Zip-Ada: Ada library for zip files (.zip). Ada programming.
(-!- marks an improvement which is bringing an incompatibility):
- '53', 14-Nov-2017:
- Decompression and loading of archive directory are more
resistant to fuzzing attacks. From that version, a random data
passed as a Zip archive will be either valid (with an extremely tiny
probability), or, for loading the archive directory, issue
Zip.Archive_Corrupted. Data extraction will issue one of:
Zip.Archive_Corrupted, UnZip.CRC_Error, UnZip.Wrong_password,
- Zip.Compress & ReZip: fix in local header generation: EOS flag for
LZMA format is properly set in any situation LZMA is actually used.
- (Tools) ZipAda tool has a more useful recursive
directory search (-r2 option).
- (Tests) Added Fuzzip, a fuzzing tool for the compression side.
- '52', 08-Oct-2016:
- UnZip.Streams: all procedures have an additional (optional)
- Zip.Compress has the following new methods with improved compression:
LZMA_3, Preselection_1 (replaces Preselection), Preselection_2.
Preselection methods use now entry name extension and size for
improving compression, while remaining 1-pass methods.
- '51', 27-Aug-2016:
- LZMA.Encoding has been added; it is a standalone compressor,
see lzma_enc.adb for an example of use.
- Zip.Compress provides now LZMA_1, LZMA_2 methods. In other words, you
can use the LZMA compression with Zip.Create.
- Zip.Compress has also a "Preselection" method that selects
a compression method depending on hints like the uncompressed size.
- Zip.Compress.Deflate: Deflate_1 .. Deflate_3 compression is
- '50', 31-Mar-2016:
- Zip.Compress.Shrink is slightly faster
- Zip.Compress.Deflate has new compression features:
- Deflate_Fixed is much faster, with slightly better compression
- Deflate_1 was added: strength similar to zlib, level 6
- Deflate_2 was added: strength similar to zlib, level 9
- Deflate_3 was added: strength similar to 7-Zip, method=deflate, level 5
- '49', 21-Mar-2015:
- encryption implemented (portable Zip 2.0 encryption scheme)
- '48', 20-Jul-2014:
decompression significantly faster
- '47', 28-Jun-2014:
method added for decompression
- '46', 14-Sep-2013:
- UnZip.Streams decompresses to input and (new) to output streams
- Removed usage of signed integers for stream sizes, increasing
limits from 2 GB to 4 GB on 32-bit targets
- Added Zip.Traverse_Unicode
- UnZip: does not attempt to create empty pathes or drives
- '45', 22-Dec-2012:
- Decryption's password check also working for archives encrypted
by Info-Zip software.
- Massive speedup when checking files that are invalid Zip archives
or Zip archives with large comments.
- Added Is_Open method for File_Zipstream.
- Zip.Load closes properly the file when loading fails.
- Improved detection of invalid dates in some Zip archives
(e.g. wmpChrome.crx Chrome extension).
- UnZip.Decompress: Optimized calls of feedback: called only when
1% more done.
-!- Removed case_sensitive as a parameter in Zip.Exists, Zip.Find_Offset,
Zip.Get_Sizes, and UnZip.Streams.Open, versions with Zip_Info profiles.
The Zip_info objects now keep this information in a field after Load.
Rationale: case-sensitivity mode for search make only sense when it
matches the mode used for building the dictionary.
- Added User_code to Zip_info entries. Can be set with the Set_user_code
and User_code subprograms, or via the Action procedure for the generic
-!- Improved (if not completed) Unicode support (UTF-8); clearer
informations about encoding.
- '44', 3-Nov-2012:
- The libary provides now a complete toolset for managing Zip archives
(creating, updating, extracting)
-!- Zip_Streams: All methods now with pointer-free profiles
- new Add_Compressed_Stream for copying entries from an archive
to another one
- file modification date and read-only attribute can be passed
- archive creation date is used when entries are added which
are from a memory buffer (Add_String)
- compression method can be changed "on the fly", before
adding new entries
- Zip.Compress: set a larger, standard output buffer size
- '43', 15-Sep-2012:
- Read-only attribute is recognized
- '42', 30-Jan-2012:
- Support for Zip archives appended to other files,
like a self-extracting archive with Zip-Ada in the executable
- Zip.Traverse (and then Extract all from Zip_Info) uses real file names
in the case-insensitive mode, instead of UPPER-cased names that are
there only for dictionary search
- Some improvements in the ReZip and ZipAda tools
- '41', 22-Jul-2011:
- Support for Unicode (UTF-8) entry names within archives; see: Zip,
-!- Zip_Streams: Made names more consistent, previous names
preserved with the pragma 'Obsolescent'
- '40', 1-Mar-2011:
- New package Zip.Compress.Deflate, with a first (weak but straightforward)
compression technique for the Deflate format
- Some improvements in the ReZip and UnZipAda tools
- '39', 5-Oct-2010:
- Some fixes in the tools
- '38', 27-Feb-2010:
- ReZip: added '-fast_dec' and '-rand_stable' options
- Zip.Create: fixed major bottlenecks around Dir_entries
→ 5x faster overall for 1000 files, 356x for 100'000 files !
- '37', 1-Jan-2010:
- Minor changes which leads to a significant speedup on GNAT;
active use of Ada.Calendar can be totally avoided if this is desired
- '36', 21-Nov-2009:
method added for decompression
- Added Zip.Traverse_verbose
- Added an UnZip.Extract to extract all files, using a Zip_Info variable
- '35', 2-Nov-2009:
- major performance improvement
decompression 10x faster, compression 3x faster, thanks to
a workaround for slow 'Read, 'Write attributes in GNAT & ObjectAda
- ReZip: HTML display improved
- '34', 12-Oct-2009:
- ReZip: added '-defl' option for having a recompressed archive only
with Deflate or Store methods (most compatible)
- ReZip: added '-comp' option for comparing output against input
- ReZip: added '-touch' and '-lower' options
- '33', 18-Jun-2009:
- UnZip: added extract_as_text option (cf. UnZipAda with -a option)
- Zip: Zip_comment function added (cf. UnZipAda with -z option)
- '31', 20-Feb-2009:
- Added tiny demos: Demo_Zip, Demo_UnZip
-!- Zip.Create: Create / Finish: if Info.Stream is to a file,
the underlying archive file is also created / closed as well
- Added procedure Add_String in Zip.Create
- '30', 7-Feb-2009:
- Added support for the 64KB slide "enhanced deflate" format #9 in UnZip.Decompress
- Added Find_Zip tool
- Added Demo_csv_into_zip demo (production of numerous files into a zip archive)
- LZ77 output in "Reduce" is cached
- '29', 30-Jan-2009:
- Added Zip.LZ77 and Zip.Compress.Reduce .
The "Reduce" method compresses data with a Markov matrix
(in this implementation, the matrix is optimal)
- Added an ./extra directory with a tiny LZH encoder/decoder
- '26', 30-Aug-2008:
- zip archive can be any kind of stream (not only a file), for both
extraction (unzip) and creation (zip)
- '22', 14-Dec-2007:
- Added a new Compose_File_Name to UnZip.File_System_Routines,
see new "-d dir" option in the UnZipAda tool
- Added Zip.Compress, Zip.Compress.Shrink,
see the ZipAda tool, which has now the light "Shrink" compression
- '19', 9-Mar-2007:
- New Zip library with Zip stuff concerning not only decompression;
packages: Zip, Zip.Headers, Zip.CRC
- '11' : 29-Nov-2002:
New generic procedure for traversing a Zip directory structure.
As a demo, a tool (comp_zip) for comparing two .Zip archive files.
Useful when combining zip, pkzip, 7zip, kzip and zipmix to shrink
archives and check them after.
- '04' : 4-Jul-1999:
Reduce method debugged. Now all PKZIPs from 1989 to 1999 are supported.
File unzipping is finished and works.
User information more complete (see unzipada.adb).
1st publishing in the Public Ada Library.
Begin of Pascal source translation via P2Ada