## Prefixes For example for adding extractors for self-extracting zip archives. ````c zip_set_archive_prefix(struct zip *za, const zip_uint8_t *data, zip_uint64_t length); const zip_uint8_t *zip_get_archive_prefix(struct zip *za, zip_uint64_t *lengthp); ```` ## Compression * add lzma2 support * add deflate64 support (https://github.com/madler/zlib/blob/master/contrib/infback9/infback9.h) ## API Issues * `zip_get_archive_comment` has `int *lenp` argument. Cleaner would be `zip_uint32_t *`. rename and fix. which other functions for naming consistency? * rename remaining `zip_XXX_{file,archive}_*` to `zip_{file,archive}_XXX_*`? * compression/crypt implementations: how to set error code on failure * compression/crypt error messages a la `ZIP_ER_ZLIB` (no detailed info passing) ## Features * add seek support for AES-encrypted files * consistently use `_zip_crypto_clear()` for passwords * support setting extra fields from `zip_source` * introduce layers of extra fields: * original * from `zip_source` * manually set * when querying extra fields, search all of them in reverse order * add whiteout (deleted) flag * allow invalid data flag, used when computing extra field size before writing data * new command `ZIP_SOURCE_EXTRA_FIELDS` * no support for multiple copies of same extra field * delete all extra fields during `zip_replace()` * function to copy file from one archive to another * set `O_CLOEXEC` flag after fopen and mkstemp * `zip_file_set_mtime()`: support InfoZIP time stamps * support streaming output (creating new archive to e.g. stdout) * add function to read/set ASCII file flag * `zip_commit()` (to finish changes without closing archive) * add custom compression function support * `zip_source_zip()`: allow rewinding * `zipcmp`: add option for file content comparison * `zipcmp`: add more paranoid checks: * external attributes/opsys * last_mod * version needed/made by * general purpose bit flags * add more consistency checks: * for stored files, test compressed = uncompressed * data descriptor * local headers come before central dir * support for old compression methods? ## Bugs * ensure that nentries is small enough not to cause overflow (size_t for entry, uint64 for CD on disk) * check for limits imposed by format (central dir size, file size, extra fields, ...) * `_zip_u2d_time()`: handle `localtime(3)` failure * POSIX: `zip_open()`: check whether file can be created and fail if not * fix inconsistent usage of valid flags (not checked in many places) * `cdr == NULL` -> `ER_NOENT` vs. `idx > cdir->nentry` -> `ER_INVAL` inconsistent (still there?) ## Cleanup * go over cdir parser and rename various offset/size variables to make it clearer * use bool * use `ZIP_SOURCE_SUPPORTS_{READABLE,SEEKABLE,WRITABLE}` * use `zip_source_seek_compute_offset()` * get rid of `zip_get_{compression,encryption}_implementation()` * use `zip_*int*_t` internally * `zip_source_file()`: don't allow write if start/len specify a part of the file ## Documentation * document: `zip_source_write()`: length can't be > `ZIP_INT64_MAX` * document: `ZIP_SOURCE_CLOSE` implementation can't return error * keep error codes in man pages in sync * document error codes in new man pages ## Infrastructure * review guidelines/community standards - [Linux Foundation Core Infrastructure Initiative Best Practices](https://bestpractices.coreinfrastructure.org/) - [Readme Maturity Level](https://github.com/LappleApple/feedmereadmes/blob/master/README-maturity-model.md) - [Github Community Profile](https://github.com/nih-at/libzip/community) * test different crypto backends with TravisCI. * improve man page formatting of tagged lists on webpage (`