Commit graph

17 commits

Author SHA1 Message Date
Tim Schumacher
43f98ac6e1 Everywhere: Remove the AK:: qualifier from Stream usages 2023-02-13 00:50:07 +00:00
Ollrogge
0ce1c52577 LibArchive: Add support for modification time and date 2023-02-12 13:13:15 -07:00
Tim Schumacher
8464da1439 AK: Move Stream and SeekableStream from LibCore
`Stream` will be qualified as `AK::Stream` until we remove the
`Core::Stream` namespace. `IODevice` now reuses the `SeekMode` that is
defined by `SeekableStream`, since defining its own would require us to
qualify it with `AK::SeekMode` everywhere.
2023-01-29 19:16:44 -07:00
implicitfield
28c99e7a1f LibArchive+Utilities: Stop using DeprecatedString
This also slightly improves error propagation in tar, unzip and zip.
2023-01-08 09:54:08 +00:00
Karol Kosek
8238f926fd LibArchive+Utilities: Port ZipOutputStream to Core::Stream 2022-12-27 07:24:07 +03:30
Linus Groh
6e19ab2bbc AK+Everywhere: Rename String to DeprecatedString
We have a new, improved string type coming up in AK (OOM aware, no null
state), and while it's going to use UTF-8, the name UTF8String is a
mouthful - so let's free up the String name by renaming the existing
class.
Making the old one have an annoying name will hopefully also help with
quick adoption :^)
2022-12-06 08:54:33 +01:00
Tim Schumacher
acc9be9f7d LibArchive: Use named members for ZIP general purpose flags
This fixes the faulty bit check that misclassified ZIPs as having
data descriptors.
2022-05-12 22:58:14 +02:00
Idan Horowitz
086969277e Everywhere: Run clang-format 2022-04-01 21:24:45 +01:00
Lenny Maiorani
be360db223 Libraries: Change enums to enum classes in LibArchive 2022-03-18 19:59:43 +01:00
Lenny Maiorani
c0735b047e LibArchive: Use designated initializers
Benefits:
- Braced-initialization prevents unknown narrowing conversions.
- Using designated initializers will result in a compiler error when a
  member is skipped or forgotten.
2022-02-18 23:54:14 +02:00
Lenny Maiorani
484c0edafc LibArchive: Refactor zip header handling
The directory headers have some common code for reading.
2022-02-18 23:54:14 +02:00
Andreas Kling
80d4e830a0 Everywhere: Pass AK::ReadonlyBytes by value 2021-11-11 01:27:46 +01:00
Idan Horowitz
1c512a702a AK+Userland: Use idan.horowitz@serenityos.org for my copyright headers 2021-04-22 22:42:38 +02:00
Brian Gianforcaro
1682f0b760 Everything: Move to SPDX license identifiers in all files.
SPDX License Identifiers are a more compact / standardized
way of representing file license information.

See: https://spdx.dev/resources/use/#identifiers

This was done with the `ambr` search and replace tool.

 ambr --no-parent-ignore --key-from-file --rep-from-file key.txt rep.txt *
2021-04-22 11:22:27 +02:00
Idan Horowitz
1ac661515e LibArchive: Bounds check header offsets in Zip Parser
Since the central directory offset in the end of central directory
record and the local file offset in each central directory header
are user-controlled arbitary data, we have to bounds check them
before using them.
2021-03-27 19:44:16 +01:00
Idan Horowitz
550ae23e80 LibArchive: Implement ZipOutputStream for zip archive creation
This output stream can be used to create zip archives, and will
be used in the implementation of the zip utility.
2021-03-23 16:09:36 +01:00
Idan Horowitz
caf4bde3a9 LibArchive: Add Zip file parser
This is based on the zip specification on PKWARE's zip specification
(https://pkware.cachefly.net/webdocs/casestudies/APPNOTE.TXT) and will
be used in the unzip utility and eventually in the zip utility.
2021-03-23 16:09:36 +01:00