Package-level declarations
Types
One member of a container. name is the raw stored name. Always run it through io.github.yuroyami.kitearchive.security.PathGuard before joining it to an output directory. dataOffset is where the entry's bytes begin in the source (container internal); -1 when not applicable.
A container / single-stream format detected by Magic.
Read side of a container. entries lists members from the header alone and touches no payload, which is "browse without extract". read materialises one entry's uncompressed bytes under the bomb ArchiveLimits.
A RandomAccessSource backed by an in-memory ByteArray.
Magic-byte format sniffer. It reads a header, or the first 512 bytes of a RandomAccessSource, and returns the matching ArchiveFormat. Brotli has no magic bytes, so this object never detects it.
A seekable, random-access byte source. Every container reader works against this read contract. ZIP "browse without extract" (read the central directory at the tail) and single-entry extract (seek to one local header) both need offset reads rather than a forward-only stream.
Functions
Read exactly length bytes at offset, or fail. Convenience over RandomAccessSource.read.