├── .editorconfig ├── .gitignore ├── ArchiveUtil.cpp ├── ArchiveUtil.h ├── BuildAutomation ├── bin │ ├── 7z.dll │ └── 7z.exe └── build.cmd ├── LICENSE ├── Log.cpp ├── Log.h ├── Log4jRemediate.rc ├── Log4jRemediate.vcxproj ├── Log4jRemediate.vcxproj.filters ├── Log4jScanner.rc ├── Log4jScanner.sln ├── Log4jScanner.vcxproj ├── Log4jScanner.vcxproj.filters ├── MainRemediate.cpp ├── MainScan.cpp ├── README.md ├── Remediate.cpp ├── Remediate.h ├── Reports.cpp ├── Reports.h ├── Scanner.cpp ├── Scanner.h ├── Utils.cpp ├── Utils.h ├── Version.info ├── bzip2 ├── CHANGES ├── LICENSE ├── README ├── blocksort.c ├── bzip2.c ├── bzip2.vcxproj ├── bzip2.vcxproj.filters ├── bzip2recover.c ├── bzlib.c ├── bzlib.h ├── bzlib_private.h ├── compress.c ├── crctable.c ├── decompress.c ├── dlltest.c ├── huffman.c ├── mk251.c ├── randtable.c ├── spewG.c └── unzcrash.c ├── libarchive ├── archive.h ├── archive_acl.c ├── archive_acl_private.h ├── archive_blake2.h ├── archive_blake2_impl.h ├── archive_blake2s_ref.c ├── archive_blake2sp_ref.c ├── archive_check_magic.c ├── archive_cmdline.c ├── archive_cmdline_private.h ├── archive_crc32.h ├── archive_cryptor.c ├── archive_cryptor_private.h ├── archive_digest.c ├── archive_digest_private.h ├── archive_disk_acl_darwin.c ├── archive_disk_acl_freebsd.c ├── archive_disk_acl_linux.c ├── archive_disk_acl_sunos.c ├── archive_endian.h ├── archive_entry.c ├── archive_entry.h ├── archive_entry_copy_bhfi.c ├── archive_entry_copy_stat.c ├── archive_entry_link_resolver.c ├── archive_entry_locale.h ├── archive_entry_private.h ├── archive_entry_sparse.c ├── archive_entry_stat.c ├── archive_entry_strmode.c ├── archive_entry_xattr.c ├── archive_getdate.c ├── archive_getdate.h ├── archive_hmac.c ├── archive_hmac_private.h ├── archive_match.c ├── archive_openssl_evp_private.h ├── archive_openssl_hmac_private.h ├── archive_options.c ├── archive_options_private.h ├── archive_pack_dev.c ├── archive_pack_dev.h ├── archive_pathmatch.c ├── archive_pathmatch.h ├── archive_platform.h ├── archive_platform_acl.h ├── archive_platform_xattr.h ├── archive_ppmd7.c ├── archive_ppmd7_private.h ├── archive_ppmd8.c ├── archive_ppmd8_private.h ├── archive_ppmd_private.h ├── archive_private.h ├── archive_random.c ├── archive_random_private.h ├── archive_rb.c ├── archive_rb.h ├── archive_read.c ├── archive_read_add_passphrase.c ├── archive_read_append_filter.c ├── archive_read_data_into_fd.c ├── archive_read_disk_entry_from_file.c ├── archive_read_disk_posix.c ├── archive_read_disk_private.h ├── archive_read_disk_set_standard_lookup.c ├── archive_read_disk_windows.c ├── archive_read_extract.c ├── archive_read_extract2.c ├── archive_read_open_fd.c ├── archive_read_open_file.c ├── archive_read_open_filename.c ├── archive_read_open_memory.c ├── archive_read_private.h ├── archive_read_set_format.c ├── archive_read_set_options.c ├── archive_read_support_filter_all.c ├── archive_read_support_filter_by_code.c ├── archive_read_support_filter_bzip2.c ├── archive_read_support_filter_compress.c ├── archive_read_support_filter_grzip.c ├── archive_read_support_filter_gzip.c ├── archive_read_support_filter_lrzip.c ├── archive_read_support_filter_lz4.c ├── archive_read_support_filter_lzop.c ├── archive_read_support_filter_none.c ├── archive_read_support_filter_program.c ├── archive_read_support_filter_rpm.c ├── archive_read_support_filter_uu.c ├── archive_read_support_filter_xz.c ├── archive_read_support_filter_zstd.c ├── archive_read_support_format_7zip.c ├── archive_read_support_format_all.c ├── archive_read_support_format_ar.c ├── archive_read_support_format_by_code.c ├── archive_read_support_format_cab.c ├── archive_read_support_format_cpio.c ├── archive_read_support_format_empty.c ├── archive_read_support_format_iso9660.c ├── archive_read_support_format_lha.c ├── archive_read_support_format_mtree.c ├── archive_read_support_format_rar.c ├── archive_read_support_format_rar5.c ├── archive_read_support_format_raw.c ├── archive_read_support_format_tar.c ├── archive_read_support_format_warc.c ├── archive_read_support_format_xar.c ├── archive_read_support_format_zip.c ├── archive_static.vcxproj ├── archive_static.vcxproj.filters ├── archive_string.c ├── archive_string.h ├── archive_string_composition.h ├── archive_string_sprintf.c ├── archive_util.c ├── archive_version_details.c ├── archive_virtual.c ├── archive_windows.c ├── archive_windows.h ├── archive_write.c ├── archive_write_add_filter.c ├── archive_write_add_filter_b64encode.c ├── archive_write_add_filter_by_name.c ├── archive_write_add_filter_bzip2.c ├── archive_write_add_filter_compress.c ├── archive_write_add_filter_grzip.c ├── archive_write_add_filter_gzip.c ├── archive_write_add_filter_lrzip.c ├── archive_write_add_filter_lz4.c ├── archive_write_add_filter_lzop.c ├── archive_write_add_filter_none.c ├── archive_write_add_filter_program.c ├── archive_write_add_filter_uuencode.c ├── archive_write_add_filter_xz.c ├── archive_write_add_filter_zstd.c ├── archive_write_disk_posix.c ├── archive_write_disk_private.h ├── archive_write_disk_set_standard_lookup.c ├── archive_write_disk_windows.c ├── archive_write_open_fd.c ├── archive_write_open_file.c ├── archive_write_open_filename.c ├── archive_write_open_memory.c ├── archive_write_private.h ├── archive_write_set_format.c ├── archive_write_set_format_7zip.c ├── archive_write_set_format_ar.c ├── archive_write_set_format_by_name.c ├── archive_write_set_format_cpio.c ├── archive_write_set_format_cpio_binary.c ├── archive_write_set_format_cpio_newc.c ├── archive_write_set_format_cpio_odc.c ├── archive_write_set_format_filter_by_ext.c ├── archive_write_set_format_gnutar.c ├── archive_write_set_format_iso9660.c ├── archive_write_set_format_mtree.c ├── archive_write_set_format_pax.c ├── archive_write_set_format_private.h ├── archive_write_set_format_raw.c ├── archive_write_set_format_shar.c ├── archive_write_set_format_ustar.c ├── archive_write_set_format_v7tar.c ├── archive_write_set_format_warc.c ├── archive_write_set_format_xar.c ├── archive_write_set_format_zip.c ├── archive_write_set_options.c ├── archive_write_set_passphrase.c ├── archive_xxhash.h ├── config.h ├── filter_fork.h ├── filter_fork_posix.c ├── filter_fork_windows.c └── xxhash.c ├── minizip ├── Makefile ├── Makefile.am ├── MiniZip64_Changes.txt ├── MiniZip64_info.txt ├── configure.ac ├── crypt.h ├── ioapi.c ├── ioapi.h ├── iowin32.c ├── iowin32.h ├── make_vms.com ├── miniunz.c ├── miniunzip.1 ├── minizip.1 ├── minizip.c ├── minizip.pc.in ├── minizip.vcxproj ├── minizip.vcxproj.user ├── mztools.c ├── mztools.h ├── unzip.c ├── unzip.h ├── zip.c ├── zip.h ├── zlib.rc └── zlibvc.def ├── rapidjson ├── .gitattributes ├── .gitignore ├── .gitlab-ci.yml ├── .gitmodules ├── .travis.yml ├── CHANGELOG.md ├── CMakeLists.txt ├── CMakeModules │ └── FindGTestSrc.cmake ├── RapidJSON.pc.in ├── RapidJSONConfig.cmake.in ├── RapidJSONConfigVersion.cmake.in ├── appveyor.yml ├── bin │ ├── data │ │ ├── abcde.txt │ │ ├── glossary.json │ │ ├── menu.json │ │ ├── readme.txt │ │ ├── sample.json │ │ ├── webapp.json │ │ └── widget.json │ ├── encodings │ │ ├── utf16be.json │ │ ├── utf16bebom.json │ │ ├── utf16le.json │ │ ├── utf16lebom.json │ │ ├── utf32be.json │ │ ├── utf32bebom.json │ │ ├── utf32le.json │ │ ├── utf32lebom.json │ │ ├── utf8.json │ │ └── utf8bom.json │ ├── jsonchecker │ │ ├── fail1.json │ │ ├── fail10.json │ │ ├── fail11.json │ │ ├── fail12.json │ │ ├── fail13.json │ │ ├── fail14.json │ │ ├── fail15.json │ │ ├── fail16.json │ │ ├── fail17.json │ │ ├── fail18.json │ │ ├── fail19.json │ │ ├── fail2.json │ │ ├── fail20.json │ │ ├── fail21.json │ │ ├── fail22.json │ │ ├── fail23.json │ │ ├── fail24.json │ │ ├── fail25.json │ │ ├── fail26.json │ │ ├── fail27.json │ │ ├── fail28.json │ │ ├── fail29.json │ │ ├── fail3.json │ │ ├── fail30.json │ │ ├── fail31.json │ │ ├── fail32.json │ │ ├── fail33.json │ │ ├── fail4.json │ │ ├── fail5.json │ │ ├── fail6.json │ │ ├── fail7.json │ │ ├── fail8.json │ │ ├── fail9.json │ │ ├── pass1.json │ │ ├── pass2.json │ │ ├── pass3.json │ │ └── readme.txt │ ├── types │ │ ├── booleans.json │ │ ├── floats.json │ │ ├── guids.json │ │ ├── integers.json │ │ ├── mixed.json │ │ ├── nulls.json │ │ ├── paragraphs.json │ │ └── readme.txt │ └── unittestschema │ │ ├── address.json │ │ ├── allOf_address.json │ │ ├── anyOf_address.json │ │ └── oneOf_address.json ├── doc │ ├── CMakeLists.txt │ ├── Doxyfile.in │ ├── Doxyfile.zh-cn.in │ ├── diagram │ │ ├── architecture.dot │ │ ├── architecture.png │ │ ├── insituparsing.dot │ │ ├── insituparsing.png │ │ ├── iterative-parser-states-diagram.dot │ │ ├── iterative-parser-states-diagram.png │ │ ├── move1.dot │ │ ├── move1.png │ │ ├── move2.dot │ │ ├── move2.png │ │ ├── move3.dot │ │ ├── move3.png │ │ ├── normalparsing.dot │ │ ├── normalparsing.png │ │ ├── simpledom.dot │ │ ├── simpledom.png │ │ ├── tutorial.dot │ │ ├── tutorial.png │ │ ├── utilityclass.dot │ │ └── utilityclass.png │ ├── dom.md │ ├── dom.zh-cn.md │ ├── encoding.md │ ├── encoding.zh-cn.md │ ├── faq.md │ ├── faq.zh-cn.md │ ├── features.md │ ├── features.zh-cn.md │ ├── internals.md │ ├── internals.zh-cn.md │ ├── logo │ │ ├── rapidjson.png │ │ └── rapidjson.svg │ ├── misc │ │ ├── DoxygenLayout.xml │ │ ├── doxygenextra.css │ │ ├── footer.html │ │ └── header.html │ ├── npm.md │ ├── performance.md │ ├── performance.zh-cn.md │ ├── pointer.md │ ├── pointer.zh-cn.md │ ├── sax.md │ ├── sax.zh-cn.md │ ├── schema.md │ ├── schema.zh-cn.md │ ├── stream.md │ ├── stream.zh-cn.md │ ├── tutorial.md │ └── tutorial.zh-cn.md ├── example │ ├── CMakeLists.txt │ ├── archiver │ │ ├── archiver.cpp │ │ ├── archiver.h │ │ └── archivertest.cpp │ ├── capitalize │ │ └── capitalize.cpp │ ├── condense │ │ └── condense.cpp │ ├── filterkey │ │ └── filterkey.cpp │ ├── filterkeydom │ │ └── filterkeydom.cpp │ ├── jsonx │ │ └── jsonx.cpp │ ├── lookaheadparser │ │ └── lookaheadparser.cpp │ ├── messagereader │ │ └── messagereader.cpp │ ├── parsebyparts │ │ └── parsebyparts.cpp │ ├── pretty │ │ └── pretty.cpp │ ├── prettyauto │ │ └── prettyauto.cpp │ ├── schemavalidator │ │ └── schemavalidator.cpp │ ├── serialize │ │ └── serialize.cpp │ ├── simpledom │ │ └── simpledom.cpp │ ├── simplepullreader │ │ └── simplepullreader.cpp │ ├── simplereader │ │ └── simplereader.cpp │ ├── simplewriter │ │ └── simplewriter.cpp │ ├── sortkeys │ │ └── sortkeys.cpp │ └── tutorial │ │ └── tutorial.cpp ├── include │ └── rapidjson │ │ ├── allocators.h │ │ ├── cursorstreamwrapper.h │ │ ├── document.h │ │ ├── encodedstream.h │ │ ├── encodings.h │ │ ├── error │ │ ├── en.h │ │ └── error.h │ │ ├── filereadstream.h │ │ ├── filewritestream.h │ │ ├── fwd.h │ │ ├── internal │ │ ├── biginteger.h │ │ ├── clzll.h │ │ ├── diyfp.h │ │ ├── dtoa.h │ │ ├── ieee754.h │ │ ├── itoa.h │ │ ├── meta.h │ │ ├── pow10.h │ │ ├── regex.h │ │ ├── stack.h │ │ ├── strfunc.h │ │ ├── strtod.h │ │ └── swap.h │ │ ├── istreamwrapper.h │ │ ├── memorybuffer.h │ │ ├── memorystream.h │ │ ├── msinttypes │ │ ├── inttypes.h │ │ └── stdint.h │ │ ├── ostreamwrapper.h │ │ ├── pointer.h │ │ ├── prettywriter.h │ │ ├── rapidjson.h │ │ ├── reader.h │ │ ├── schema.h │ │ ├── stream.h │ │ ├── stringbuffer.h │ │ └── writer.h ├── include_dirs.js ├── library.json ├── license.txt ├── package.json ├── rapidjson.autopkg ├── readme.md ├── readme.zh-cn.md ├── test │ ├── CMakeLists.txt │ ├── perftest │ │ ├── CMakeLists.txt │ │ ├── misctest.cpp │ │ ├── perftest.cpp │ │ ├── perftest.h │ │ ├── platformtest.cpp │ │ ├── rapidjsontest.cpp │ │ └── schematest.cpp │ ├── unittest │ │ ├── CMakeLists.txt │ │ ├── allocatorstest.cpp │ │ ├── bigintegertest.cpp │ │ ├── clzlltest.cpp │ │ ├── cursorstreamwrappertest.cpp │ │ ├── documenttest.cpp │ │ ├── dtoatest.cpp │ │ ├── encodedstreamtest.cpp │ │ ├── encodingstest.cpp │ │ ├── filestreamtest.cpp │ │ ├── fwdtest.cpp │ │ ├── istreamwrappertest.cpp │ │ ├── itoatest.cpp │ │ ├── jsoncheckertest.cpp │ │ ├── namespacetest.cpp │ │ ├── ostreamwrappertest.cpp │ │ ├── pointertest.cpp │ │ ├── prettywritertest.cpp │ │ ├── readertest.cpp │ │ ├── regextest.cpp │ │ ├── schematest.cpp │ │ ├── simdtest.cpp │ │ ├── strfunctest.cpp │ │ ├── stringbuffertest.cpp │ │ ├── strtodtest.cpp │ │ ├── unittest.cpp │ │ ├── unittest.h │ │ ├── valuetest.cpp │ │ └── writertest.cpp │ └── valgrind.supp └── travis-doxygen.sh ├── resource.h ├── stdafx.cpp ├── stdafx.h ├── targetver.h ├── tarlib ├── filesyshelpers.cpp ├── filesyshelpers.h ├── stringhelpers.cpp ├── stringhelpers.h ├── tarlib.cpp ├── tarlib.h └── tarlib.vcxproj └── zlib ├── .gitignore ├── CMakeLists.txt ├── ChangeLog ├── FAQ ├── INDEX ├── Makefile ├── Makefile.in ├── README ├── adler32.c ├── amiga ├── Makefile.pup └── Makefile.sas ├── compress.c ├── configure ├── contrib ├── README.contrib ├── ada │ ├── buffer_demo.adb │ ├── mtest.adb │ ├── read.adb │ ├── readme.txt │ ├── test.adb │ ├── zlib-streams.adb │ ├── zlib-streams.ads │ ├── zlib-thin.adb │ ├── zlib-thin.ads │ ├── zlib.adb │ ├── zlib.ads │ └── zlib.gpr ├── amd64 │ └── amd64-match.S ├── asm686 │ ├── README.686 │ └── match.S ├── blast │ ├── Makefile │ ├── README │ ├── blast.c │ ├── blast.h │ ├── test.pk │ └── test.txt ├── delphi │ ├── ZLib.pas │ ├── ZLibConst.pas │ ├── readme.txt │ └── zlibd32.mak ├── dotzlib │ ├── DotZLib.build │ ├── DotZLib.chm │ ├── DotZLib.sln │ ├── DotZLib │ │ ├── AssemblyInfo.cs │ │ ├── ChecksumImpl.cs │ │ ├── CircularBuffer.cs │ │ ├── CodecBase.cs │ │ ├── Deflater.cs │ │ ├── DotZLib.cs │ │ ├── DotZLib.csproj │ │ ├── GZipStream.cs │ │ ├── Inflater.cs │ │ └── UnitTests.cs │ ├── LICENSE_1_0.txt │ └── readme.txt ├── gcc_gvmat64 │ └── gvmat64.S ├── infback9 │ ├── README │ ├── infback9.c │ ├── infback9.h │ ├── inffix9.h │ ├── inflate9.h │ ├── inftree9.c │ └── inftree9.h ├── inflate86 │ ├── inffas86.c │ └── inffast.S ├── iostream │ ├── test.cpp │ ├── zfstream.cpp │ └── zfstream.h ├── iostream2 │ ├── zstream.h │ └── zstream_test.cpp ├── iostream3 │ ├── README │ ├── TODO │ ├── test.cc │ ├── zfstream.cc │ └── zfstream.h ├── masmx64 │ ├── bld_ml64.bat │ ├── gvmat64.asm │ ├── inffas8664.c │ ├── inffasx64.asm │ └── readme.txt ├── masmx86 │ ├── bld_ml32.bat │ ├── inffas32.asm │ ├── match686.asm │ └── readme.txt ├── minizip │ ├── Makefile │ ├── Makefile.am │ ├── MiniZip64_Changes.txt │ ├── MiniZip64_info.txt │ ├── configure.ac │ ├── crypt.h │ ├── ioapi.c │ ├── ioapi.h │ ├── iowin32.c │ ├── iowin32.h │ ├── make_vms.com │ ├── miniunz.c │ ├── miniunzip.1 │ ├── minizip.1 │ ├── minizip.c │ ├── minizip.pc.in │ ├── mztools.c │ ├── mztools.h │ ├── unzip.c │ ├── unzip.h │ ├── zip.c │ └── zip.h ├── pascal │ ├── example.pas │ ├── readme.txt │ ├── zlibd32.mak │ └── zlibpas.pas ├── puff │ ├── Makefile │ ├── README │ ├── puff.c │ ├── puff.h │ ├── pufftest.c │ └── zeros.raw ├── testzlib │ ├── testzlib.c │ └── testzlib.txt ├── untgz │ ├── Makefile │ ├── Makefile.msc │ └── untgz.c └── vstudio │ ├── readme.txt │ ├── vc10 │ ├── miniunz.vcxproj │ ├── miniunz.vcxproj.filters │ ├── minizip.vcxproj │ ├── minizip.vcxproj.filters │ ├── testzlib.vcxproj │ ├── testzlib.vcxproj.filters │ ├── testzlibdll.vcxproj │ ├── testzlibdll.vcxproj.filters │ ├── zlib.rc │ ├── zlibstat.vcxproj │ ├── zlibstat.vcxproj.filters │ ├── zlibvc.def │ ├── zlibvc.sln │ ├── zlibvc.vcxproj │ └── zlibvc.vcxproj.filters │ ├── vc11 │ ├── miniunz.vcxproj │ ├── minizip.vcxproj │ ├── testzlib.vcxproj │ ├── testzlibdll.vcxproj │ ├── zlib.rc │ ├── zlibstat.vcxproj │ ├── zlibvc.def │ ├── zlibvc.sln │ └── zlibvc.vcxproj │ ├── vc12 │ ├── miniunz.vcxproj │ ├── minizip.vcxproj │ ├── testzlib.vcxproj │ ├── testzlibdll.vcxproj │ ├── zlib.rc │ ├── zlibstat.vcxproj │ ├── zlibvc.def │ ├── zlibvc.sln │ └── zlibvc.vcxproj │ ├── vc14 │ ├── miniunz.vcxproj │ ├── minizip.vcxproj │ ├── testzlib.vcxproj │ ├── testzlibdll.vcxproj │ ├── zlib.rc │ ├── zlibstat.vcxproj │ ├── zlibvc.def │ ├── zlibvc.sln │ └── zlibvc.vcxproj │ └── vc9 │ ├── miniunz.vcproj │ ├── minizip.vcproj │ ├── testzlib.vcproj │ ├── testzlibdll.vcproj │ ├── zlib.rc │ ├── zlibstat.vcproj │ ├── zlibvc.def │ ├── zlibvc.sln │ └── zlibvc.vcproj ├── crc32.c ├── crc32.h ├── deflate.c ├── deflate.h ├── doc ├── algorithm.txt ├── crc-doc.1.0.pdf ├── rfc1950.txt ├── rfc1951.txt ├── rfc1952.txt └── txtvsbin.txt ├── examples ├── README.examples ├── enough.c ├── fitblk.c ├── gun.c ├── gzappend.c ├── gzjoin.c ├── gzlog.c ├── gzlog.h ├── gznorm.c ├── zlib_how.html ├── zpipe.c ├── zran.c └── zran.h ├── gzclose.c ├── gzguts.h ├── gzlib.c ├── gzread.c ├── gzwrite.c ├── infback.c ├── inffast.c ├── inffast.h ├── inffixed.h ├── inflate.c ├── inflate.h ├── inftrees.c ├── inftrees.h ├── make_vms.com ├── msdos ├── Makefile.bor ├── Makefile.dj2 ├── Makefile.emx ├── Makefile.msc └── Makefile.tc ├── nintendods ├── Makefile └── README ├── old ├── Makefile.emx ├── Makefile.riscos ├── README ├── descrip.mms ├── os2 │ ├── Makefile.os2 │ └── zlib.def └── visual-basic.txt ├── os400 ├── README400 ├── bndsrc ├── make.sh └── zlib.inc ├── qnx └── package.qpg ├── test ├── example.c ├── infcover.c └── minigzip.c ├── treebuild.xml ├── trees.c ├── trees.h ├── uncompr.c ├── watcom ├── watcom_f.mak └── watcom_l.mak ├── win32 ├── DLL_FAQ.txt ├── Makefile.bor ├── Makefile.gcc ├── Makefile.msc ├── README-WIN32.txt ├── VisualC.txt ├── zlib.def └── zlib1.rc ├── zconf.h ├── zconf.h.cmakein ├── zconf.h.in ├── zlib.3 ├── zlib.3.pdf ├── zlib.h ├── zlib.map ├── zlib.pc.cmakein ├── zlib.pc.in ├── zlib2ansi ├── zutil.c └── zutil.h /.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | /.vs 3 | *.user 4 | -------------------------------------------------------------------------------- /BuildAutomation/bin/7z.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/BuildAutomation/bin/7z.dll -------------------------------------------------------------------------------- /BuildAutomation/bin/7z.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/BuildAutomation/bin/7z.exe -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | THIS SCRIPT IS PROVIDED TO YOU "AS IS." TO THE EXTENT PERMITTED BY LAW, QUALYS HEREBY DISCLAIMS ALL WARRANTIES AND LIABILITY FOR THE PROVISION OR USE OF THIS SCRIPT. 2 | IN NO EVENT SHALL THESE SCRIPTS BE DEEMED TO BE CLOUD SERVICES AS PROVIDED BY QUALYS -------------------------------------------------------------------------------- /Log.cpp: -------------------------------------------------------------------------------- 1 | #include "stdafx.h" 2 | #include "Log.h" 3 | 4 | // Returns the wide string for given Win32 error code 5 | std::wstring GetWin32ErrorAsString(const DWORD& error_code) { 6 | LPWSTR messageBuffer = nullptr; 7 | 8 | if (error_code == ERROR_SUCCESS) { 9 | return std::wstring(); 10 | } 11 | 12 | size_t size = FormatMessageW(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS, 13 | nullptr , error_code, MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), (LPWSTR)&messageBuffer, 0, nullptr); 14 | 15 | std::wstring message(messageBuffer, size); 16 | 17 | LocalFree(messageBuffer); 18 | 19 | return message; 20 | } 21 | -------------------------------------------------------------------------------- /Log.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | std::wstring GetWin32ErrorAsString(const DWORD& error_code); 4 | 5 | #define LOG_MESSAGE(message, ...) LogStatusMessage(message L"\n", __VA_ARGS__) 6 | 7 | #define LOG_WIN32_MESSAGE(error_code, message, ...) LOG_MESSAGE(message L": %s", __VA_ARGS__, GetWin32ErrorAsString(error_code).c_str()) -------------------------------------------------------------------------------- /Remediate.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | namespace log4jremediate { 4 | 5 | constexpr DWORD SIGNATURE_ITEM_LENGTH = 4; 6 | 7 | class RemediateLog4JFile { 8 | public: 9 | RemediateLog4JFile() = default; 10 | 11 | ~RemediateLog4JFile() = default; 12 | 13 | DWORD RemediateFileArchive(const std::wstring& vulnerable_file_path); 14 | 15 | private: 16 | /* Cleanup temporary files*/ 17 | void CleanupTempFiles(const std::unordered_set& setTempLocs); 18 | }; 19 | 20 | class RemediateLog4JSigReport { 21 | public: 22 | static DWORD RemediateFromSignatureReport(); 23 | }; 24 | } 25 | -------------------------------------------------------------------------------- /Scanner.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | class CScannerOptions { 4 | public: 5 | bool console; 6 | bool verbose; 7 | std::vector excludedDrives; 8 | std::vector excludedDirectories; 9 | std::vector excludedFiles; 10 | int64_t maxFileSize; 11 | std::wstring tempDirectory; 12 | std::vector knownTarExtensions; 13 | std::vector knownGZipTarExtensions; 14 | std::vector knownBZipTarExtensions; 15 | std::vector knownZipExtensions; 16 | 17 | CScannerOptions() { 18 | console = false; 19 | verbose = false; 20 | excludedDrives.clear(); 21 | excludedDirectories.clear(); 22 | excludedFiles.clear(); 23 | maxFileSize = 0; 24 | tempDirectory.clear(); 25 | knownTarExtensions.clear(); 26 | knownGZipTarExtensions.clear(); 27 | knownBZipTarExtensions.clear(); 28 | knownZipExtensions.clear(); 29 | } 30 | }; 31 | 32 | int32_t ScanFile(CScannerOptions& options, std::wstring file, std::wstring file_physical); 33 | int32_t ScanDirectory(CScannerOptions& options, std::wstring directory, std::wstring directory_physical); 34 | int32_t ScanLocalDrives(CScannerOptions& options); 35 | int32_t ScanNetworkDrives(CScannerOptions& options); 36 | int32_t ScanLocalDrivesInclMountpoints(CScannerOptions& options); 37 | int32_t ScanPrepareEnvironment(CScannerOptions& options); 38 | -------------------------------------------------------------------------------- /Version.info: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #define SCANNER_VERSION_BINARY 2,1,4,0 3 | #define SCANNER_VERSION_STRING "2.1.4.0" 4 | 5 | #define REMEDIATE_VERSION_BINARY 1,2,2,1 6 | #define REMEDIATE_VERSION_STRING "1.2.2.1" 7 | -------------------------------------------------------------------------------- /bzip2/LICENSE: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------- 3 | 4 | This program, "bzip2", the associated library "libbzip2", and all 5 | documentation, are copyright (C) 1996-2019 Julian R Seward. All 6 | rights reserved. 7 | 8 | Redistribution and use in source and binary forms, with or without 9 | modification, are permitted provided that the following conditions 10 | are met: 11 | 12 | 1. Redistributions of source code must retain the above copyright 13 | notice, this list of conditions and the following disclaimer. 14 | 15 | 2. The origin of this software must not be misrepresented; you must 16 | not claim that you wrote the original software. If you use this 17 | software in a product, an acknowledgment in the product 18 | documentation would be appreciated but is not required. 19 | 20 | 3. Altered source versions must be plainly marked as such, and must 21 | not be misrepresented as being the original software. 22 | 23 | 4. The name of the author may not be used to endorse or promote 24 | products derived from this software without specific prior written 25 | permission. 26 | 27 | THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS 28 | OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 29 | WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 30 | ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY 31 | DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 32 | DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE 33 | GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 34 | INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 35 | WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING 36 | NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 37 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 38 | 39 | Julian Seward, jseward@acm.org 40 | bzip2/libbzip2 version 1.0.8 of 13 July 2019 41 | 42 | -------------------------------------------------------------------------- 43 | -------------------------------------------------------------------------------- /bzip2/bzip2.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {3e47117d-7e00-451f-87b5-aad6134a7ec0} 6 | 7 | 8 | {b802c171-17a2-49f7-9a24-3e1c8e1c23ff} 9 | 10 | 11 | {81e85710-2079-4285-87a6-c69f9455903c} 12 | 13 | 14 | 15 | 16 | Source Files 17 | 18 | 19 | Source Files 20 | 21 | 22 | Source Files 23 | 24 | 25 | Source Files 26 | 27 | 28 | Source Files 29 | 30 | 31 | Source Files 32 | 33 | 34 | Source Files 35 | 36 | 37 | 38 | 39 | Header Files 40 | 41 | 42 | Header Files 43 | 44 | 45 | -------------------------------------------------------------------------------- /bzip2/mk251.c: -------------------------------------------------------------------------------- 1 | 2 | /* Spew out a long sequence of the byte 251. When fed to bzip2 3 | versions 1.0.0 or 1.0.1, causes it to die with internal error 4 | 1007 in blocksort.c. This assertion misses an extremely rare 5 | case, which is fixed in this version (1.0.2) and above. 6 | */ 7 | 8 | /* ------------------------------------------------------------------ 9 | This file is part of bzip2/libbzip2, a program and library for 10 | lossless, block-sorting data compression. 11 | 12 | bzip2/libbzip2 version 1.0.8 of 13 July 2019 13 | Copyright (C) 1996-2019 Julian Seward 14 | 15 | Please read the WARNING, DISCLAIMER and PATENTS sections in the 16 | README file. 17 | 18 | This program is released under the terms of the license contained 19 | in the file LICENSE. 20 | ------------------------------------------------------------------ */ 21 | 22 | 23 | #include 24 | 25 | int main () 26 | { 27 | int i; 28 | for (i = 0; i < 48500000 ; i++) 29 | putchar(251); 30 | return 0; 31 | } 32 | -------------------------------------------------------------------------------- /bzip2/spewG.c: -------------------------------------------------------------------------------- 1 | 2 | /* spew out a thoroughly gigantic file designed so that bzip2 3 | can compress it reasonably rapidly. This is to help test 4 | support for large files (> 2GB) in a reasonable amount of time. 5 | I suggest you use the undocumented --exponential option to 6 | bzip2 when compressing the resulting file; this saves a bit of 7 | time. Note: *don't* bother with --exponential when compressing 8 | Real Files; it'll just waste a lot of CPU time :-) 9 | (but is otherwise harmless). 10 | */ 11 | 12 | /* ------------------------------------------------------------------ 13 | This file is part of bzip2/libbzip2, a program and library for 14 | lossless, block-sorting data compression. 15 | 16 | bzip2/libbzip2 version 1.0.8 of 13 July 2019 17 | Copyright (C) 1996-2019 Julian Seward 18 | 19 | Please read the WARNING, DISCLAIMER and PATENTS sections in the 20 | README file. 21 | 22 | This program is released under the terms of the license contained 23 | in the file LICENSE. 24 | ------------------------------------------------------------------ */ 25 | 26 | 27 | #define _FILE_OFFSET_BITS 64 28 | 29 | #include 30 | #include 31 | 32 | /* The number of megabytes of junk to spew out (roughly) */ 33 | #define MEGABYTES 5000 34 | 35 | #define N_BUF 1000000 36 | char buf[N_BUF]; 37 | 38 | int main ( int argc, char** argv ) 39 | { 40 | int ii, kk, p; 41 | srandom(1); 42 | setbuffer ( stdout, buf, N_BUF ); 43 | for (kk = 0; kk < MEGABYTES * 515; kk+=3) { 44 | p = 25+random()%50; 45 | for (ii = 0; ii < p; ii++) 46 | printf ( "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" ); 47 | for (ii = 0; ii < p-1; ii++) 48 | printf ( "bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb" ); 49 | for (ii = 0; ii < p+1; ii++) 50 | printf ( "ccccccccccccccccccccccccccccccccccccc" ); 51 | } 52 | fflush(stdout); 53 | return 0; 54 | } 55 | -------------------------------------------------------------------------------- /libarchive/archive_cmdline_private.h: -------------------------------------------------------------------------------- 1 | /*- 2 | * Copyright (c) 2012 Michihiro NAKAJIMA 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 14 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR 15 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 16 | * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 17 | * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, 18 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 | * 25 | * $FreeBSD$ 26 | */ 27 | 28 | #ifndef ARCHIVE_CMDLINE_PRIVATE_H 29 | #define ARCHIVE_CMDLINE_PRIVATE_H 30 | 31 | #ifndef __LIBARCHIVE_BUILD 32 | #ifndef __LIBARCHIVE_TEST 33 | #error This header is only to be used internally to libarchive. 34 | #endif 35 | #endif 36 | 37 | struct archive_cmdline { 38 | char *path; 39 | char **argv; 40 | int argc; 41 | }; 42 | 43 | struct archive_cmdline *__archive_cmdline_allocate(void); 44 | int __archive_cmdline_parse(struct archive_cmdline *, const char *); 45 | int __archive_cmdline_free(struct archive_cmdline *); 46 | 47 | #endif 48 | -------------------------------------------------------------------------------- /libarchive/archive_getdate.h: -------------------------------------------------------------------------------- 1 | /*- 2 | * Copyright (c) 2003-2015 Tim Kientzle 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 14 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR 15 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 16 | * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 17 | * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, 18 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 | * 25 | * $FreeBSD$ 26 | */ 27 | 28 | #ifndef ARCHIVE_GETDATE_H_INCLUDED 29 | #define ARCHIVE_GETDATE_H_INCLUDED 30 | 31 | #ifndef __LIBARCHIVE_BUILD 32 | #error This header is only to be used internally to libarchive. 33 | #endif 34 | 35 | #include 36 | 37 | time_t __archive_get_date(time_t now, const char *); 38 | 39 | #endif 40 | -------------------------------------------------------------------------------- /libarchive/archive_openssl_evp_private.h: -------------------------------------------------------------------------------- 1 | /*- 2 | * Copyright (c) 2003-2007 Tim Kientzle 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 14 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR 15 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 16 | * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 17 | * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, 18 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 | */ 25 | 26 | #ifndef ARCHIVE_OPENSSL_EVP_PRIVATE_H_INCLUDED 27 | #define ARCHIVE_OPENSSL_EVP_PRIVATE_H_INCLUDED 28 | 29 | #ifndef __LIBARCHIVE_BUILD 30 | #error This header is only to be used internally to libarchive. 31 | #endif 32 | 33 | #include 34 | #include 35 | 36 | #if OPENSSL_VERSION_NUMBER < 0x10100000L 37 | #include /* malloc, free */ 38 | #include /* memset */ 39 | static inline EVP_MD_CTX *EVP_MD_CTX_new(void) 40 | { 41 | EVP_MD_CTX *ctx = (EVP_MD_CTX *)calloc(1, sizeof(EVP_MD_CTX)); 42 | return ctx; 43 | } 44 | 45 | static inline void EVP_MD_CTX_free(EVP_MD_CTX *ctx) 46 | { 47 | EVP_MD_CTX_cleanup(ctx); 48 | memset(ctx, 0, sizeof(*ctx)); 49 | free(ctx); 50 | } 51 | #endif 52 | 53 | #endif 54 | -------------------------------------------------------------------------------- /libarchive/archive_openssl_hmac_private.h: -------------------------------------------------------------------------------- 1 | /*- 2 | * Copyright (c) 2003-2007 Tim Kientzle 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 14 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR 15 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 16 | * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 17 | * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, 18 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 | */ 25 | 26 | #ifndef ARCHIVE_OPENSSL_HMAC_PRIVATE_H_INCLUDED 27 | #define ARCHIVE_OPENSSL_HMAC_PRIVATE_H_INCLUDED 28 | 29 | #ifndef __LIBARCHIVE_BUILD 30 | #error This header is only to be used internally to libarchive. 31 | #endif 32 | 33 | #include 34 | #include 35 | 36 | #if OPENSSL_VERSION_NUMBER < 0x10100000L || \ 37 | (defined(LIBRESSL_VERSION_NUMBER) && LIBRESSL_VERSION_NUMBER < 0x20700000L) 38 | #include /* malloc, free */ 39 | #include /* memset */ 40 | static inline HMAC_CTX *HMAC_CTX_new(void) 41 | { 42 | HMAC_CTX *ctx = (HMAC_CTX *)calloc(1, sizeof(HMAC_CTX)); 43 | return ctx; 44 | } 45 | 46 | static inline void HMAC_CTX_free(HMAC_CTX *ctx) 47 | { 48 | HMAC_CTX_cleanup(ctx); 49 | memset(ctx, 0, sizeof(*ctx)); 50 | free(ctx); 51 | } 52 | #endif 53 | 54 | #endif 55 | -------------------------------------------------------------------------------- /libarchive/archive_options_private.h: -------------------------------------------------------------------------------- 1 | /*- 2 | * Copyright (c) 2011 Tim Kientzle 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 14 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR 15 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 16 | * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 17 | * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, 18 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 | */ 25 | 26 | #ifndef ARCHIVE_OPTIONS_PRIVATE_H_INCLUDED 27 | #define ARCHIVE_OPTIONS_PRIVATE_H_INCLUDED 28 | 29 | #include "archive_platform.h" 30 | __FBSDID("$FreeBSD$"); 31 | 32 | #include "archive_private.h" 33 | 34 | typedef int (*option_handler)(struct archive *a, 35 | const char *mod, const char *opt, const char *val); 36 | 37 | int 38 | _archive_set_option(struct archive *a, 39 | const char *mod, const char *opt, const char *val, 40 | int magic, const char *fn, option_handler use_option); 41 | 42 | int 43 | _archive_set_options(struct archive *a, const char *options, 44 | int magic, const char *fn, option_handler use_option); 45 | 46 | int 47 | _archive_set_either_option(struct archive *a, 48 | const char *m, const char *o, const char *v, 49 | option_handler use_format_option, option_handler use_filter_option); 50 | 51 | #endif 52 | -------------------------------------------------------------------------------- /libarchive/archive_pack_dev.h: -------------------------------------------------------------------------------- 1 | /* $NetBSD: pack_dev.h,v 1.8 2013/06/14 16:28:20 tsutsui Exp $ */ 2 | 3 | /*- 4 | * Copyright (c) 1998, 2001 The NetBSD Foundation, Inc. 5 | * All rights reserved. 6 | * 7 | * This code is derived from software contributed to The NetBSD Foundation 8 | * by Charles M. Hannum. 9 | * 10 | * Redistribution and use in source and binary forms, with or without 11 | * modification, are permitted provided that the following conditions 12 | * are met: 13 | * 1. Redistributions of source code must retain the above copyright 14 | * notice, this list of conditions and the following disclaimer. 15 | * 2. Redistributions in binary form must reproduce the above copyright 16 | * notice, this list of conditions and the following disclaimer in the 17 | * documentation and/or other materials provided with the distribution. 18 | * 19 | * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS 20 | * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED 21 | * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 22 | * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS 23 | * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 24 | * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 25 | * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 26 | * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 27 | * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 28 | * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 29 | * POSSIBILITY OF SUCH DAMAGE. 30 | */ 31 | 32 | /* Originally from NetBSD's mknod(8) source. */ 33 | 34 | #ifndef ARCHIVE_PACK_DEV_H 35 | #define ARCHIVE_PACK_DEV_H 36 | 37 | typedef dev_t pack_t(int, unsigned long [], const char **); 38 | 39 | pack_t *pack_find(const char *); 40 | pack_t pack_native; 41 | 42 | #define major_netbsd(x) ((int32_t)((((x) & 0x000fff00) >> 8))) 43 | #define minor_netbsd(x) ((int32_t)((((x) & 0xfff00000) >> 12) | \ 44 | (((x) & 0x000000ff) >> 0))) 45 | #define makedev_netbsd(x,y) ((dev_t)((((x) << 8) & 0x000fff00) | \ 46 | (((y) << 12) & 0xfff00000) | \ 47 | (((y) << 0) & 0x000000ff))) 48 | 49 | #endif /* ARCHIVE_PACK_DEV_H */ 50 | -------------------------------------------------------------------------------- /libarchive/archive_platform_acl.h: -------------------------------------------------------------------------------- 1 | /*- 2 | * Copyright (c) 2017 Martin Matuska 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 14 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR 15 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 16 | * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 17 | * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, 18 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 | * 25 | * $FreeBSD$ 26 | */ 27 | 28 | /* !!ONLY FOR USE INTERNALLY TO LIBARCHIVE!! */ 29 | 30 | #ifndef ARCHIVE_PLATFORM_ACL_H_INCLUDED 31 | #define ARCHIVE_PLATFORM_ACL_H_INCLUDED 32 | 33 | #ifndef __LIBARCHIVE_BUILD 34 | #ifndef __LIBARCHIVE_TEST_COMMON 35 | #error This header is only to be used internally to libarchive. 36 | #endif 37 | #endif 38 | 39 | /* 40 | * Determine what ACL types are supported 41 | */ 42 | #if ARCHIVE_ACL_FREEBSD || ARCHIVE_ACL_SUNOS || ARCHIVE_ACL_LIBACL 43 | #define ARCHIVE_ACL_POSIX1E 1 44 | #endif 45 | 46 | #if ARCHIVE_ACL_FREEBSD_NFS4 || ARCHIVE_ACL_SUNOS_NFS4 || \ 47 | ARCHIVE_ACL_DARWIN || ARCHIVE_ACL_LIBRICHACL 48 | #define ARCHIVE_ACL_NFS4 1 49 | #endif 50 | 51 | #if ARCHIVE_ACL_POSIX1E || ARCHIVE_ACL_NFS4 52 | #define ARCHIVE_ACL_SUPPORT 1 53 | #endif 54 | 55 | #endif /* ARCHIVE_PLATFORM_ACL_H_INCLUDED */ 56 | -------------------------------------------------------------------------------- /libarchive/archive_platform_xattr.h: -------------------------------------------------------------------------------- 1 | /*- 2 | * Copyright (c) 2017 Martin Matuska 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 14 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR 15 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 16 | * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 17 | * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, 18 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 | * 25 | * $FreeBSD$ 26 | */ 27 | 28 | /* !!ONLY FOR USE INTERNALLY TO LIBARCHIVE!! */ 29 | 30 | #ifndef ARCHIVE_PLATFORM_XATTR_H_INCLUDED 31 | #define ARCHIVE_PLATFORM_XATTR_H_INCLUDED 32 | 33 | #ifndef __LIBARCHIVE_BUILD 34 | #ifndef __LIBARCHIVE_TEST_COMMON 35 | #error This header is only to be used internally to libarchive. 36 | #endif 37 | #endif 38 | 39 | /* 40 | * Determine if we support extended attributes 41 | */ 42 | #if ARCHIVE_XATTR_LINUX || ARCHIVE_XATTR_DARWIN || ARCHIVE_XATTR_FREEBSD || \ 43 | ARCHIVE_XATTR_AIX 44 | #define ARCHIVE_XATTR_SUPPORT 1 45 | #endif 46 | 47 | #endif /* ARCHIVE_PLATFORM_XATTR_H_INCLUDED */ 48 | -------------------------------------------------------------------------------- /libarchive/archive_random_private.h: -------------------------------------------------------------------------------- 1 | /*- 2 | * Copyright (c) 2014 Michihiro NAKAJIMA 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 14 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR 15 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 16 | * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 17 | * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, 18 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 | */ 25 | 26 | #ifndef ARCHIVE_RANDOM_PRIVATE_H_INCLUDED 27 | #define ARCHIVE_RANDOM_PRIVATE_H_INCLUDED 28 | 29 | #ifndef __LIBARCHIVE_BUILD 30 | #error This header is only to be used internally to libarchive. 31 | #endif 32 | 33 | /* Random number generator. */ 34 | int archive_random(void *buf, size_t nbytes); 35 | 36 | #endif /* ARCHIVE_RANDOM_PRIVATE_H_INCLUDED */ 37 | -------------------------------------------------------------------------------- /libarchive/archive_read_support_filter_none.c: -------------------------------------------------------------------------------- 1 | /*- 2 | * Copyright (c) 2003-2007 Tim Kientzle 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 14 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR 15 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 16 | * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 17 | * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, 18 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 | */ 25 | 26 | #include "archive_platform.h" 27 | __FBSDID("$FreeBSD$"); 28 | 29 | #include "archive.h" 30 | #include "archive_private.h" 31 | 32 | #if ARCHIVE_VERSION_NUMBER < 4000000 33 | /* Deprecated; remove in libarchive 4.0 */ 34 | int 35 | archive_read_support_compression_none(struct archive *a) 36 | { 37 | return archive_read_support_filter_none(a); 38 | } 39 | #endif 40 | 41 | /* 42 | * Uncompressed streams are handled implicitly by the read core, 43 | * so this is now a no-op. 44 | */ 45 | int 46 | archive_read_support_filter_none(struct archive *a) 47 | { 48 | archive_check_magic(a, ARCHIVE_READ_MAGIC, 49 | ARCHIVE_STATE_NEW, "archive_read_support_filter_none"); 50 | 51 | return (ARCHIVE_OK); 52 | } 53 | -------------------------------------------------------------------------------- /libarchive/archive_write_add_filter_none.c: -------------------------------------------------------------------------------- 1 | /*- 2 | * Copyright (c) 2003-2010 Tim Kientzle 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 14 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR 15 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 16 | * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 17 | * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, 18 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 | */ 25 | 26 | #include "archive_platform.h" 27 | __FBSDID("$FreeBSD: head/lib/libarchive/archive_write_set_compression_none.c 201080 2009-12-28 02:03:54Z kientzle $"); 28 | 29 | #include "archive.h" 30 | 31 | int 32 | archive_write_set_compression_none(struct archive *a) 33 | { 34 | (void)a; /* UNUSED */ 35 | return (ARCHIVE_OK); 36 | } 37 | 38 | int 39 | archive_write_add_filter_none(struct archive *a) 40 | { 41 | (void)a; /* UNUSED */ 42 | return (ARCHIVE_OK); 43 | } 44 | -------------------------------------------------------------------------------- /libarchive/archive_write_disk_private.h: -------------------------------------------------------------------------------- 1 | /*- 2 | * Copyright (c) 2003-2007 Tim Kientzle 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer 10 | * in this position and unchanged. 11 | * 2. Redistributions in binary form must reproduce the above copyright 12 | * notice, this list of conditions and the following disclaimer in the 13 | * documentation and/or other materials provided with the distribution. 14 | * 15 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR 16 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 17 | * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 18 | * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, 19 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 20 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 21 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 22 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 23 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 24 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 25 | * 26 | * $FreeBSD: head/lib/libarchive/archive_write_disk_private.h 201086 2009-12-28 02:17:53Z kientzle $ 27 | */ 28 | 29 | #ifndef ARCHIVE_WRITE_DISK_PRIVATE_H_INCLUDED 30 | #define ARCHIVE_WRITE_DISK_PRIVATE_H_INCLUDED 31 | 32 | #ifndef __LIBARCHIVE_BUILD 33 | #error This header is only to be used internally to libarchive. 34 | #endif 35 | 36 | #include "archive_platform_acl.h" 37 | #include "archive_acl_private.h" 38 | #include "archive_entry.h" 39 | 40 | struct archive_write_disk; 41 | 42 | int archive_write_disk_set_acls(struct archive *, int, const char *, 43 | struct archive_acl *, __LA_MODE_T); 44 | 45 | #endif 46 | -------------------------------------------------------------------------------- /libarchive/archive_write_set_format_cpio.c: -------------------------------------------------------------------------------- 1 | #include "archive.h" 2 | 3 | /* 4 | * Set output format to the default 'cpio' format. 5 | */ 6 | int 7 | archive_write_set_format_cpio(struct archive *_a) 8 | { 9 | return archive_write_set_format_cpio_odc(_a); 10 | } 11 | -------------------------------------------------------------------------------- /libarchive/archive_write_set_format_private.h: -------------------------------------------------------------------------------- 1 | /*- 2 | * Copyright (c) 2020 Martin Matuska 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 14 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR 15 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 16 | * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 17 | * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, 18 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 | * 25 | * $FreeBSD$ 26 | */ 27 | 28 | #ifndef ARCHIVE_WRITE_SET_FORMAT_PRIVATE_H_INCLUDED 29 | #define ARCHIVE_WRITE_SET_FORMAT_PRIVATE_H_INCLUDED 30 | 31 | #ifndef __LIBARCHIVE_BUILD 32 | #ifndef __LIBARCHIVE_TEST 33 | #error This header is only to be used internally to libarchive. 34 | #endif 35 | #endif 36 | 37 | #include "archive.h" 38 | #include "archive_entry.h" 39 | 40 | void __archive_write_entry_filetype_unsupported(struct archive *a, 41 | struct archive_entry *entry, const char *format); 42 | #endif 43 | -------------------------------------------------------------------------------- /libarchive/archive_xxhash.h: -------------------------------------------------------------------------------- 1 | /*- 2 | * Copyright (c) 2014 Michihiro NAKAJIMA 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 14 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR 15 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 16 | * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 17 | * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, 18 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 | * 25 | */ 26 | 27 | #ifndef ARCHIVE_XXHASH_H_INCLUDED 28 | #define ARCHIVE_XXHASH_H_INCLUDED 29 | 30 | #ifndef __LIBARCHIVE_BUILD 31 | #error This header is only to be used internally to libarchive. 32 | #endif 33 | 34 | 35 | typedef enum { XXH_OK=0, XXH_ERROR } XXH_errorcode; 36 | 37 | struct archive_xxhash { 38 | unsigned int (*XXH32)(const void* input, unsigned int len, 39 | unsigned int seed); 40 | void* (*XXH32_init)(unsigned int seed); 41 | XXH_errorcode (*XXH32_update)(void* state, const void* input, 42 | unsigned int len); 43 | unsigned int (*XXH32_digest)(void* state); 44 | }; 45 | 46 | extern const struct archive_xxhash __archive_xxhash; 47 | 48 | #endif 49 | -------------------------------------------------------------------------------- /libarchive/filter_fork.h: -------------------------------------------------------------------------------- 1 | /*- 2 | * Copyright (c) 2007 Joerg Sonnenberger 3 | * All rights reserved. 4 | * 5 | * Redistribution and use in source and binary forms, with or without 6 | * modification, are permitted provided that the following conditions 7 | * are met: 8 | * 1. Redistributions of source code must retain the above copyright 9 | * notice, this list of conditions and the following disclaimer. 10 | * 2. Redistributions in binary form must reproduce the above copyright 11 | * notice, this list of conditions and the following disclaimer in the 12 | * documentation and/or other materials provided with the distribution. 13 | * 14 | * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR 15 | * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 16 | * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 17 | * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT, 18 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 19 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 20 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 21 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 22 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 23 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 24 | * 25 | * $FreeBSD: head/lib/libarchive/filter_fork.h 201087 2009-12-28 02:18:26Z kientzle $ 26 | */ 27 | 28 | #ifndef FILTER_FORK_H 29 | #define FILTER_FORK_H 30 | 31 | #ifndef __LIBARCHIVE_BUILD 32 | #error This header is only to be used internally to libarchive. 33 | #endif 34 | 35 | int 36 | __archive_create_child(const char *cmd, int *child_stdin, int *child_stdout, 37 | #if defined(_WIN32) && !defined(__CYGWIN__) 38 | HANDLE *out_child); 39 | #else 40 | pid_t *out_child); 41 | #endif 42 | 43 | void 44 | __archive_check_child(int in, int out); 45 | 46 | #endif 47 | -------------------------------------------------------------------------------- /minizip/Makefile: -------------------------------------------------------------------------------- 1 | CC=cc 2 | CFLAGS=-O -I../.. 3 | 4 | UNZ_OBJS = miniunz.o unzip.o ioapi.o ../../libz.a 5 | ZIP_OBJS = minizip.o zip.o ioapi.o ../../libz.a 6 | 7 | .c.o: 8 | $(CC) -c $(CFLAGS) $*.c 9 | 10 | all: miniunz minizip 11 | 12 | miniunz: $(UNZ_OBJS) 13 | $(CC) $(CFLAGS) -o $@ $(UNZ_OBJS) 14 | 15 | minizip: $(ZIP_OBJS) 16 | $(CC) $(CFLAGS) -o $@ $(ZIP_OBJS) 17 | 18 | test: miniunz minizip 19 | ./minizip test readme.txt 20 | ./miniunz -l test.zip 21 | mv readme.txt readme.old 22 | ./miniunz test.zip 23 | 24 | clean: 25 | /bin/rm -f *.o *~ minizip miniunz 26 | -------------------------------------------------------------------------------- /minizip/Makefile.am: -------------------------------------------------------------------------------- 1 | lib_LTLIBRARIES = libminizip.la 2 | 3 | if COND_DEMOS 4 | bin_PROGRAMS = miniunzip minizip 5 | endif 6 | 7 | zlib_top_srcdir = $(top_srcdir)/../.. 8 | zlib_top_builddir = $(top_builddir)/../.. 9 | 10 | AM_CPPFLAGS = -I$(zlib_top_srcdir) 11 | AM_LDFLAGS = -L$(zlib_top_builddir) 12 | 13 | if WIN32 14 | iowin32_src = iowin32.c 15 | iowin32_h = iowin32.h 16 | endif 17 | 18 | libminizip_la_SOURCES = \ 19 | ioapi.c \ 20 | mztools.c \ 21 | unzip.c \ 22 | zip.c \ 23 | ${iowin32_src} 24 | 25 | libminizip_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 -lz 26 | 27 | minizip_includedir = $(includedir)/minizip 28 | minizip_include_HEADERS = \ 29 | crypt.h \ 30 | ioapi.h \ 31 | mztools.h \ 32 | unzip.h \ 33 | zip.h \ 34 | ${iowin32_h} 35 | 36 | pkgconfigdir = $(libdir)/pkgconfig 37 | pkgconfig_DATA = minizip.pc 38 | 39 | EXTRA_PROGRAMS = miniunzip minizip 40 | 41 | miniunzip_SOURCES = miniunz.c 42 | miniunzip_LDADD = libminizip.la 43 | 44 | minizip_SOURCES = minizip.c 45 | minizip_LDADD = libminizip.la -lz 46 | -------------------------------------------------------------------------------- /minizip/MiniZip64_Changes.txt: -------------------------------------------------------------------------------- 1 | 2 | MiniZip 1.1 was derrived from MiniZip at version 1.01f 3 | 4 | Change in 1.0 (Okt 2009) 5 | - **TODO - Add history** 6 | 7 | -------------------------------------------------------------------------------- /minizip/configure.ac: -------------------------------------------------------------------------------- 1 | # -*- Autoconf -*- 2 | # Process this file with autoconf to produce a configure script. 3 | 4 | AC_INIT([minizip], [1.2.11], [bugzilla.redhat.com]) 5 | AC_CONFIG_SRCDIR([minizip.c]) 6 | AM_INIT_AUTOMAKE([foreign]) 7 | LT_INIT 8 | 9 | AC_MSG_CHECKING([whether to build example programs]) 10 | AC_ARG_ENABLE([demos], AC_HELP_STRING([--enable-demos], [build example programs])) 11 | AM_CONDITIONAL([COND_DEMOS], [test "$enable_demos" = yes]) 12 | if test "$enable_demos" = yes 13 | then 14 | AC_MSG_RESULT([yes]) 15 | else 16 | AC_MSG_RESULT([no]) 17 | fi 18 | 19 | case "${host}" in 20 | *-mingw* | mingw*) 21 | WIN32="yes" 22 | ;; 23 | *) 24 | ;; 25 | esac 26 | AM_CONDITIONAL([WIN32], [test "${WIN32}" = "yes"]) 27 | 28 | 29 | AC_SUBST([HAVE_UNISTD_H], [0]) 30 | AC_CHECK_HEADER([unistd.h], [HAVE_UNISTD_H=1], []) 31 | AC_CONFIG_FILES([Makefile minizip.pc]) 32 | AC_OUTPUT 33 | -------------------------------------------------------------------------------- /minizip/iowin32.h: -------------------------------------------------------------------------------- 1 | /* iowin32.h -- IO base function header for compress/uncompress .zip 2 | Version 1.1, February 14h, 2010 3 | part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) 4 | 5 | Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) 6 | 7 | Modifications for Zip64 support 8 | Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) 9 | 10 | For more info read MiniZip_info.txt 11 | 12 | */ 13 | 14 | #include 15 | 16 | 17 | #ifdef __cplusplus 18 | extern "C" { 19 | #endif 20 | 21 | void fill_win32_filefunc OF((zlib_filefunc_def* pzlib_filefunc_def)); 22 | void fill_win32_filefunc64 OF((zlib_filefunc64_def* pzlib_filefunc_def)); 23 | void fill_win32_filefunc64A OF((zlib_filefunc64_def* pzlib_filefunc_def)); 24 | void fill_win32_filefunc64W OF((zlib_filefunc64_def* pzlib_filefunc_def)); 25 | 26 | #ifdef __cplusplus 27 | } 28 | #endif 29 | -------------------------------------------------------------------------------- /minizip/make_vms.com: -------------------------------------------------------------------------------- 1 | $ if f$search("ioapi.h_orig") .eqs. "" then copy ioapi.h ioapi.h_orig 2 | $ open/write zdef vmsdefs.h 3 | $ copy sys$input: zdef 4 | $ deck 5 | #define unix 6 | #define fill_zlib_filefunc64_32_def_from_filefunc32 fillzffunc64from 7 | #define Write_Zip64EndOfCentralDirectoryLocator Write_Zip64EoDLocator 8 | #define Write_Zip64EndOfCentralDirectoryRecord Write_Zip64EoDRecord 9 | #define Write_EndOfCentralDirectoryRecord Write_EoDRecord 10 | $ eod 11 | $ close zdef 12 | $ copy vmsdefs.h,ioapi.h_orig ioapi.h 13 | $ cc/include=[--]/prefix=all ioapi.c 14 | $ cc/include=[--]/prefix=all miniunz.c 15 | $ cc/include=[--]/prefix=all unzip.c 16 | $ cc/include=[--]/prefix=all minizip.c 17 | $ cc/include=[--]/prefix=all zip.c 18 | $ link miniunz,unzip,ioapi,[--]libz.olb/lib 19 | $ link minizip,zip,ioapi,[--]libz.olb/lib 20 | $ mcr []minizip test minizip_info.txt 21 | $ mcr []miniunz -l test.zip 22 | $ rename minizip_info.txt; minizip_info.txt_old 23 | $ mcr []miniunz test.zip 24 | $ delete test.zip;* 25 | $exit 26 | -------------------------------------------------------------------------------- /minizip/miniunzip.1: -------------------------------------------------------------------------------- 1 | .\" Hey, EMACS: -*- nroff -*- 2 | .TH miniunzip 1 "Nov 7, 2001" 3 | .\" Please adjust this date whenever revising the manpage. 4 | .\" 5 | .\" Some roff macros, for reference: 6 | .\" .nh disable hyphenation 7 | .\" .hy enable hyphenation 8 | .\" .ad l left justify 9 | .\" .ad b justify to both left and right margins 10 | .\" .nf disable filling 11 | .\" .fi enable filling 12 | .\" .br insert line break 13 | .\" .sp insert n+1 empty lines 14 | .\" for manpage-specific macros, see man(7) 15 | .SH NAME 16 | miniunzip - uncompress and examine ZIP archives 17 | .SH SYNOPSIS 18 | .B miniunzip 19 | .RI [ -exvlo ] 20 | zipfile [ files_to_extract ] [-d tempdir] 21 | .SH DESCRIPTION 22 | .B minizip 23 | is a simple tool which allows the extraction of compressed file 24 | archives in the ZIP format used by the MS-DOS utility PKZIP. It was 25 | written as a demonstration of the 26 | .IR zlib (3) 27 | library and therefore lack many of the features of the 28 | .IR unzip (1) 29 | program. 30 | .SH OPTIONS 31 | A number of options are supported. With the exception of 32 | .BI \-d\ tempdir 33 | these must be supplied before any 34 | other arguments and are: 35 | .TP 36 | .BI \-l\ ,\ \-\-v 37 | List the files in the archive without extracting them. 38 | .TP 39 | .B \-o 40 | Overwrite files without prompting for confirmation. 41 | .TP 42 | .B \-x 43 | Extract files (default). 44 | .PP 45 | The 46 | .I zipfile 47 | argument is the name of the archive to process. The next argument can be used 48 | to specify a single file to extract from the archive. 49 | 50 | Lastly, the following option can be specified at the end of the command-line: 51 | .TP 52 | .BI \-d\ tempdir 53 | Extract the archive in the directory 54 | .I tempdir 55 | rather than the current directory. 56 | .SH SEE ALSO 57 | .BR minizip (1), 58 | .BR zlib (3), 59 | .BR unzip (1). 60 | .SH AUTHOR 61 | This program was written by Gilles Vollant. This manual page was 62 | written by Mark Brown . The -d tempdir option 63 | was added by Dirk Eddelbuettel . 64 | -------------------------------------------------------------------------------- /minizip/minizip.1: -------------------------------------------------------------------------------- 1 | .\" Hey, EMACS: -*- nroff -*- 2 | .TH minizip 1 "May 2, 2001" 3 | .\" Please adjust this date whenever revising the manpage. 4 | .\" 5 | .\" Some roff macros, for reference: 6 | .\" .nh disable hyphenation 7 | .\" .hy enable hyphenation 8 | .\" .ad l left justify 9 | .\" .ad b justify to both left and right margins 10 | .\" .nf disable filling 11 | .\" .fi enable filling 12 | .\" .br insert line break 13 | .\" .sp insert n+1 empty lines 14 | .\" for manpage-specific macros, see man(7) 15 | .SH NAME 16 | minizip - create ZIP archives 17 | .SH SYNOPSIS 18 | .B minizip 19 | .RI [ -o ] 20 | zipfile [ " files" ... ] 21 | .SH DESCRIPTION 22 | .B minizip 23 | is a simple tool which allows the creation of compressed file archives 24 | in the ZIP format used by the MS-DOS utility PKZIP. It was written as 25 | a demonstration of the 26 | .IR zlib (3) 27 | library and therefore lack many of the features of the 28 | .IR zip (1) 29 | program. 30 | .SH OPTIONS 31 | The first argument supplied is the name of the ZIP archive to create or 32 | .RI -o 33 | in which case it is ignored and the second argument treated as the 34 | name of the ZIP file. If the ZIP file already exists it will be 35 | overwritten. 36 | .PP 37 | Subsequent arguments specify a list of files to place in the ZIP 38 | archive. If none are specified then an empty archive will be created. 39 | .SH SEE ALSO 40 | .BR miniunzip (1), 41 | .BR zlib (3), 42 | .BR zip (1). 43 | .SH AUTHOR 44 | This program was written by Gilles Vollant. This manual page was 45 | written by Mark Brown . 46 | 47 | -------------------------------------------------------------------------------- /minizip/minizip.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@/minizip 5 | 6 | Name: minizip 7 | Description: Minizip zip file manipulation library 8 | Requires: 9 | Version: @PACKAGE_VERSION@ 10 | Libs: -L${libdir} -lminizip 11 | Libs.private: -lz 12 | Cflags: -I${includedir} 13 | -------------------------------------------------------------------------------- /minizip/minizip.vcxproj.user: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | -------------------------------------------------------------------------------- /minizip/mztools.h: -------------------------------------------------------------------------------- 1 | /* 2 | Additional tools for Minizip 3 | Code: Xavier Roche '2004 4 | License: Same as ZLIB (www.gzip.org) 5 | */ 6 | 7 | #ifndef _zip_tools_H 8 | #define _zip_tools_H 9 | 10 | #ifdef __cplusplus 11 | extern "C" { 12 | #endif 13 | 14 | #ifndef _ZLIB_H 15 | #include "zlib.h" 16 | #endif 17 | 18 | #include "unzip.h" 19 | 20 | /* Repair a ZIP file (missing central directory) 21 | file: file to recover 22 | fileOut: output file after recovery 23 | fileOutTmp: temporary file name used for recovery 24 | */ 25 | extern int ZEXPORT unzRepair(const char* file, 26 | const char* fileOut, 27 | const char* fileOutTmp, 28 | uLong* nRecovered, 29 | uLong* bytesRecovered); 30 | 31 | 32 | #ifdef __cplusplus 33 | } 34 | #endif 35 | 36 | 37 | #endif 38 | -------------------------------------------------------------------------------- /minizip/zlib.rc: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #define IDR_VERSION1 1 4 | IDR_VERSION1 VERSIONINFO MOVEABLE IMPURE LOADONCALL DISCARDABLE 5 | FILEVERSION 1, 2, 11, 0 6 | PRODUCTVERSION 1, 2, 11, 0 7 | FILEFLAGSMASK VS_FFI_FILEFLAGSMASK 8 | FILEFLAGS 0 9 | FILEOS VOS_DOS_WINDOWS32 10 | FILETYPE VFT_DLL 11 | FILESUBTYPE 0 // not used 12 | BEGIN 13 | BLOCK "StringFileInfo" 14 | BEGIN 15 | BLOCK "040904E4" 16 | //language ID = U.S. English, char set = Windows, Multilingual 17 | 18 | BEGIN 19 | VALUE "FileDescription", "zlib data compression and ZIP file I/O library\0" 20 | VALUE "FileVersion", "1.2.11\0" 21 | VALUE "InternalName", "zlib\0" 22 | VALUE "OriginalFilename", "zlibwapi.dll\0" 23 | VALUE "ProductName", "ZLib.DLL\0" 24 | VALUE "Comments","DLL support by Alessandro Iacopetti & Gilles Vollant\0" 25 | VALUE "LegalCopyright", "(C) 1995-2017 Jean-loup Gailly & Mark Adler\0" 26 | END 27 | END 28 | BLOCK "VarFileInfo" 29 | BEGIN 30 | VALUE "Translation", 0x0409, 1252 31 | END 32 | END 33 | -------------------------------------------------------------------------------- /rapidjson/.gitattributes: -------------------------------------------------------------------------------- 1 | # Set the default behavior, in case people don't have core.autocrlf set. 2 | * text=auto 3 | 4 | # Explicitly declare text files you want to always be normalized and converted 5 | # to native line endings on checkout. 6 | *.cpp text 7 | *.h text 8 | *.txt text 9 | *.md text 10 | *.cmake text 11 | *.svg text 12 | *.dot text 13 | *.yml text 14 | *.in text 15 | *.sh text 16 | *.autopkg text 17 | Dockerfile text 18 | 19 | # Denote all files that are truly binary and should not be modified. 20 | *.png binary 21 | *.jpg binary 22 | *.json binary -------------------------------------------------------------------------------- /rapidjson/.gitignore: -------------------------------------------------------------------------------- 1 | /bin/* 2 | !/bin/data 3 | !/bin/encodings 4 | !/bin/jsonchecker 5 | !/bin/types 6 | !/bin/unittestschema 7 | /build 8 | /doc/html 9 | /doc/doxygen_*.db 10 | *.a 11 | 12 | # Temporary files created during CMake build 13 | CMakeCache.txt 14 | CMakeFiles 15 | cmake_install.cmake 16 | CTestTestfile.cmake 17 | Makefile 18 | RapidJSON*.cmake 19 | RapidJSON.pc 20 | Testing 21 | /googletest 22 | install_manifest.txt 23 | Doxyfile 24 | Doxyfile.zh-cn 25 | DartConfiguration.tcl 26 | *.nupkg 27 | 28 | # Files created by OS 29 | *.DS_Store 30 | -------------------------------------------------------------------------------- /rapidjson/.gitmodules: -------------------------------------------------------------------------------- 1 | [submodule "thirdparty/gtest"] 2 | path = thirdparty/gtest 3 | url = https://github.com/google/googletest.git 4 | -------------------------------------------------------------------------------- /rapidjson/CMakeModules/FindGTestSrc.cmake: -------------------------------------------------------------------------------- 1 | 2 | SET(GTEST_SEARCH_PATH 3 | "${GTEST_SOURCE_DIR}" 4 | "${CMAKE_CURRENT_LIST_DIR}/../thirdparty/gtest/googletest") 5 | 6 | IF(UNIX) 7 | IF(RAPIDJSON_BUILD_THIRDPARTY_GTEST) 8 | LIST(APPEND GTEST_SEARCH_PATH "/usr/src/gtest") 9 | ELSE() 10 | LIST(INSERT GTEST_SEARCH_PATH 1 "/usr/src/gtest") 11 | ENDIF() 12 | ENDIF() 13 | 14 | FIND_PATH(GTEST_SOURCE_DIR 15 | NAMES CMakeLists.txt src/gtest_main.cc 16 | PATHS ${GTEST_SEARCH_PATH}) 17 | 18 | 19 | # Debian installs gtest include directory in /usr/include, thus need to look 20 | # for include directory separately from source directory. 21 | FIND_PATH(GTEST_INCLUDE_DIR 22 | NAMES gtest/gtest.h 23 | PATH_SUFFIXES include 24 | HINTS ${GTEST_SOURCE_DIR} 25 | PATHS ${GTEST_SEARCH_PATH}) 26 | 27 | INCLUDE(FindPackageHandleStandardArgs) 28 | find_package_handle_standard_args(GTestSrc DEFAULT_MSG 29 | GTEST_SOURCE_DIR 30 | GTEST_INCLUDE_DIR) 31 | -------------------------------------------------------------------------------- /rapidjson/RapidJSON.pc.in: -------------------------------------------------------------------------------- 1 | includedir=@INCLUDE_INSTALL_DIR@ 2 | 3 | Name: @PROJECT_NAME@ 4 | Description: A fast JSON parser/generator for C++ with both SAX/DOM style API 5 | Version: @LIB_VERSION_STRING@ 6 | URL: https://github.com/Tencent/rapidjson 7 | Cflags: -I${includedir} 8 | -------------------------------------------------------------------------------- /rapidjson/RapidJSONConfig.cmake.in: -------------------------------------------------------------------------------- 1 | ################################################################################ 2 | # CMake minimum version required 3 | cmake_minimum_required(VERSION 3.0) 4 | 5 | ################################################################################ 6 | # RapidJSON source dir 7 | set( RapidJSON_SOURCE_DIR "@CONFIG_SOURCE_DIR@") 8 | 9 | ################################################################################ 10 | # RapidJSON build dir 11 | set( RapidJSON_DIR "@CONFIG_DIR@") 12 | 13 | ################################################################################ 14 | # Compute paths 15 | get_filename_component(RapidJSON_CMAKE_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH) 16 | 17 | set( RapidJSON_INCLUDE_DIR "@RapidJSON_INCLUDE_DIR@" ) 18 | set( RapidJSON_INCLUDE_DIRS "@RapidJSON_INCLUDE_DIR@" ) 19 | message(STATUS "RapidJSON found. Headers: ${RapidJSON_INCLUDE_DIRS}") 20 | 21 | if(NOT TARGET rapidjson) 22 | add_library(rapidjson INTERFACE IMPORTED) 23 | set_property(TARGET rapidjson PROPERTY 24 | INTERFACE_INCLUDE_DIRECTORIES ${RapidJSON_INCLUDE_DIRS}) 25 | endif() 26 | -------------------------------------------------------------------------------- /rapidjson/RapidJSONConfigVersion.cmake.in: -------------------------------------------------------------------------------- 1 | SET(PACKAGE_VERSION "@LIB_VERSION_STRING@") 2 | 3 | IF (PACKAGE_FIND_VERSION VERSION_EQUAL PACKAGE_VERSION) 4 | SET(PACKAGE_VERSION_EXACT "true") 5 | ENDIF (PACKAGE_FIND_VERSION VERSION_EQUAL PACKAGE_VERSION) 6 | IF (NOT PACKAGE_FIND_VERSION VERSION_GREATER PACKAGE_VERSION) 7 | SET(PACKAGE_VERSION_COMPATIBLE "true") 8 | ELSE (NOT PACKAGE_FIND_VERSION VERSION_GREATER PACKAGE_VERSION) 9 | SET(PACKAGE_VERSION_UNSUITABLE "true") 10 | ENDIF (NOT PACKAGE_FIND_VERSION VERSION_GREATER PACKAGE_VERSION) 11 | -------------------------------------------------------------------------------- /rapidjson/appveyor.yml: -------------------------------------------------------------------------------- 1 | version: 1.1.0.{build} 2 | 3 | configuration: 4 | - Debug 5 | - Release 6 | 7 | environment: 8 | matrix: 9 | # - VS_VERSION: 9 2008 10 | # VS_PLATFORM: win32 11 | # - VS_VERSION: 9 2008 12 | # VS_PLATFORM: x64 13 | - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2013 14 | VS_VERSION: 10 2010 15 | VS_PLATFORM: win32 16 | - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2013 17 | VS_VERSION: 10 2010 18 | VS_PLATFORM: x64 19 | - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2013 20 | VS_VERSION: 11 2012 21 | VS_PLATFORM: win32 22 | - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2013 23 | VS_VERSION: 11 2012 24 | VS_PLATFORM: x64 25 | - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2013 26 | VS_VERSION: 12 2013 27 | VS_PLATFORM: win32 28 | - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2013 29 | VS_VERSION: 12 2013 30 | VS_PLATFORM: x64 31 | - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015 32 | VS_VERSION: 14 2015 33 | VS_PLATFORM: win32 34 | - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2015 35 | VS_VERSION: 14 2015 36 | VS_PLATFORM: x64 37 | - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017 38 | VS_VERSION: 15 2017 39 | VS_PLATFORM: win32 40 | - APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017 41 | VS_VERSION: 15 2017 42 | VS_PLATFORM: x64 43 | 44 | before_build: 45 | - git submodule update --init --recursive 46 | - cmake -H. -BBuild/VS -G "Visual Studio %VS_VERSION%" -DCMAKE_GENERATOR_PLATFORM=%VS_PLATFORM% -DCMAKE_VERBOSE_MAKEFILE=ON -DBUILD_SHARED_LIBS=true -Wno-dev 47 | 48 | build: 49 | project: Build\VS\RapidJSON.sln 50 | parallel: true 51 | verbosity: minimal 52 | 53 | test_script: 54 | - cd Build\VS && if %CONFIGURATION%==Debug (ctest --verbose -E perftest --build-config %CONFIGURATION%) else (ctest --verbose --build-config %CONFIGURATION%) 55 | -------------------------------------------------------------------------------- /rapidjson/bin/data/abcde.txt: -------------------------------------------------------------------------------- 1 | abcde -------------------------------------------------------------------------------- /rapidjson/bin/data/glossary.json: -------------------------------------------------------------------------------- 1 | { 2 | "glossary": { 3 | "title": "example glossary", 4 | "GlossDiv": { 5 | "title": "S", 6 | "GlossList": { 7 | "GlossEntry": { 8 | "ID": "SGML", 9 | "SortAs": "SGML", 10 | "GlossTerm": "Standard Generalized Markup Language", 11 | "Acronym": "SGML", 12 | "Abbrev": "ISO 8879:1986", 13 | "GlossDef": { 14 | "para": "A meta-markup language, used to create markup languages such as DocBook.", 15 | "GlossSeeAlso": ["GML", "XML"] 16 | }, 17 | "GlossSee": "markup" 18 | } 19 | } 20 | } 21 | } 22 | } -------------------------------------------------------------------------------- /rapidjson/bin/data/menu.json: -------------------------------------------------------------------------------- 1 | {"menu": { 2 | "header": "SVG Viewer", 3 | "items": [ 4 | {"id": "Open"}, 5 | {"id": "OpenNew", "label": "Open New"}, 6 | null, 7 | {"id": "ZoomIn", "label": "Zoom In"}, 8 | {"id": "ZoomOut", "label": "Zoom Out"}, 9 | {"id": "OriginalView", "label": "Original View"}, 10 | null, 11 | {"id": "Quality"}, 12 | {"id": "Pause"}, 13 | {"id": "Mute"}, 14 | null, 15 | {"id": "Find", "label": "Find..."}, 16 | {"id": "FindAgain", "label": "Find Again"}, 17 | {"id": "Copy"}, 18 | {"id": "CopyAgain", "label": "Copy Again"}, 19 | {"id": "CopySVG", "label": "Copy SVG"}, 20 | {"id": "ViewSVG", "label": "View SVG"}, 21 | {"id": "ViewSource", "label": "View Source"}, 22 | {"id": "SaveAs", "label": "Save As"}, 23 | null, 24 | {"id": "Help"}, 25 | {"id": "About", "label": "About Adobe CVG Viewer..."} 26 | ] 27 | }} -------------------------------------------------------------------------------- /rapidjson/bin/data/readme.txt: -------------------------------------------------------------------------------- 1 | sample.json is obtained from http://code.google.com/p/json-test-suite/downloads/detail?name=sample.zip 2 | -------------------------------------------------------------------------------- /rapidjson/bin/data/widget.json: -------------------------------------------------------------------------------- 1 | {"widget": { 2 | "debug": "on", 3 | "window": { 4 | "title": "Sample Konfabulator Widget", 5 | "name": "main_window", 6 | "width": 500, 7 | "height": 500 8 | }, 9 | "image": { 10 | "src": "Images/Sun.png", 11 | "name": "sun1", 12 | "hOffset": 250, 13 | "vOffset": 250, 14 | "alignment": "center" 15 | }, 16 | "text": { 17 | "data": "Click Here", 18 | "size": 36, 19 | "style": "bold", 20 | "name": "text1", 21 | "hOffset": 250, 22 | "vOffset": 100, 23 | "alignment": "center", 24 | "onMouseUp": "sun1.opacity = (sun1.opacity / 100) * 90;" 25 | } 26 | }} -------------------------------------------------------------------------------- /rapidjson/bin/encodings/utf16be.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/bin/encodings/utf16be.json -------------------------------------------------------------------------------- /rapidjson/bin/encodings/utf16bebom.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/bin/encodings/utf16bebom.json -------------------------------------------------------------------------------- /rapidjson/bin/encodings/utf16le.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/bin/encodings/utf16le.json -------------------------------------------------------------------------------- /rapidjson/bin/encodings/utf16lebom.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/bin/encodings/utf16lebom.json -------------------------------------------------------------------------------- /rapidjson/bin/encodings/utf32be.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/bin/encodings/utf32be.json -------------------------------------------------------------------------------- /rapidjson/bin/encodings/utf32bebom.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/bin/encodings/utf32bebom.json -------------------------------------------------------------------------------- /rapidjson/bin/encodings/utf32le.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/bin/encodings/utf32le.json -------------------------------------------------------------------------------- /rapidjson/bin/encodings/utf32lebom.json: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/bin/encodings/utf32lebom.json -------------------------------------------------------------------------------- /rapidjson/bin/encodings/utf8.json: -------------------------------------------------------------------------------- 1 | { 2 | "en":"I can eat glass and it doesn't hurt me.", 3 | "zh-Hant":"我能吞下玻璃而不傷身體。", 4 | "zh-Hans":"我能吞下玻璃而不伤身体。", 5 | "ja":"私はガラスを食べられます。それは私を傷つけません。", 6 | "ko":"나는 유리를 먹을 수 있어요. 그래도 아프지 않아요" 7 | } -------------------------------------------------------------------------------- /rapidjson/bin/encodings/utf8bom.json: -------------------------------------------------------------------------------- 1 | { 2 | "en":"I can eat glass and it doesn't hurt me.", 3 | "zh-Hant":"我能吞下玻璃而不傷身體。", 4 | "zh-Hans":"我能吞下玻璃而不伤身体。", 5 | "ja":"私はガラスを食べられます。それは私を傷つけません。", 6 | "ko":"나는 유리를 먹을 수 있어요. 그래도 아프지 않아요" 7 | } -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail1.json: -------------------------------------------------------------------------------- 1 | "A JSON payload should be an object or array, not a string." -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail10.json: -------------------------------------------------------------------------------- 1 | {"Extra value after close": true} "misplaced quoted value" -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail11.json: -------------------------------------------------------------------------------- 1 | {"Illegal expression": 1 + 2} -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail12.json: -------------------------------------------------------------------------------- 1 | {"Illegal invocation": alert()} -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail13.json: -------------------------------------------------------------------------------- 1 | {"Numbers cannot have leading zeroes": 013} -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail14.json: -------------------------------------------------------------------------------- 1 | {"Numbers cannot be hex": 0x14} -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail15.json: -------------------------------------------------------------------------------- 1 | ["Illegal backslash escape: \x15"] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail16.json: -------------------------------------------------------------------------------- 1 | [\naked] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail17.json: -------------------------------------------------------------------------------- 1 | ["Illegal backslash escape: \017"] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail18.json: -------------------------------------------------------------------------------- 1 | [[[[[[[[[[[[[[[[[[[["Too deep"]]]]]]]]]]]]]]]]]]]] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail19.json: -------------------------------------------------------------------------------- 1 | {"Missing colon" null} -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail2.json: -------------------------------------------------------------------------------- 1 | ["Unclosed array" -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail20.json: -------------------------------------------------------------------------------- 1 | {"Double colon":: null} -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail21.json: -------------------------------------------------------------------------------- 1 | {"Comma instead of colon", null} -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail22.json: -------------------------------------------------------------------------------- 1 | ["Colon instead of comma": false] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail23.json: -------------------------------------------------------------------------------- 1 | ["Bad value", truth] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail24.json: -------------------------------------------------------------------------------- 1 | ['single quote'] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail25.json: -------------------------------------------------------------------------------- 1 | [" tab character in string "] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail26.json: -------------------------------------------------------------------------------- 1 | ["tab\ character\ in\ string\ "] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail27.json: -------------------------------------------------------------------------------- 1 | ["line 2 | break"] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail28.json: -------------------------------------------------------------------------------- 1 | ["line\ 2 | break"] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail29.json: -------------------------------------------------------------------------------- 1 | [0e] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail3.json: -------------------------------------------------------------------------------- 1 | {unquoted_key: "keys must be quoted"} -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail30.json: -------------------------------------------------------------------------------- 1 | [0e+] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail31.json: -------------------------------------------------------------------------------- 1 | [0e+-1] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail32.json: -------------------------------------------------------------------------------- 1 | {"Comma instead if closing brace": true, -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail33.json: -------------------------------------------------------------------------------- 1 | ["mismatch"} -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail4.json: -------------------------------------------------------------------------------- 1 | ["extra comma",] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail5.json: -------------------------------------------------------------------------------- 1 | ["double extra comma",,] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail6.json: -------------------------------------------------------------------------------- 1 | [ , "<-- missing value"] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail7.json: -------------------------------------------------------------------------------- 1 | ["Comma after the close"], -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail8.json: -------------------------------------------------------------------------------- 1 | ["Extra close"]] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/fail9.json: -------------------------------------------------------------------------------- 1 | {"Extra comma": true,} -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/pass1.json: -------------------------------------------------------------------------------- 1 | [ 2 | "JSON Test Pattern pass1", 3 | {"object with 1 member":["array with 1 element"]}, 4 | {}, 5 | [], 6 | -42, 7 | true, 8 | false, 9 | null, 10 | { 11 | "integer": 1234567890, 12 | "real": -9876.543210, 13 | "e": 0.123456789e-12, 14 | "E": 1.234567890E+34, 15 | "": 23456789012E66, 16 | "zero": 0, 17 | "one": 1, 18 | "space": " ", 19 | "quote": "\"", 20 | "backslash": "\\", 21 | "controls": "\b\f\n\r\t", 22 | "slash": "/ & \/", 23 | "alpha": "abcdefghijklmnopqrstuvwyz", 24 | "ALPHA": "ABCDEFGHIJKLMNOPQRSTUVWYZ", 25 | "digit": "0123456789", 26 | "0123456789": "digit", 27 | "special": "`1~!@#$%^&*()_+-={':[,]}|;.?", 28 | "hex": "\u0123\u4567\u89AB\uCDEF\uabcd\uef4A", 29 | "true": true, 30 | "false": false, 31 | "null": null, 32 | "array":[ ], 33 | "object":{ }, 34 | "address": "50 St. James Street", 35 | "url": "http://www.JSON.org/", 36 | "comment": "// /* */": " ", 38 | " s p a c e d " :[1,2 , 3 39 | 40 | , 41 | 42 | 4 , 5 , 6 ,7 ],"compact":[1,2,3,4,5,6,7], 43 | "jsontext": "{\"object with 1 member\":[\"array with 1 element\"]}", 44 | "quotes": "" \u0022 %22 0x22 034 "", 45 | "\/\\\"\uCAFE\uBABE\uAB98\uFCDE\ubcda\uef4A\b\f\n\r\t`1~!@#$%^&*()_+-=[]{}|;:',./<>?" 46 | : "A key can be any string" 47 | }, 48 | 0.5 ,98.6 49 | , 50 | 99.44 51 | , 52 | 53 | 1066, 54 | 1e1, 55 | 0.1e1, 56 | 1e-1, 57 | 1e00,2e+00,2e-00 58 | ,"rosebud"] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/pass2.json: -------------------------------------------------------------------------------- 1 | [[[[[[[[[[[[[[[[[[["Not too deep"]]]]]]]]]]]]]]]]]]] -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/pass3.json: -------------------------------------------------------------------------------- 1 | { 2 | "JSON Test Pattern pass3": { 3 | "The outermost value": "must be an object or array.", 4 | "In this test": "It is an object." 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /rapidjson/bin/jsonchecker/readme.txt: -------------------------------------------------------------------------------- 1 | Test suite from http://json.org/JSON_checker/. 2 | 3 | If the JSON_checker is working correctly, it must accept all of the pass*.json files and reject all of the fail*.json files. 4 | -------------------------------------------------------------------------------- /rapidjson/bin/types/booleans.json: -------------------------------------------------------------------------------- 1 | [ 2 | true, 3 | true, 4 | false, 5 | false, 6 | true, 7 | true, 8 | true, 9 | false, 10 | false, 11 | true, 12 | false, 13 | false, 14 | true, 15 | false, 16 | false, 17 | false, 18 | true, 19 | false, 20 | false, 21 | true, 22 | true, 23 | false, 24 | true, 25 | true, 26 | true, 27 | false, 28 | false, 29 | false, 30 | true, 31 | false, 32 | true, 33 | false, 34 | false, 35 | true, 36 | true, 37 | true, 38 | true, 39 | true, 40 | true, 41 | false, 42 | false, 43 | true, 44 | false, 45 | false, 46 | false, 47 | true, 48 | true, 49 | false, 50 | true, 51 | true, 52 | false, 53 | true, 54 | false, 55 | true, 56 | true, 57 | true, 58 | false, 59 | false, 60 | false, 61 | true, 62 | false, 63 | false, 64 | false, 65 | true, 66 | true, 67 | false, 68 | true, 69 | true, 70 | true, 71 | true, 72 | true, 73 | true, 74 | true, 75 | true, 76 | false, 77 | false, 78 | false, 79 | false, 80 | false, 81 | true, 82 | true, 83 | true, 84 | true, 85 | true, 86 | true, 87 | true, 88 | false, 89 | false, 90 | false, 91 | true, 92 | false, 93 | false, 94 | false, 95 | true, 96 | true, 97 | true, 98 | false, 99 | false, 100 | true, 101 | false 102 | ] -------------------------------------------------------------------------------- /rapidjson/bin/types/floats.json: -------------------------------------------------------------------------------- 1 | [ 2 | 135.747111636, 3 | 123.377054008, 4 | 140.527504552, 5 | -72.299143906, 6 | -23.851678949, 7 | 73.586193519, 8 | -158.299382442, 9 | 177.477876032, 10 | 32.268518982, 11 | -139.560009969, 12 | 115.203105183, 13 | -106.025823607, 14 | 167.224138231, 15 | 103.378383732, 16 | -97.498486285, 17 | 18.184723416, 18 | 69.137075711, 19 | 33.849002681, 20 | -120.185228215, 21 | -20.841408615, 22 | -172.659492727, 23 | -2.691464061, 24 | 22.426164066, 25 | -98.416909437, 26 | -31.603082708, 27 | -85.072296561, 28 | 108.620987395, 29 | -43.127078238, 30 | -126.473562057, 31 | -158.595489097, 32 | -57.890678254, 33 | -13.254016573, 34 | -85.024504709, 35 | 171.663552644, 36 | -146.495558248, 37 | -10.606748276, 38 | -118.786969354, 39 | 153.352057804, 40 | -45.215545083, 41 | 37.038725288, 42 | 106.344071897, 43 | -64.607402031, 44 | 85.148030911, 45 | 28.897784566, 46 | 39.51082061, 47 | 20.450382102, 48 | -113.174943618, 49 | 71.60785784, 50 | -168.202648062, 51 | -157.338200017, 52 | 10.879588527, 53 | -114.261694831, 54 | -5.622927072, 55 | -173.330830616, 56 | -29.47002003, 57 | -39.829034201, 58 | 50.031545162, 59 | 82.815735508, 60 | -119.188760828, 61 | -48.455928081, 62 | 163.964263034, 63 | 46.30378861, 64 | -26.248889762, 65 | -47.354615322, 66 | 155.388677633, 67 | -166.710356904, 68 | 42.987233558, 69 | 144.275297374, 70 | 37.394383186, 71 | -122.550388725, 72 | 177.469945914, 73 | 101.104677413, 74 | 109.429869885, 75 | -104.919625624, 76 | 147.522756541, 77 | -81.294703727, 78 | 122.744731363, 79 | 81.803603684, 80 | 26.321556167, 81 | 147.045441354, 82 | 147.256895816, 83 | -174.211095908, 84 | 52.518769316, 85 | -78.58250334, 86 | -173.356685435, 87 | -107.728209264, 88 | -69.982325771, 89 | -113.776095893, 90 | -35.785267074, 91 | -105.748545976, 92 | -30.206523864, 93 | -76.185311723, 94 | -126.400112781, 95 | -26.864958639, 96 | 56.840053629, 97 | 93.781553535, 98 | -116.002949803, 99 | -46.617140948, 100 | 176.846840093, 101 | -144.24821335 102 | ] 103 | -------------------------------------------------------------------------------- /rapidjson/bin/types/integers.json: -------------------------------------------------------------------------------- 1 | [ 2 | 8125686, 3 | 8958709, 4 | 5976222, 5 | 1889524, 6 | 7968493, 7 | 1357486, 8 | 118415, 9 | 7081097, 10 | 4635968, 11 | 7555332, 12 | 2270233, 13 | 3428352, 14 | 8699968, 15 | 2087333, 16 | 7861337, 17 | 7554440, 18 | 2017031, 19 | 7981692, 20 | 6060687, 21 | 1877715, 22 | 3297474, 23 | 8373177, 24 | 6158629, 25 | 7853641, 26 | 3004441, 27 | 9650406, 28 | 2695251, 29 | 1180761, 30 | 4988426, 31 | 6043805, 32 | 8063373, 33 | 6103218, 34 | 2848339, 35 | 8188690, 36 | 9235573, 37 | 5949816, 38 | 6116081, 39 | 6471138, 40 | 3354531, 41 | 4787414, 42 | 9660600, 43 | 942529, 44 | 7278535, 45 | 7967399, 46 | 554292, 47 | 1436493, 48 | 267319, 49 | 2606657, 50 | 7900601, 51 | 4276634, 52 | 7996757, 53 | 8544466, 54 | 7266469, 55 | 3301373, 56 | 4005350, 57 | 6437652, 58 | 7717672, 59 | 7126292, 60 | 8588394, 61 | 2127902, 62 | 7410190, 63 | 1517806, 64 | 4583602, 65 | 3123440, 66 | 7747613, 67 | 5029464, 68 | 9834390, 69 | 3087227, 70 | 4913822, 71 | 7550487, 72 | 4518144, 73 | 5862588, 74 | 1778599, 75 | 9493290, 76 | 5588455, 77 | 3638706, 78 | 7394293, 79 | 4294719, 80 | 3837830, 81 | 6381878, 82 | 7175866, 83 | 8575492, 84 | 1415229, 85 | 1453733, 86 | 6972404, 87 | 9782571, 88 | 4234063, 89 | 7117418, 90 | 7293130, 91 | 8057071, 92 | 9345285, 93 | 7626648, 94 | 3358911, 95 | 4574537, 96 | 9371826, 97 | 7627107, 98 | 6154093, 99 | 5392367, 100 | 5398105, 101 | 6956377 102 | ] -------------------------------------------------------------------------------- /rapidjson/bin/types/nulls.json: -------------------------------------------------------------------------------- 1 | [ 2 | null, 3 | null, 4 | null, 5 | null, 6 | null, 7 | null, 8 | null, 9 | null, 10 | null, 11 | null, 12 | null, 13 | null, 14 | null, 15 | null, 16 | null, 17 | null, 18 | null, 19 | null, 20 | null, 21 | null, 22 | null, 23 | null, 24 | null, 25 | null, 26 | null, 27 | null, 28 | null, 29 | null, 30 | null, 31 | null, 32 | null, 33 | null, 34 | null, 35 | null, 36 | null, 37 | null, 38 | null, 39 | null, 40 | null, 41 | null, 42 | null, 43 | null, 44 | null, 45 | null, 46 | null, 47 | null, 48 | null, 49 | null, 50 | null, 51 | null, 52 | null, 53 | null, 54 | null, 55 | null, 56 | null, 57 | null, 58 | null, 59 | null, 60 | null, 61 | null, 62 | null, 63 | null, 64 | null, 65 | null, 66 | null, 67 | null, 68 | null, 69 | null, 70 | null, 71 | null, 72 | null, 73 | null, 74 | null, 75 | null, 76 | null, 77 | null, 78 | null, 79 | null, 80 | null, 81 | null, 82 | null, 83 | null, 84 | null, 85 | null, 86 | null, 87 | null, 88 | null, 89 | null, 90 | null, 91 | null, 92 | null, 93 | null, 94 | null, 95 | null, 96 | null, 97 | null, 98 | null, 99 | null, 100 | null, 101 | null 102 | ] -------------------------------------------------------------------------------- /rapidjson/bin/types/readme.txt: -------------------------------------------------------------------------------- 1 | Test data obtained from https://github.com/xpol/lua-rapidjson/tree/master/performance 2 | -------------------------------------------------------------------------------- /rapidjson/bin/unittestschema/allOf_address.json: -------------------------------------------------------------------------------- 1 | { 2 | "allOf": [ 3 | { 4 | "$ref": "http://localhost:1234/address.json#" 5 | } 6 | ] 7 | } -------------------------------------------------------------------------------- /rapidjson/bin/unittestschema/anyOf_address.json: -------------------------------------------------------------------------------- 1 | { 2 | "anyOf": [ 3 | { 4 | "$ref": "http://localhost:1234/address.json#" 5 | } 6 | ] 7 | } -------------------------------------------------------------------------------- /rapidjson/bin/unittestschema/oneOf_address.json: -------------------------------------------------------------------------------- 1 | { 2 | "oneOf": [ 3 | { 4 | "$ref": "http://localhost:1234/address.json#" 5 | } 6 | ] 7 | } -------------------------------------------------------------------------------- /rapidjson/doc/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | find_package(Doxygen) 2 | 3 | IF(NOT DOXYGEN_FOUND) 4 | MESSAGE(STATUS "No Doxygen found. Documentation won't be built") 5 | ELSE() 6 | file(GLOB SOURCES ${CMAKE_CURRENT_LIST_DIR}/../include/*) 7 | file(GLOB MARKDOWN_DOC ${CMAKE_CURRENT_LIST_DIR}/../doc/*.md) 8 | list(APPEND MARKDOWN_DOC ${CMAKE_CURRENT_LIST_DIR}/../readme.md) 9 | 10 | CONFIGURE_FILE(Doxyfile.in Doxyfile @ONLY) 11 | CONFIGURE_FILE(Doxyfile.zh-cn.in Doxyfile.zh-cn @ONLY) 12 | 13 | file(GLOB DOXYFILES ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile*) 14 | 15 | add_custom_command(OUTPUT html 16 | COMMAND ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile 17 | COMMAND ${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile.zh-cn 18 | COMMAND ${CMAKE_COMMAND} -E touch ${CMAKE_CURRENT_BINARY_DIR}/html 19 | DEPENDS ${MARKDOWN_DOC} ${SOURCES} ${DOXYFILES} 20 | WORKING_DIRECTORY ${CMAKE_CURRENT_LIST_DIR}/../ 21 | ) 22 | 23 | add_custom_target(doc ALL DEPENDS html) 24 | install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/html 25 | DESTINATION ${DOC_INSTALL_DIR} 26 | COMPONENT doc) 27 | ENDIF() 28 | -------------------------------------------------------------------------------- /rapidjson/doc/diagram/architecture.dot: -------------------------------------------------------------------------------- 1 | digraph { 2 | compound=true 3 | fontname="Inconsolata, Consolas" 4 | fontsize=10 5 | margin="0,0" 6 | ranksep=0.2 7 | nodesep=0.5 8 | penwidth=0.5 9 | colorscheme=spectral7 10 | 11 | node [shape=box, fontname="Inconsolata, Consolas", fontsize=10, penwidth=0.5, style=filled, fillcolor=white] 12 | edge [fontname="Inconsolata, Consolas", fontsize=10, penwidth=0.5] 13 | 14 | subgraph cluster1 { 15 | margin="10,10" 16 | labeljust="left" 17 | label = "SAX" 18 | style=filled 19 | fillcolor=6 20 | 21 | Reader -> Writer [style=invis] 22 | } 23 | 24 | subgraph cluster2 { 25 | margin="10,10" 26 | labeljust="left" 27 | label = "DOM" 28 | style=filled 29 | fillcolor=7 30 | 31 | Value 32 | Document 33 | } 34 | 35 | Handler [label="<>\nHandler"] 36 | 37 | { 38 | edge [arrowtail=onormal, dir=back] 39 | Value -> Document 40 | Handler -> Document 41 | Handler -> Writer 42 | } 43 | 44 | { 45 | edge [arrowhead=vee, style=dashed, constraint=false] 46 | Reader -> Handler [label="calls"] 47 | Value -> Handler [label="calls"] 48 | Document -> Reader [label="uses"] 49 | } 50 | } -------------------------------------------------------------------------------- /rapidjson/doc/diagram/architecture.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/doc/diagram/architecture.png -------------------------------------------------------------------------------- /rapidjson/doc/diagram/insituparsing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/doc/diagram/insituparsing.png -------------------------------------------------------------------------------- /rapidjson/doc/diagram/iterative-parser-states-diagram.dot: -------------------------------------------------------------------------------- 1 | digraph { 2 | fontname="Inconsolata, Consolas" 3 | fontsize=10 4 | margin="0,0" 5 | penwidth=0.0 6 | 7 | node [fontname="Inconsolata, Consolas", fontsize=10, penwidth=0.5] 8 | edge [fontname="Inconsolata, Consolas", fontsize=10, penwidth=0.5] 9 | 10 | node [shape = doublecircle]; Start; Finish; 11 | node [shape = box; style = "rounded, filled"; fillcolor=white ]; 12 | 13 | Start -> ArrayInitial [label=" ["]; 14 | Start -> ObjectInitial [label=" {"]; 15 | 16 | subgraph clusterArray { 17 | margin="10,10" 18 | style=filled 19 | fillcolor=gray95 20 | label = "Array" 21 | 22 | ArrayInitial; Element; ElementDelimiter; ArrayFinish; 23 | } 24 | 25 | subgraph clusterObject { 26 | margin="10,10" 27 | style=filled 28 | fillcolor=gray95 29 | label = "Object" 30 | 31 | ObjectInitial; MemberKey; KeyValueDelimiter; MemberValue; MemberDelimiter; ObjectFinish; 32 | } 33 | 34 | ArrayInitial -> ArrayInitial [label="["]; 35 | ArrayInitial -> ArrayFinish [label=" ]"]; 36 | ArrayInitial -> ObjectInitial [label="{", constraint=false]; 37 | ArrayInitial -> Element [label="string\nfalse\ntrue\nnull\nnumber"]; 38 | 39 | Element -> ArrayFinish [label="]"]; 40 | Element -> ElementDelimiter [label=","]; 41 | 42 | ElementDelimiter -> ArrayInitial [label=" ["]; 43 | ElementDelimiter -> ObjectInitial [label="{"]; 44 | ElementDelimiter -> Element [label="string\nfalse\ntrue\nnull\nnumber"]; 45 | 46 | ObjectInitial -> ObjectFinish [label=" }"]; 47 | ObjectInitial -> MemberKey [label=" string "]; 48 | 49 | MemberKey -> KeyValueDelimiter [label=":"]; 50 | 51 | KeyValueDelimiter -> ArrayInitial [label="["]; 52 | KeyValueDelimiter -> ObjectInitial [label=" {"]; 53 | KeyValueDelimiter -> MemberValue [label=" string\n false\n true\n null\n number"]; 54 | 55 | MemberValue -> ObjectFinish [label="}"]; 56 | MemberValue -> MemberDelimiter [label=","]; 57 | 58 | MemberDelimiter -> MemberKey [label=" string "]; 59 | 60 | ArrayFinish -> Finish; 61 | ObjectFinish -> Finish; 62 | } 63 | -------------------------------------------------------------------------------- /rapidjson/doc/diagram/iterative-parser-states-diagram.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/doc/diagram/iterative-parser-states-diagram.png -------------------------------------------------------------------------------- /rapidjson/doc/diagram/move1.dot: -------------------------------------------------------------------------------- 1 | digraph { 2 | compound=true 3 | fontname="Inconsolata, Consolas" 4 | fontsize=10 5 | margin="0,0" 6 | ranksep=0.2 7 | penwidth=0.5 8 | 9 | node [fontname="Inconsolata, Consolas", fontsize=10, penwidth=0.5] 10 | edge [fontname="Inconsolata, Consolas", fontsize=10, arrowhead=normal] 11 | 12 | subgraph cluster1 { 13 | margin="10,10" 14 | labeljust="left" 15 | label = "Before" 16 | style=filled 17 | fillcolor=gray95 18 | 19 | node [shape=Mrecord, style=filled, colorscheme=spectral7] 20 | 21 | { 22 | rank = same 23 | b1 [label="{b:number|456}", fillcolor=6] 24 | a1 [label="{a:number|123}", fillcolor=6] 25 | } 26 | 27 | a1 -> b1 [style="dashed", label="Move", dir=back] 28 | } 29 | 30 | subgraph cluster2 { 31 | margin="10,10" 32 | labeljust="left" 33 | label = "After" 34 | style=filled 35 | fillcolor=gray95 36 | 37 | node [shape=Mrecord, style=filled, colorscheme=spectral7] 38 | 39 | { 40 | rank = same 41 | b2 [label="{b:null|}", fillcolor=1] 42 | a2 [label="{a:number|456}", fillcolor=6] 43 | } 44 | a2 -> b2 [style=invis, dir=back] 45 | } 46 | b1 -> b2 [style=invis] 47 | } -------------------------------------------------------------------------------- /rapidjson/doc/diagram/move1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/doc/diagram/move1.png -------------------------------------------------------------------------------- /rapidjson/doc/diagram/move2.dot: -------------------------------------------------------------------------------- 1 | digraph { 2 | compound=true 3 | fontname="Inconsolata, Consolas" 4 | fontsize=10 5 | margin="0,0" 6 | ranksep=0.2 7 | penwidth=0.5 8 | 9 | node [fontname="Inconsolata, Consolas", fontsize=10, penwidth=0.5] 10 | edge [fontname="Inconsolata, Consolas", fontsize=10, arrowhead=normal] 11 | 12 | subgraph cluster1 { 13 | margin="10,10" 14 | labeljust="left" 15 | label = "Before Copying (Hypothetic)" 16 | style=filled 17 | fillcolor=gray95 18 | 19 | node [shape=Mrecord, style=filled, colorscheme=spectral7] 20 | 21 | c1 [label="{contacts:array|}", fillcolor=4] 22 | c11 [label="{|}"] 23 | c12 [label="{|}"] 24 | c13 [shape="none", label="...", style="solid"] 25 | o1 [label="{o:object|}", fillcolor=3] 26 | ghost [label="{o:object|}", style=invis] 27 | 28 | c1 -> o1 [style="dashed", label="AddMember", constraint=false] 29 | 30 | edge [arrowhead=vee] 31 | c1 -> { c11; c12; c13 } 32 | o1 -> ghost [style=invis] 33 | } 34 | 35 | subgraph cluster2 { 36 | margin="10,10" 37 | labeljust="left" 38 | label = "After Copying (Hypothetic)" 39 | style=filled 40 | fillcolor=gray95 41 | 42 | node [shape=Mrecord, style=filled, colorscheme=spectral7] 43 | 44 | c2 [label="{contacts:array|}", fillcolor=4] 45 | c3 [label="{array|}", fillcolor=4] 46 | c21 [label="{|}"] 47 | c22 [label="{|}"] 48 | c23 [shape=none, label="...", style="solid"] 49 | o2 [label="{o:object|}", fillcolor=3] 50 | cs [label="{string|\"contacts\"}", fillcolor=5] 51 | c31 [label="{|}"] 52 | c32 [label="{|}"] 53 | c33 [shape="none", label="...", style="solid"] 54 | 55 | edge [arrowhead=vee] 56 | c2 -> { c21; c22; c23 } 57 | o2 -> cs 58 | cs -> c3 [arrowhead=none] 59 | c3 -> { c31; c32; c33 } 60 | } 61 | ghost -> o2 [style=invis] 62 | } 63 | -------------------------------------------------------------------------------- /rapidjson/doc/diagram/move2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/doc/diagram/move2.png -------------------------------------------------------------------------------- /rapidjson/doc/diagram/move3.dot: -------------------------------------------------------------------------------- 1 | digraph { 2 | compound=true 3 | fontname="Inconsolata, Consolas" 4 | fontsize=10 5 | margin="0,0" 6 | ranksep=0.2 7 | penwidth=0.5 8 | forcelabels=true 9 | 10 | node [fontname="Inconsolata, Consolas", fontsize=10, penwidth=0.5] 11 | edge [fontname="Inconsolata, Consolas", fontsize=10, arrowhead=normal] 12 | 13 | subgraph cluster1 { 14 | margin="10,10" 15 | labeljust="left" 16 | label = "Before Moving" 17 | style=filled 18 | fillcolor=gray95 19 | 20 | node [shape=Mrecord, style=filled, colorscheme=spectral7] 21 | 22 | c1 [label="{contacts:array|}", fillcolor=4] 23 | c11 [label="{|}"] 24 | c12 [label="{|}"] 25 | c13 [shape=none, label="...", style="solid"] 26 | o1 [label="{o:object|}", fillcolor=3] 27 | ghost [label="{o:object|}", style=invis] 28 | 29 | c1 -> o1 [style="dashed", constraint=false, label="AddMember"] 30 | 31 | edge [arrowhead=vee] 32 | c1 -> { c11; c12; c13 } 33 | o1 -> ghost [style=invis] 34 | } 35 | 36 | subgraph cluster2 { 37 | margin="10,10" 38 | labeljust="left" 39 | label = "After Moving" 40 | style=filled 41 | fillcolor=gray95 42 | 43 | node [shape=Mrecord, style=filled, colorscheme=spectral7] 44 | 45 | c2 [label="{contacts:null|}", fillcolor=1] 46 | c3 [label="{array|}", fillcolor=4] 47 | c21 [label="{|}"] 48 | c22 [label="{|}"] 49 | c23 [shape="none", label="...", style="solid"] 50 | o2 [label="{o:object|}", fillcolor=3] 51 | cs [label="{string|\"contacts\"}", fillcolor=5] 52 | c2 -> o2 [style="dashed", constraint=false, label="AddMember", style=invis] 53 | 54 | edge [arrowhead=vee] 55 | c3 -> { c21; c22; c23 } 56 | o2 -> cs 57 | cs -> c3 [arrowhead=none] 58 | } 59 | ghost -> o2 [style=invis] 60 | } 61 | -------------------------------------------------------------------------------- /rapidjson/doc/diagram/move3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/doc/diagram/move3.png -------------------------------------------------------------------------------- /rapidjson/doc/diagram/normalparsing.dot: -------------------------------------------------------------------------------- 1 | digraph { 2 | compound=true 3 | fontname="Inconsolata, Consolas" 4 | fontsize=10 5 | margin="0,0" 6 | ranksep=0.2 7 | penwidth=0.5 8 | 9 | node [fontname="Inconsolata, Consolas", fontsize=10, penwidth=0.5] 10 | edge [fontname="Inconsolata, Consolas", fontsize=10, arrowhead=normal] 11 | 12 | { 13 | node [shape=record, fontsize="8", margin="0.04", height=0.2, color=gray] 14 | normaljson [label="\{|\"|m|s|g|\"|:|\"|H|e|l|l|o|\\|n|W|o|r|l|d|!|\"|,|\"|\\|u|0|0|7|3|t|a|r|s\"|:|1|0|\}"] 15 | 16 | { 17 | rank = same 18 | msgstring [label="m|s|g|\\0"] 19 | helloworldstring [label="H|e|l|l|o|\\n|W|o|r|l|d|!|\\0"] 20 | starsstring [label="s|t|a|r|s\\0"] 21 | } 22 | } 23 | 24 | subgraph cluster1 { 25 | margin="10,10" 26 | labeljust="left" 27 | label = "Document by Normal Parsing" 28 | style=filled 29 | fillcolor=gray95 30 | node [shape=Mrecord, style=filled, colorscheme=spectral7] 31 | 32 | root [label="{object|}", fillcolor=3] 33 | 34 | { 35 | msg [label="{string|}", fillcolor=5] 36 | helloworld [label="{string|}", fillcolor=5] 37 | stars [label="{string|}", fillcolor=5] 38 | ten [label="{number|10}", fillcolor=6] 39 | } 40 | } 41 | 42 | normaljson -> root [label=" Parse()" lhead="cluster1"] 43 | edge [arrowhead=vee] 44 | root -> { msg; stars } 45 | 46 | edge [arrowhead="none"] 47 | msg -> helloworld 48 | stars -> ten 49 | 50 | edge [arrowhead=vee, arrowtail=dot, arrowsize=0.5, dir=both, tailclip=false] 51 | msg:a:c -> msgstring:w 52 | helloworld:a:c -> helloworldstring:w 53 | stars:a:c -> starsstring:w 54 | 55 | msgstring -> helloworldstring -> starsstring [style=invis] 56 | } -------------------------------------------------------------------------------- /rapidjson/doc/diagram/normalparsing.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/doc/diagram/normalparsing.png -------------------------------------------------------------------------------- /rapidjson/doc/diagram/simpledom.dot: -------------------------------------------------------------------------------- 1 | digraph { 2 | compound=true 3 | fontname="Inconsolata, Consolas" 4 | fontsize=10 5 | margin="0,0" 6 | ranksep=0.2 7 | penwidth=0.5 8 | 9 | node [fontname="Inconsolata, Consolas", fontsize=10, penwidth=0.5] 10 | edge [fontname="Inconsolata, Consolas", fontsize=10, arrowhead=normal] 11 | 12 | { 13 | node [shape=record, fontsize="8", margin="0.04", height=0.2, color=gray] 14 | srcjson [label="\{|\"|p|r|o|j|e|c|t|\"|:|\"|r|a|p|i|d|j|s|o|n|\"|,|\"|s|t|a|r|s|\"|:|1|0|\}"] 15 | dstjson [label="\{|\"|p|r|o|j|e|c|t|\"|:|\"|r|a|p|i|d|j|s|o|n|\"|,|\"|s|t|a|r|s|\"|:|1|1|\}"] 16 | } 17 | 18 | { 19 | node [shape="box", style="filled", fillcolor="gray95"] 20 | Document2 [label="(Modified) Document"] 21 | Writer 22 | } 23 | 24 | subgraph cluster1 { 25 | margin="10,10" 26 | labeljust="left" 27 | label = "Document" 28 | style=filled 29 | fillcolor=gray95 30 | node [shape=Mrecord, style=filled, colorscheme=spectral7] 31 | 32 | root [label="{object|}", fillcolor=3] 33 | 34 | { 35 | project [label="{string|\"project\"}", fillcolor=5] 36 | rapidjson [label="{string|\"rapidjson\"}", fillcolor=5] 37 | stars [label="{string|\"stars\"}", fillcolor=5] 38 | ten [label="{number|10}", fillcolor=6] 39 | } 40 | 41 | edge [arrowhead=vee] 42 | root -> { project; stars } 43 | 44 | edge [arrowhead="none"] 45 | project -> rapidjson 46 | stars -> ten 47 | } 48 | 49 | srcjson -> root [label=" Parse()", lhead="cluster1"] 50 | 51 | ten -> Document2 [label=" Increase \"stars\"", ltail="cluster1" ] 52 | Document2 -> Writer [label=" Traverse DOM by Accept()"] 53 | Writer -> dstjson [label=" Output to StringBuffer"] 54 | } -------------------------------------------------------------------------------- /rapidjson/doc/diagram/simpledom.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/doc/diagram/simpledom.png -------------------------------------------------------------------------------- /rapidjson/doc/diagram/tutorial.dot: -------------------------------------------------------------------------------- 1 | digraph { 2 | compound=true 3 | fontname="Inconsolata, Consolas" 4 | fontsize=10 5 | margin="0,0" 6 | ranksep=0.2 7 | penwidth=0.5 8 | 9 | node [fontname="Inconsolata, Consolas", fontsize=10, penwidth=0.5] 10 | edge [fontname="Inconsolata, Consolas", fontsize=10] 11 | 12 | subgraph cluster1 { 13 | margin="10,10" 14 | labeljust="left" 15 | label = "Document" 16 | style=filled 17 | fillcolor=gray95 18 | node [shape=Mrecord, style=filled, colorscheme=spectral7] 19 | 20 | root [label="{object|}", fillcolor=3] 21 | 22 | { 23 | hello [label="{string|\"hello\"}", fillcolor=5] 24 | t [label="{string|\"t\"}", fillcolor=5] 25 | f [label="{string|\"f\"}", fillcolor=5] 26 | n [label="{string|\"n\"}", fillcolor=5] 27 | i [label="{string|\"i\"}", fillcolor=5] 28 | pi [label="{string|\"pi\"}", fillcolor=5] 29 | a [label="{string|\"a\"}", fillcolor=5] 30 | 31 | world [label="{string|\"world\"}", fillcolor=5] 32 | true [label="{true|}", fillcolor=7] 33 | false [label="{false|}", fillcolor=2] 34 | null [label="{null|}", fillcolor=1] 35 | i1 [label="{number|123}", fillcolor=6] 36 | pi1 [label="{number|3.1416}", fillcolor=6] 37 | array [label="{array|size=4}", fillcolor=4] 38 | 39 | a1 [label="{number|1}", fillcolor=6] 40 | a2 [label="{number|2}", fillcolor=6] 41 | a3 [label="{number|3}", fillcolor=6] 42 | a4 [label="{number|4}", fillcolor=6] 43 | } 44 | 45 | edge [arrowhead=vee] 46 | root -> { hello; t; f; n; i; pi; a } 47 | array -> { a1; a2; a3; a4 } 48 | 49 | edge [arrowhead=none] 50 | hello -> world 51 | t -> true 52 | f -> false 53 | n -> null 54 | i -> i1 55 | pi -> pi1 56 | a -> array 57 | } 58 | } -------------------------------------------------------------------------------- /rapidjson/doc/diagram/tutorial.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/doc/diagram/tutorial.png -------------------------------------------------------------------------------- /rapidjson/doc/diagram/utilityclass.dot: -------------------------------------------------------------------------------- 1 | digraph { 2 | rankdir=LR 3 | compound=true 4 | fontname="Inconsolata, Consolas" 5 | fontsize=10 6 | margin="0,0" 7 | ranksep=0.3 8 | nodesep=0.15 9 | penwidth=0.5 10 | colorscheme=spectral7 11 | 12 | node [shape=box, fontname="Inconsolata, Consolas", fontsize=10, penwidth=0.5, style=filled, fillcolor=white] 13 | edge [fontname="Inconsolata, Consolas", fontsize=10, penwidth=0.5] 14 | 15 | subgraph cluster0 { 16 | style=filled 17 | fillcolor=4 18 | 19 | Encoding [label="<>\nEncoding"] 20 | 21 | edge [arrowtail=onormal, dir=back] 22 | Encoding -> { UTF8; UTF16; UTF32; ASCII; AutoUTF } 23 | UTF16 -> { UTF16LE; UTF16BE } 24 | UTF32 -> { UTF32LE; UTF32BE } 25 | } 26 | 27 | subgraph cluster1 { 28 | style=filled 29 | fillcolor=5 30 | 31 | Stream [label="<>\nStream"] 32 | InputByteStream [label="<>\nInputByteStream"] 33 | OutputByteStream [label="<>\nOutputByteStream"] 34 | 35 | edge [arrowtail=onormal, dir=back] 36 | Stream -> { 37 | StringStream; InsituStringStream; StringBuffer; 38 | EncodedInputStream; EncodedOutputStream; 39 | AutoUTFInputStream; AutoUTFOutputStream 40 | InputByteStream; OutputByteStream 41 | } 42 | 43 | InputByteStream -> { MemoryStream; FlieReadStream } 44 | OutputByteStream -> { MemoryBuffer; FileWriteStream } 45 | } 46 | 47 | subgraph cluster2 { 48 | style=filled 49 | fillcolor=3 50 | 51 | Allocator [label="<>\nAllocator"] 52 | 53 | edge [arrowtail=onormal, dir=back] 54 | Allocator -> { CrtAllocator; MemoryPoolAllocator } 55 | } 56 | 57 | { 58 | edge [arrowtail=odiamond, arrowhead=vee, dir=both] 59 | EncodedInputStream -> InputByteStream 60 | EncodedOutputStream -> OutputByteStream 61 | AutoUTFInputStream -> InputByteStream 62 | AutoUTFOutputStream -> OutputByteStream 63 | MemoryPoolAllocator -> Allocator [label="base", tailport=s] 64 | } 65 | 66 | { 67 | edge [arrowhead=vee, style=dashed] 68 | AutoUTFInputStream -> AutoUTF 69 | AutoUTFOutputStream -> AutoUTF 70 | } 71 | 72 | //UTF32LE -> Stream [style=invis] 73 | } -------------------------------------------------------------------------------- /rapidjson/doc/diagram/utilityclass.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/doc/diagram/utilityclass.png -------------------------------------------------------------------------------- /rapidjson/doc/logo/rapidjson.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/rapidjson/doc/logo/rapidjson.png -------------------------------------------------------------------------------- /rapidjson/doc/misc/footer.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /rapidjson/doc/misc/header.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | $projectname: $title 9 | $title 10 | 11 | 12 | 13 | $treeview 14 | $search 15 | $mathjax 16 | 17 | $extrastylesheet 18 | 19 | 20 |
21 |
22 | $searchbox 23 | 24 | 25 | -------------------------------------------------------------------------------- /rapidjson/doc/npm.md: -------------------------------------------------------------------------------- 1 | ## NPM 2 | 3 | # package.json {#package} 4 | 5 | ~~~~~~~~~~js 6 | { 7 | ... 8 | "dependencies": { 9 | ... 10 | "rapidjson": "git@github.com:Tencent/rapidjson.git" 11 | }, 12 | ... 13 | "gypfile": true 14 | } 15 | ~~~~~~~~~~ 16 | 17 | # binding.gyp {#binding} 18 | 19 | ~~~~~~~~~~js 20 | { 21 | ... 22 | 'targets': [ 23 | { 24 | ... 25 | 'include_dirs': [ 26 | ' writer(os); 24 | 25 | // JSON reader parse from the input stream and let writer generate the output. 26 | if (!reader.Parse(is, writer)) { 27 | fprintf(stderr, "\nError(%u): %s\n", static_cast(reader.GetErrorOffset()), GetParseError_En(reader.GetParseErrorCode())); 28 | return 1; 29 | } 30 | 31 | return 0; 32 | } 33 | -------------------------------------------------------------------------------- /rapidjson/example/pretty/pretty.cpp: -------------------------------------------------------------------------------- 1 | // JSON pretty formatting example 2 | // This example can only handle UTF-8. For handling other encodings, see prettyauto example. 3 | 4 | #include "rapidjson/reader.h" 5 | #include "rapidjson/prettywriter.h" 6 | #include "rapidjson/filereadstream.h" 7 | #include "rapidjson/filewritestream.h" 8 | #include "rapidjson/error/en.h" 9 | 10 | using namespace rapidjson; 11 | 12 | int main(int, char*[]) { 13 | // Prepare reader and input stream. 14 | Reader reader; 15 | char readBuffer[65536]; 16 | FileReadStream is(stdin, readBuffer, sizeof(readBuffer)); 17 | 18 | // Prepare writer and output stream. 19 | char writeBuffer[65536]; 20 | FileWriteStream os(stdout, writeBuffer, sizeof(writeBuffer)); 21 | PrettyWriter writer(os); 22 | 23 | // JSON reader parse from the input stream and let writer generate the output. 24 | if (!reader.Parse(is, writer)) { 25 | fprintf(stderr, "\nError(%u): %s\n", static_cast(reader.GetErrorOffset()), GetParseError_En(reader.GetParseErrorCode())); 26 | return 1; 27 | } 28 | 29 | return 0; 30 | } 31 | -------------------------------------------------------------------------------- /rapidjson/example/simpledom/simpledom.cpp: -------------------------------------------------------------------------------- 1 | // JSON simple example 2 | // This example does not handle errors. 3 | 4 | #include "rapidjson/document.h" 5 | #include "rapidjson/writer.h" 6 | #include "rapidjson/stringbuffer.h" 7 | #include 8 | 9 | using namespace rapidjson; 10 | 11 | int main() { 12 | // 1. Parse a JSON string into DOM. 13 | const char* json = "{\"project\":\"rapidjson\",\"stars\":10}"; 14 | Document d; 15 | d.Parse(json); 16 | 17 | // 2. Modify it by DOM. 18 | Value& s = d["stars"]; 19 | s.SetInt(s.GetInt() + 1); 20 | 21 | // 3. Stringify the DOM 22 | StringBuffer buffer; 23 | Writer writer(buffer); 24 | d.Accept(writer); 25 | 26 | // Output {"project":"rapidjson","stars":11} 27 | std::cout << buffer.GetString() << std::endl; 28 | return 0; 29 | } 30 | -------------------------------------------------------------------------------- /rapidjson/example/simplereader/simplereader.cpp: -------------------------------------------------------------------------------- 1 | #include "rapidjson/reader.h" 2 | #include 3 | 4 | using namespace rapidjson; 5 | using namespace std; 6 | 7 | struct MyHandler { 8 | bool Null() { cout << "Null()" << endl; return true; } 9 | bool Bool(bool b) { cout << "Bool(" << boolalpha << b << ")" << endl; return true; } 10 | bool Int(int i) { cout << "Int(" << i << ")" << endl; return true; } 11 | bool Uint(unsigned u) { cout << "Uint(" << u << ")" << endl; return true; } 12 | bool Int64(int64_t i) { cout << "Int64(" << i << ")" << endl; return true; } 13 | bool Uint64(uint64_t u) { cout << "Uint64(" << u << ")" << endl; return true; } 14 | bool Double(double d) { cout << "Double(" << d << ")" << endl; return true; } 15 | bool RawNumber(const char* str, SizeType length, bool copy) { 16 | cout << "Number(" << str << ", " << length << ", " << boolalpha << copy << ")" << endl; 17 | return true; 18 | } 19 | bool String(const char* str, SizeType length, bool copy) { 20 | cout << "String(" << str << ", " << length << ", " << boolalpha << copy << ")" << endl; 21 | return true; 22 | } 23 | bool StartObject() { cout << "StartObject()" << endl; return true; } 24 | bool Key(const char* str, SizeType length, bool copy) { 25 | cout << "Key(" << str << ", " << length << ", " << boolalpha << copy << ")" << endl; 26 | return true; 27 | } 28 | bool EndObject(SizeType memberCount) { cout << "EndObject(" << memberCount << ")" << endl; return true; } 29 | bool StartArray() { cout << "StartArray()" << endl; return true; } 30 | bool EndArray(SizeType elementCount) { cout << "EndArray(" << elementCount << ")" << endl; return true; } 31 | }; 32 | 33 | int main() { 34 | const char json[] = " { \"hello\" : \"world\", \"t\" : true , \"f\" : false, \"n\": null, \"i\":123, \"pi\": 3.1416, \"a\":[1, 2, 3, 4] } "; 35 | 36 | MyHandler handler; 37 | Reader reader; 38 | StringStream ss(json); 39 | reader.Parse(ss, handler); 40 | 41 | return 0; 42 | } 43 | -------------------------------------------------------------------------------- /rapidjson/example/simplewriter/simplewriter.cpp: -------------------------------------------------------------------------------- 1 | #include "rapidjson/writer.h" 2 | #include "rapidjson/stringbuffer.h" 3 | #include 4 | 5 | using namespace rapidjson; 6 | using namespace std; 7 | 8 | int main() { 9 | StringBuffer s; 10 | Writer writer(s); 11 | 12 | writer.StartObject(); // Between StartObject()/EndObject(), 13 | writer.Key("hello"); // output a key, 14 | writer.String("world"); // follow by a value. 15 | writer.Key("t"); 16 | writer.Bool(true); 17 | writer.Key("f"); 18 | writer.Bool(false); 19 | writer.Key("n"); 20 | writer.Null(); 21 | writer.Key("i"); 22 | writer.Uint(123); 23 | writer.Key("pi"); 24 | writer.Double(3.1416); 25 | writer.Key("a"); 26 | writer.StartArray(); // Between StartArray()/EndArray(), 27 | for (unsigned i = 0; i < 4; i++) 28 | writer.Uint(i); // all values are elements of the array. 29 | writer.EndArray(); 30 | writer.EndObject(); 31 | 32 | // {"hello":"world","t":true,"f":false,"n":null,"i":123,"pi":3.1416,"a":[0,1,2,3]} 33 | cout << s.GetString() << endl; 34 | 35 | return 0; 36 | } 37 | -------------------------------------------------------------------------------- /rapidjson/example/sortkeys/sortkeys.cpp: -------------------------------------------------------------------------------- 1 | #include "rapidjson/document.h" 2 | #include "rapidjson/filewritestream.h" 3 | #include 4 | 5 | #include 6 | #include 7 | 8 | using namespace rapidjson; 9 | using namespace std; 10 | 11 | static void printIt(const Value &doc) { 12 | char writeBuffer[65536]; 13 | FileWriteStream os(stdout, writeBuffer, sizeof(writeBuffer)); 14 | PrettyWriter writer(os); 15 | doc.Accept(writer); 16 | cout << endl; 17 | } 18 | 19 | struct NameComparator { 20 | bool operator()(const Value::Member &lhs, const Value::Member &rhs) const { 21 | return (strcmp(lhs.name.GetString(), rhs.name.GetString()) < 0); 22 | } 23 | }; 24 | 25 | int main() { 26 | Document d(kObjectType); 27 | Document::AllocatorType &allocator = d.GetAllocator(); 28 | 29 | d.AddMember("zeta", Value().SetBool(false), allocator); 30 | d.AddMember("gama", Value().SetString("test string", allocator), allocator); 31 | d.AddMember("delta", Value().SetInt(123), allocator); 32 | d.AddMember("alpha", Value(kArrayType).Move(), allocator); 33 | 34 | printIt(d); 35 | 36 | /* 37 | { 38 | "zeta": false, 39 | "gama": "test string", 40 | "delta": 123, 41 | "alpha": [] 42 | } 43 | */ 44 | 45 | // C++11 supports std::move() of Value so it always have no problem for std::sort(). 46 | // Some C++03 implementations of std::sort() requires copy constructor which causes compilation error. 47 | // Needs a sorting function only depends on std::swap() instead. 48 | #if __cplusplus >= 201103L || (!defined(__GLIBCXX__) && (!defined(_MSC_VER) || _MSC_VER >= 1900)) 49 | std::sort(d.MemberBegin(), d.MemberEnd(), NameComparator()); 50 | 51 | printIt(d); 52 | 53 | /* 54 | { 55 | "alpha": [], 56 | "delta": 123, 57 | "gama": "test string", 58 | "zeta": false 59 | } 60 | */ 61 | #endif 62 | } 63 | -------------------------------------------------------------------------------- /rapidjson/include/rapidjson/internal/swap.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making RapidJSON available. 2 | // 3 | // Copyright (C) 2015 THL A29 Limited, a Tencent company, and Milo Yip. 4 | // 5 | // Licensed under the MIT License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // http://opensource.org/licenses/MIT 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef RAPIDJSON_INTERNAL_SWAP_H_ 16 | #define RAPIDJSON_INTERNAL_SWAP_H_ 17 | 18 | #include "../rapidjson.h" 19 | 20 | #if defined(__clang__) 21 | RAPIDJSON_DIAG_PUSH 22 | RAPIDJSON_DIAG_OFF(c++98-compat) 23 | #endif 24 | 25 | RAPIDJSON_NAMESPACE_BEGIN 26 | namespace internal { 27 | 28 | //! Custom swap() to avoid dependency on C++ header 29 | /*! \tparam T Type of the arguments to swap, should be instantiated with primitive C++ types only. 30 | \note This has the same semantics as std::swap(). 31 | */ 32 | template 33 | inline void Swap(T& a, T& b) RAPIDJSON_NOEXCEPT { 34 | T tmp = a; 35 | a = b; 36 | b = tmp; 37 | } 38 | 39 | } // namespace internal 40 | RAPIDJSON_NAMESPACE_END 41 | 42 | #if defined(__clang__) 43 | RAPIDJSON_DIAG_POP 44 | #endif 45 | 46 | #endif // RAPIDJSON_INTERNAL_SWAP_H_ 47 | -------------------------------------------------------------------------------- /rapidjson/include_dirs.js: -------------------------------------------------------------------------------- 1 | var path = require('path'); 2 | console.log(path.join(path.relative('.', __dirname), 'include')); 3 | -------------------------------------------------------------------------------- /rapidjson/library.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "RapidJSON", 3 | "version": "1.1.0", 4 | "keywords": "json, sax, dom, parser, generator", 5 | "description": "A fast JSON parser/generator for C++ with both SAX/DOM style API", 6 | "export": { 7 | "include": "include" 8 | }, 9 | "examples": "example/*/*.cpp", 10 | "repository": 11 | { 12 | "type": "git", 13 | "url": "https://github.com/Tencent/rapidjson" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /rapidjson/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "rapidjson", 3 | "version": "1.0.4", 4 | "description": "![](doc/logo/rapidjson.png)", 5 | "main": "include_dirs.js", 6 | "directories": { 7 | "doc": "doc", 8 | "example": "example", 9 | "test": "test" 10 | }, 11 | "scripts": { 12 | "test": "echo \"Error: no test specified\" && exit 1" 13 | }, 14 | "repository": { 15 | "type": "git", 16 | "url": "git+https://github.com/Tencent/rapidjson.git" 17 | }, 18 | "author": "", 19 | "license": "ISC", 20 | "bugs": { 21 | "url": "https://github.com/Tencent/rapidjson/issues" 22 | }, 23 | "homepage": "https://github.com/Tencent/rapidjson#readme" 24 | } 25 | -------------------------------------------------------------------------------- /rapidjson/test/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | find_package(GTestSrc) 2 | 3 | IF(GTESTSRC_FOUND) 4 | enable_testing() 5 | 6 | if (WIN32 AND (NOT CYGWIN) AND (NOT MINGW)) 7 | set(gtest_disable_pthreads ON) 8 | set(gtest_force_shared_crt ON) 9 | endif() 10 | 11 | add_subdirectory(${GTEST_SOURCE_DIR} ${CMAKE_BINARY_DIR}/googletest) 12 | include_directories(SYSTEM ${GTEST_INCLUDE_DIR}) 13 | 14 | set(TEST_LIBRARIES gtest gtest_main) 15 | 16 | add_custom_target(tests ALL) 17 | add_subdirectory(perftest) 18 | add_subdirectory(unittest) 19 | 20 | ENDIF(GTESTSRC_FOUND) 21 | -------------------------------------------------------------------------------- /rapidjson/test/perftest/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | set(PERFTEST_SOURCES 2 | misctest.cpp 3 | perftest.cpp 4 | platformtest.cpp 5 | rapidjsontest.cpp 6 | schematest.cpp) 7 | 8 | add_executable(perftest ${PERFTEST_SOURCES}) 9 | target_link_libraries(perftest ${TEST_LIBRARIES}) 10 | 11 | add_dependencies(tests perftest) 12 | 13 | find_program(CCACHE_FOUND ccache) 14 | if(CCACHE_FOUND) 15 | set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache) 16 | set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK ccache) 17 | if (CMAKE_CXX_COMPILER_ID MATCHES "Clang") 18 | set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Qunused-arguments -fcolor-diagnostics") 19 | endif() 20 | endif(CCACHE_FOUND) 21 | 22 | set_property(DIRECTORY PROPERTY COMPILE_OPTIONS ${EXTRA_CXX_FLAGS}) 23 | 24 | IF(NOT (CMAKE_BUILD_TYPE STREQUAL "Debug")) 25 | add_test(NAME perftest 26 | COMMAND ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/perftest 27 | WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/bin) 28 | ENDIF() 29 | -------------------------------------------------------------------------------- /rapidjson/test/perftest/perftest.cpp: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making RapidJSON available. 2 | // 3 | // Copyright (C) 2015 THL A29 Limited, a Tencent company, and Milo Yip. 4 | // 5 | // Licensed under the MIT License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // http://opensource.org/licenses/MIT 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #include "perftest.h" 16 | 17 | int main(int argc, char **argv) { 18 | #if _MSC_VER 19 | _CrtSetDbgFlag ( _CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF ); 20 | //void *testWhetherMemoryLeakDetectionWorks = malloc(1); 21 | #endif 22 | ::testing::InitGoogleTest(&argc, argv); 23 | return RUN_ALL_TESTS(); 24 | } 25 | -------------------------------------------------------------------------------- /rapidjson/test/unittest/clzlltest.cpp: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making RapidJSON available. 2 | // 3 | // Copyright (C) 2015 THL A29 Limited, a Tencent company, and Milo Yip. 4 | // 5 | // Licensed under the MIT License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // http://opensource.org/licenses/MIT 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #include "unittest.h" 16 | #include "rapidjson/internal/clzll.h" 17 | 18 | #ifdef __GNUC__ 19 | RAPIDJSON_DIAG_PUSH 20 | #endif 21 | 22 | using namespace rapidjson::internal; 23 | 24 | TEST(clzll, normal) { 25 | EXPECT_EQ(clzll(1), 63U); 26 | EXPECT_EQ(clzll(2), 62U); 27 | EXPECT_EQ(clzll(12), 60U); 28 | EXPECT_EQ(clzll(0x0000000080000001UL), 32U); 29 | EXPECT_EQ(clzll(0x8000000000000001UL), 0U); 30 | } 31 | 32 | #ifdef __GNUC__ 33 | RAPIDJSON_DIAG_POP 34 | #endif 35 | -------------------------------------------------------------------------------- /rapidjson/test/unittest/strfunctest.cpp: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making RapidJSON available. 2 | // 3 | // Copyright (C) 2015 THL A29 Limited, a Tencent company, and Milo Yip. 4 | // 5 | // Licensed under the MIT License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // http://opensource.org/licenses/MIT 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #include "unittest.h" 16 | #include "rapidjson/internal/strfunc.h" 17 | 18 | using namespace rapidjson; 19 | using namespace rapidjson::internal; 20 | 21 | TEST(StrFunc, CountStringCodePoint) { 22 | SizeType count; 23 | EXPECT_TRUE(CountStringCodePoint >("", 0, &count)); 24 | EXPECT_EQ(0u, count); 25 | EXPECT_TRUE(CountStringCodePoint >("Hello", 5, &count)); 26 | EXPECT_EQ(5u, count); 27 | EXPECT_TRUE(CountStringCodePoint >("\xC2\xA2\xE2\x82\xAC\xF0\x9D\x84\x9E", 9, &count)); // cents euro G-clef 28 | EXPECT_EQ(3u, count); 29 | EXPECT_FALSE(CountStringCodePoint >("\xC2\xA2\xE2\x82\xAC\xF0\x9D\x84\x9E\x80", 10, &count)); 30 | } 31 | -------------------------------------------------------------------------------- /rapidjson/test/unittest/unittest.cpp: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making RapidJSON available. 2 | // 3 | // Copyright (C) 2015 THL A29 Limited, a Tencent company, and Milo Yip. 4 | // 5 | // Licensed under the MIT License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // http://opensource.org/licenses/MIT 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #include "unittest.h" 16 | #include "rapidjson/rapidjson.h" 17 | 18 | #ifdef __clang__ 19 | #pragma GCC diagnostic push 20 | #if __has_warning("-Wdeprecated") 21 | #pragma GCC diagnostic ignored "-Wdeprecated" 22 | #endif 23 | #endif 24 | 25 | AssertException::~AssertException() throw() {} 26 | 27 | #ifdef __clang__ 28 | #pragma GCC diagnostic pop 29 | #endif 30 | 31 | int main(int argc, char **argv) { 32 | ::testing::InitGoogleTest(&argc, argv); 33 | 34 | std::cout << "RapidJSON v" << RAPIDJSON_VERSION_STRING << std::endl; 35 | 36 | #ifdef _MSC_VER 37 | _CrtMemState memoryState = { 0 }; 38 | (void)memoryState; 39 | _CrtMemCheckpoint(&memoryState); 40 | //_CrtSetBreakAlloc(X); 41 | //void *testWhetherMemoryLeakDetectionWorks = malloc(1); 42 | #endif 43 | 44 | int ret = RUN_ALL_TESTS(); 45 | 46 | #ifdef _MSC_VER 47 | // Current gtest constantly leak 2 blocks at exit 48 | _CrtMemDumpAllObjectsSince(&memoryState); 49 | #endif 50 | return ret; 51 | } 52 | -------------------------------------------------------------------------------- /rapidjson/test/valgrind.supp: -------------------------------------------------------------------------------- 1 | { 2 | Suppress wcslen valgrind report 1 3 | Memcheck:Cond 4 | fun:__wcslen_sse2 5 | } 6 | 7 | { 8 | Suppress wcslen valgrind report 2 9 | Memcheck:Addr8 10 | fun:__wcslen_sse2 11 | } 12 | 13 | { 14 | Suppress wcslen valgrind report 3 15 | Memcheck:Value8 16 | fun:__wcslen_sse2 17 | } 18 | -------------------------------------------------------------------------------- /resource.h: -------------------------------------------------------------------------------- 1 | //{{NO_DEPENDENCIES}} 2 | // Microsoft Visual C++ generated include file. 3 | // Used by CVE-2021-4104, CVE-2021-44228, CVE-2021-45046, CVE-2021-45105 Scan.rc 4 | 5 | // Next default values for new objects 6 | // 7 | #ifdef APSTUDIO_INVOKED 8 | #ifndef APSTUDIO_READONLY_SYMBOLS 9 | #define _APS_NEXT_RESOURCE_VALUE 101 10 | #define _APS_NEXT_COMMAND_VALUE 40001 11 | #define _APS_NEXT_CONTROL_VALUE 1001 12 | #define _APS_NEXT_SYMED_VALUE 101 13 | #endif 14 | #endif 15 | -------------------------------------------------------------------------------- /stdafx.cpp: -------------------------------------------------------------------------------- 1 | #include "stdafx.h" 2 | -------------------------------------------------------------------------------- /stdafx.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include "targetver.h" 4 | #include 5 | #include 6 | #include 7 | #include 8 | #include 9 | 10 | #include 11 | #include 12 | #include 13 | #include 14 | #include 15 | #include 16 | #include 17 | #include 18 | #include 19 | #include 20 | #include 21 | 22 | #include "minizip/ioapi.h" 23 | #include "minizip/zip.h" 24 | #include "minizip/unzip.h" 25 | #include "minizip/iowin32.h" 26 | 27 | #include "archive.h" 28 | #include "archive_entry.h" 29 | 30 | #include "Log.h" -------------------------------------------------------------------------------- /targetver.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | // Including SDKDDKVer.h defines the highest available Windows platform. 4 | 5 | // If you wish to build your application for a previous Windows platform, include WinSDKVer.h and 6 | // set the _WIN32_WINNT macro to the platform you wish to support before including SDKDDKVer.h. 7 | 8 | #include 9 | 10 | // 11 | // Target Windows XP SP3 with Internet Explorer 5.01 12 | // Use of any newer API(s) should use LoadLibrary()/GetProcAddress() 13 | // 14 | #ifndef WINVER 15 | #define WINVER 0x0501 16 | #endif 17 | #ifndef _WIN32_WINNT 18 | #define _WIN32_WINNT 0x0501 19 | #endif 20 | #ifndef _WIN32_WINDOWS 21 | #define _WIN32_WINDOWS 0x0501 22 | #endif 23 | #ifndef _WIN32_IE 24 | #define _WIN32_IE 0x0501 25 | #endif 26 | #ifndef NTDDI_VERSION 27 | #define NTDDI_VERSION 0x05010300 28 | #endif 29 | 30 | #include 31 | 32 | // Newly defined versions of Windows 33 | 34 | #ifndef _WIN32_WINNT_WIN8 35 | #define _WIN32_WINNT_WIN8 0x0602 36 | #endif 37 | #ifndef _WIN32_WINNT_WINBLUE 38 | #define _WIN32_WINNT_WINBLUE 0x0603 39 | #endif 40 | #ifndef NTDDI_WIN8 41 | #define NTDDI_WIN8 0x06020000 42 | #endif 43 | #ifndef NTDDI_WINBLUE 44 | #define NTDDI_WINBLUE 0x06030000 45 | #endif 46 | 47 | -------------------------------------------------------------------------------- /tarlib/filesyshelpers.h: -------------------------------------------------------------------------------- 1 | // +-------------------------------------------------------------------------------------------+ 2 | // | tarlib - Windows library for handling TAR files | 3 | // | Created by Marius Bancila | 4 | // | Version 1.1 (2012.09.14) | 5 | // | Discussion board: http://codexpert.ro/forum/viewforum.php?f=47 | 6 | // | License: Creative Commons Attribution-ShareAlike (CC BY-SA) | 7 | // | http://creativecommons.org/licenses/by-sa/3.0/ | 8 | // | Disclaimer: The software is provided "as-is". | 9 | // | No claim of suitability, guarantee, or any warranty whatsoever is provided. | 10 | // +-------------------------------------------------------------------------------------------+ 11 | 12 | #pragma once 13 | 14 | #include 15 | #include 16 | 17 | namespace tarlib 18 | { 19 | namespace utils 20 | { 21 | bool createfolder(std::string const &folder); 22 | std::string path_combine(std::string const& path1, std::string const &path2); 23 | bool path_exists(std::string const &path); 24 | bool path_is_folder(std::string const &path); 25 | bool path_is_file(std::string const &path); 26 | std::string extract_filename(std::string const &path); 27 | std::string extract_foldername(std::string const &path); 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /tarlib/stringhelpers.cpp: -------------------------------------------------------------------------------- 1 | // +-------------------------------------------------------------------------------------------+ 2 | // | tarlib - Windows library for handling TAR files | 3 | // | Created by Marius Bancila | 4 | // | Version 1.1 (2012.09.14) | 5 | // | Discussion board: http://codexpert.ro/forum/viewforum.php?f=47 | 6 | // | License: Creative Commons Attribution-ShareAlike (CC BY-SA) | 7 | // | http://creativecommons.org/licenses/by-sa/3.0/ | 8 | // | Disclaimer: The software is provided "as-is". | 9 | // | No claim of suitability, guarantee, or any warranty whatsoever is provided. | 10 | // +-------------------------------------------------------------------------------------------+ 11 | 12 | #include "stringhelpers.h" 13 | 14 | namespace tarlib 15 | { 16 | namespace utils 17 | { 18 | bool ends_with_ci(std::string const& text, std::string const& ending) 19 | { 20 | ci_string citext = text.c_str(); 21 | ci_string ciending = ending.c_str(); 22 | 23 | if (citext.length() >= ciending.length()) { 24 | return (0 == citext.compare (citext.length() - ciending.length(), ciending.length(), ciending)); 25 | } 26 | 27 | return false; 28 | } 29 | 30 | bool starts_with_ci(std::string const& text, std::string const& ending) 31 | { 32 | ci_string citext = text.c_str(); 33 | ci_string ciending = ending.c_str(); 34 | 35 | if (citext.length() >= ciending.length()) { 36 | return (0 == citext.compare (0, ciending.length(), ciending)); 37 | } 38 | 39 | return false; 40 | } 41 | 42 | } 43 | } -------------------------------------------------------------------------------- /tarlib/stringhelpers.h: -------------------------------------------------------------------------------- 1 | // +-------------------------------------------------------------------------------------------+ 2 | // | tarlib - Windows library for handling TAR files | 3 | // | Created by Marius Bancila | 4 | // | Version 1.1 (2012.09.14) | 5 | // | Discussion board: http://codexpert.ro/forum/viewforum.php?f=47 | 6 | // | License: Creative Commons Attribution-ShareAlike (CC BY-SA) | 7 | // | http://creativecommons.org/licenses/by-sa/3.0/ | 8 | // | Disclaimer: The software is provided "as-is". | 9 | // | No claim of suitability, guarantee, or any warranty whatsoever is provided. | 10 | // +-------------------------------------------------------------------------------------------+ 11 | 12 | #pragma once 13 | #include 14 | 15 | namespace tarlib 16 | { 17 | namespace utils 18 | { 19 | struct ci_char_traits : public std::char_traits 20 | { 21 | static bool eq(char c1, char c2) { return toupper(c1) == toupper(c2); } 22 | static bool ne(char c1, char c2) { return toupper(c1) != toupper(c2); } 23 | static bool lt(char c1, char c2) { return toupper(c1) < toupper(c2); } 24 | static int compare(const char* s1, const char* s2, size_t n) { 25 | while( n-- != 0 ) { 26 | if( toupper(*s1) < toupper(*s2) ) return -1; 27 | if( toupper(*s1) > toupper(*s2) ) return 1; 28 | ++s1; ++s2; 29 | } 30 | return 0; 31 | } 32 | static const char* find(const char* s, int n, char a) { 33 | while( n-- > 0 && toupper(*s) != toupper(a) ) { 34 | ++s; 35 | } 36 | return s; 37 | } 38 | }; 39 | 40 | typedef std::basic_string ci_string; 41 | 42 | bool ends_with_ci(std::string const& text, std::string const& ending); 43 | bool starts_with_ci(std::string const& text, std::string const& ending); 44 | } 45 | } -------------------------------------------------------------------------------- /zlib/.gitignore: -------------------------------------------------------------------------------- 1 | *.diff 2 | *.patch 3 | *.orig 4 | *.rej 5 | 6 | *~ 7 | *.a 8 | *.lo 9 | *.o 10 | *.dylib 11 | 12 | *.gcda 13 | *.gcno 14 | *.gcov 15 | 16 | /example 17 | /example64 18 | /examplesh 19 | /libz.so* 20 | /minigzip 21 | /minigzip64 22 | /minigzipsh 23 | /zlib.pc 24 | /configure.log 25 | 26 | .DS_Store 27 | -------------------------------------------------------------------------------- /zlib/INDEX: -------------------------------------------------------------------------------- 1 | CMakeLists.txt cmake build file 2 | ChangeLog history of changes 3 | FAQ Frequently Asked Questions about zlib 4 | INDEX this file 5 | Makefile dummy Makefile that tells you to ./configure 6 | Makefile.in template for Unix Makefile 7 | README guess what 8 | configure configure script for Unix 9 | make_vms.com makefile for VMS 10 | test/example.c zlib usages examples for build testing 11 | test/minigzip.c minimal gzip-like functionality for build testing 12 | test/infcover.c inf*.c code coverage for build coverage testing 13 | treebuild.xml XML description of source file dependencies 14 | zconf.h.cmakein zconf.h template for cmake 15 | zconf.h.in zconf.h template for configure 16 | zlib.3 Man page for zlib 17 | zlib.3.pdf Man page in PDF format 18 | zlib.map Linux symbol information 19 | zlib.pc.in Template for pkg-config descriptor 20 | zlib.pc.cmakein zlib.pc template for cmake 21 | zlib2ansi perl script to convert source files for C++ compilation 22 | 23 | amiga/ makefiles for Amiga SAS C 24 | as400/ makefiles for AS/400 25 | doc/ documentation for formats and algorithms 26 | msdos/ makefiles for MSDOS 27 | nintendods/ makefile for Nintendo DS 28 | old/ makefiles for various architectures and zlib documentation 29 | files that have not yet been updated for zlib 1.2.x 30 | qnx/ makefiles for QNX 31 | watcom/ makefiles for OpenWatcom 32 | win32/ makefiles for Windows 33 | 34 | zlib public header files (required for library use): 35 | zconf.h 36 | zlib.h 37 | 38 | private source files used to build the zlib library: 39 | adler32.c 40 | compress.c 41 | crc32.c 42 | crc32.h 43 | deflate.c 44 | deflate.h 45 | gzclose.c 46 | gzguts.h 47 | gzlib.c 48 | gzread.c 49 | gzwrite.c 50 | infback.c 51 | inffast.c 52 | inffast.h 53 | inffixed.h 54 | inflate.c 55 | inflate.h 56 | inftrees.c 57 | inftrees.h 58 | trees.c 59 | trees.h 60 | uncompr.c 61 | zutil.c 62 | zutil.h 63 | 64 | source files for sample programs 65 | See examples/README.examples 66 | 67 | unsupported contributions by third parties 68 | See contrib/README.contrib 69 | -------------------------------------------------------------------------------- /zlib/Makefile: -------------------------------------------------------------------------------- 1 | all: 2 | -@echo "Please use ./configure first. Thank you." 3 | 4 | distclean: 5 | make -f Makefile.in distclean 6 | -------------------------------------------------------------------------------- /zlib/amiga/Makefile.pup: -------------------------------------------------------------------------------- 1 | # Amiga powerUP (TM) Makefile 2 | # makefile for libpng and SAS C V6.58/7.00 PPC compiler 3 | # Copyright (C) 1998 by Andreas R. Kleinert 4 | 5 | LIBNAME = libzip.a 6 | 7 | CC = scppc 8 | CFLAGS = NOSTKCHK NOSINT OPTIMIZE OPTGO OPTPEEP OPTINLOCAL OPTINL \ 9 | OPTLOOP OPTRDEP=8 OPTDEP=8 OPTCOMP=8 NOVER 10 | AR = ppc-amigaos-ar cr 11 | RANLIB = ppc-amigaos-ranlib 12 | LD = ppc-amigaos-ld -r 13 | LDFLAGS = -o 14 | LDLIBS = LIB:scppc.a LIB:end.o 15 | RM = delete quiet 16 | 17 | OBJS = adler32.o compress.o crc32.o gzclose.o gzlib.o gzread.o gzwrite.o \ 18 | uncompr.o deflate.o trees.o zutil.o inflate.o infback.o inftrees.o inffast.o 19 | 20 | TEST_OBJS = example.o minigzip.o 21 | 22 | all: example minigzip 23 | 24 | check: test 25 | test: all 26 | example 27 | echo hello world | minigzip | minigzip -d 28 | 29 | $(LIBNAME): $(OBJS) 30 | $(AR) $@ $(OBJS) 31 | -$(RANLIB) $@ 32 | 33 | example: example.o $(LIBNAME) 34 | $(LD) $(LDFLAGS) $@ LIB:c_ppc.o $@.o $(LIBNAME) $(LDLIBS) 35 | 36 | minigzip: minigzip.o $(LIBNAME) 37 | $(LD) $(LDFLAGS) $@ LIB:c_ppc.o $@.o $(LIBNAME) $(LDLIBS) 38 | 39 | mostlyclean: clean 40 | clean: 41 | $(RM) *.o example minigzip $(LIBNAME) foo.gz 42 | 43 | zip: 44 | zip -ul9 zlib README ChangeLog Makefile Make????.??? Makefile.?? \ 45 | descrip.mms *.[ch] 46 | 47 | tgz: 48 | cd ..; tar cfz zlib/zlib.tgz zlib/README zlib/ChangeLog zlib/Makefile \ 49 | zlib/Make????.??? zlib/Makefile.?? zlib/descrip.mms zlib/*.[ch] 50 | 51 | # DO NOT DELETE THIS LINE -- make depend depends on it. 52 | 53 | adler32.o: zlib.h zconf.h 54 | compress.o: zlib.h zconf.h 55 | crc32.o: crc32.h zlib.h zconf.h 56 | deflate.o: deflate.h zutil.h zlib.h zconf.h 57 | example.o: zlib.h zconf.h 58 | gzclose.o: zlib.h zconf.h gzguts.h 59 | gzlib.o: zlib.h zconf.h gzguts.h 60 | gzread.o: zlib.h zconf.h gzguts.h 61 | gzwrite.o: zlib.h zconf.h gzguts.h 62 | inffast.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h 63 | inflate.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h 64 | infback.o: zutil.h zlib.h zconf.h inftrees.h inflate.h inffast.h 65 | inftrees.o: zutil.h zlib.h zconf.h inftrees.h 66 | minigzip.o: zlib.h zconf.h 67 | trees.o: deflate.h zutil.h zlib.h zconf.h trees.h 68 | uncompr.o: zlib.h zconf.h 69 | zutil.o: zutil.h zlib.h zconf.h 70 | -------------------------------------------------------------------------------- /zlib/amiga/Makefile.sas: -------------------------------------------------------------------------------- 1 | # SMakefile for zlib 2 | # Modified from the standard UNIX Makefile Copyright Jean-loup Gailly 3 | # Osma Ahvenlampi 4 | # Amiga, SAS/C 6.56 & Smake 5 | 6 | CC=sc 7 | CFLAGS=OPT 8 | #CFLAGS=OPT CPU=68030 9 | #CFLAGS=DEBUG=LINE 10 | LDFLAGS=LIB z.lib 11 | 12 | SCOPTIONS=OPTSCHED OPTINLINE OPTALIAS OPTTIME OPTINLOCAL STRMERGE \ 13 | NOICONS PARMS=BOTH NOSTACKCHECK UTILLIB NOVERSION ERRORREXX \ 14 | DEF=POSTINC 15 | 16 | OBJS = adler32.o compress.o crc32.o gzclose.o gzlib.o gzread.o gzwrite.o \ 17 | uncompr.o deflate.o trees.o zutil.o inflate.o infback.o inftrees.o inffast.o 18 | 19 | TEST_OBJS = example.o minigzip.o 20 | 21 | all: SCOPTIONS example minigzip 22 | 23 | check: test 24 | test: all 25 | example 26 | echo hello world | minigzip | minigzip -d 27 | 28 | install: z.lib 29 | copy clone zlib.h zconf.h INCLUDE: 30 | copy clone z.lib LIB: 31 | 32 | z.lib: $(OBJS) 33 | oml z.lib r $(OBJS) 34 | 35 | example: example.o z.lib 36 | $(CC) $(CFLAGS) LINK TO $@ example.o $(LDFLAGS) 37 | 38 | minigzip: minigzip.o z.lib 39 | $(CC) $(CFLAGS) LINK TO $@ minigzip.o $(LDFLAGS) 40 | 41 | mostlyclean: clean 42 | clean: 43 | -delete force quiet example minigzip *.o z.lib foo.gz *.lnk SCOPTIONS 44 | 45 | SCOPTIONS: Makefile.sas 46 | copy to $@ 2 | 3 | A .Net wrapper library around ZLib1.dll 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /zlib/contrib/dotzlib/DotZLib.chm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/zlib/contrib/dotzlib/DotZLib.chm -------------------------------------------------------------------------------- /zlib/contrib/dotzlib/DotZLib.sln: -------------------------------------------------------------------------------- 1 | Microsoft Visual Studio Solution File, Format Version 8.00 2 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DotZLib", "DotZLib\DotZLib.csproj", "{BB1EE0B1-1808-46CB-B786-949D91117FC5}" 3 | ProjectSection(ProjectDependencies) = postProject 4 | EndProjectSection 5 | EndProject 6 | Global 7 | GlobalSection(SolutionConfiguration) = preSolution 8 | Debug = Debug 9 | Release = Release 10 | EndGlobalSection 11 | GlobalSection(ProjectConfiguration) = postSolution 12 | {BB1EE0B1-1808-46CB-B786-949D91117FC5}.Debug.ActiveCfg = Debug|.NET 13 | {BB1EE0B1-1808-46CB-B786-949D91117FC5}.Debug.Build.0 = Debug|.NET 14 | {BB1EE0B1-1808-46CB-B786-949D91117FC5}.Release.ActiveCfg = Release|.NET 15 | {BB1EE0B1-1808-46CB-B786-949D91117FC5}.Release.Build.0 = Release|.NET 16 | EndGlobalSection 17 | GlobalSection(ExtensibilityGlobals) = postSolution 18 | EndGlobalSection 19 | GlobalSection(ExtensibilityAddIns) = postSolution 20 | EndGlobalSection 21 | EndGlobal 22 | -------------------------------------------------------------------------------- /zlib/contrib/dotzlib/DotZLib/ChecksumImpl.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/zlib/contrib/dotzlib/DotZLib/ChecksumImpl.cs -------------------------------------------------------------------------------- /zlib/contrib/dotzlib/DotZLib/CircularBuffer.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/zlib/contrib/dotzlib/DotZLib/CircularBuffer.cs -------------------------------------------------------------------------------- /zlib/contrib/dotzlib/DotZLib/CodecBase.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/zlib/contrib/dotzlib/DotZLib/CodecBase.cs -------------------------------------------------------------------------------- /zlib/contrib/dotzlib/DotZLib/Deflater.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/zlib/contrib/dotzlib/DotZLib/Deflater.cs -------------------------------------------------------------------------------- /zlib/contrib/dotzlib/DotZLib/DotZLib.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/zlib/contrib/dotzlib/DotZLib/DotZLib.cs -------------------------------------------------------------------------------- /zlib/contrib/dotzlib/DotZLib/GZipStream.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/zlib/contrib/dotzlib/DotZLib/GZipStream.cs -------------------------------------------------------------------------------- /zlib/contrib/dotzlib/DotZLib/Inflater.cs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/zlib/contrib/dotzlib/DotZLib/Inflater.cs -------------------------------------------------------------------------------- /zlib/contrib/dotzlib/LICENSE_1_0.txt: -------------------------------------------------------------------------------- 1 | Boost Software License - Version 1.0 - August 17th, 2003 2 | 3 | Permission is hereby granted, free of charge, to any person or organization 4 | obtaining a copy of the software and accompanying documentation covered by 5 | this license (the "Software") to use, reproduce, display, distribute, 6 | execute, and transmit the Software, and to prepare derivative works of the 7 | Software, and to permit third-parties to whom the Software is furnished to 8 | do so, all subject to the following: 9 | 10 | The copyright notices in the Software and this entire statement, including 11 | the above license grant, this restriction and the following disclaimer, 12 | must be included in all copies of the Software, in whole or in part, and 13 | all derivative works of the Software, unless such copies or derivative 14 | works are solely in the form of machine-executable object code generated by 15 | a source language processor. 16 | 17 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 18 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 19 | FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT 20 | SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE 21 | FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE, 22 | ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 23 | DEALINGS IN THE SOFTWARE. -------------------------------------------------------------------------------- /zlib/contrib/infback9/README: -------------------------------------------------------------------------------- 1 | See infback9.h for what this is and how to use it. 2 | -------------------------------------------------------------------------------- /zlib/contrib/infback9/infback9.h: -------------------------------------------------------------------------------- 1 | /* infback9.h -- header for using inflateBack9 functions 2 | * Copyright (C) 2003 Mark Adler 3 | * For conditions of distribution and use, see copyright notice in zlib.h 4 | */ 5 | 6 | /* 7 | * This header file and associated patches provide a decoder for PKWare's 8 | * undocumented deflate64 compression method (method 9). Use with infback9.c, 9 | * inftree9.h, inftree9.c, and inffix9.h. These patches are not supported. 10 | * This should be compiled with zlib, since it uses zutil.h and zutil.o. 11 | * This code has not yet been tested on 16-bit architectures. See the 12 | * comments in zlib.h for inflateBack() usage. These functions are used 13 | * identically, except that there is no windowBits parameter, and a 64K 14 | * window must be provided. Also if int's are 16 bits, then a zero for 15 | * the third parameter of the "out" function actually means 65536UL. 16 | * zlib.h must be included before this header file. 17 | */ 18 | 19 | #ifdef __cplusplus 20 | extern "C" { 21 | #endif 22 | 23 | ZEXTERN int ZEXPORT inflateBack9 OF((z_stream FAR *strm, 24 | in_func in, void FAR *in_desc, 25 | out_func out, void FAR *out_desc)); 26 | ZEXTERN int ZEXPORT inflateBack9End OF((z_stream FAR *strm)); 27 | ZEXTERN int ZEXPORT inflateBack9Init_ OF((z_stream FAR *strm, 28 | unsigned char FAR *window, 29 | const char *version, 30 | int stream_size)); 31 | #define inflateBack9Init(strm, window) \ 32 | inflateBack9Init_((strm), (window), \ 33 | ZLIB_VERSION, sizeof(z_stream)) 34 | 35 | #ifdef __cplusplus 36 | } 37 | #endif 38 | -------------------------------------------------------------------------------- /zlib/contrib/infback9/inflate9.h: -------------------------------------------------------------------------------- 1 | /* inflate9.h -- internal inflate state definition 2 | * Copyright (C) 1995-2003 Mark Adler 3 | * For conditions of distribution and use, see copyright notice in zlib.h 4 | */ 5 | 6 | /* WARNING: this file should *not* be used by applications. It is 7 | part of the implementation of the compression library and is 8 | subject to change. Applications should only use zlib.h. 9 | */ 10 | 11 | /* Possible inflate modes between inflate() calls */ 12 | typedef enum { 13 | TYPE, /* i: waiting for type bits, including last-flag bit */ 14 | STORED, /* i: waiting for stored size (length and complement) */ 15 | TABLE, /* i: waiting for dynamic block table lengths */ 16 | LEN, /* i: waiting for length/lit code */ 17 | DONE, /* finished check, done -- remain here until reset */ 18 | BAD /* got a data error -- remain here until reset */ 19 | } inflate_mode; 20 | 21 | /* 22 | State transitions between above modes - 23 | 24 | (most modes can go to the BAD mode -- not shown for clarity) 25 | 26 | Read deflate blocks: 27 | TYPE -> STORED or TABLE or LEN or DONE 28 | STORED -> TYPE 29 | TABLE -> LENLENS -> CODELENS -> LEN 30 | Read deflate codes: 31 | LEN -> LEN or TYPE 32 | */ 33 | 34 | /* state maintained between inflate() calls. Approximately 7K bytes. */ 35 | struct inflate_state { 36 | /* sliding window */ 37 | unsigned char FAR *window; /* allocated sliding window, if needed */ 38 | /* dynamic table building */ 39 | unsigned ncode; /* number of code length code lengths */ 40 | unsigned nlen; /* number of length code lengths */ 41 | unsigned ndist; /* number of distance code lengths */ 42 | unsigned have; /* number of code lengths in lens[] */ 43 | code FAR *next; /* next available space in codes[] */ 44 | unsigned short lens[320]; /* temporary storage for code lengths */ 45 | unsigned short work[288]; /* work area for code table building */ 46 | code codes[ENOUGH]; /* space for code tables */ 47 | }; 48 | -------------------------------------------------------------------------------- /zlib/contrib/iostream/test.cpp: -------------------------------------------------------------------------------- 1 | 2 | #include "zfstream.h" 3 | 4 | int main() { 5 | 6 | // Construct a stream object with this filebuffer. Anything sent 7 | // to this stream will go to standard out. 8 | gzofstream os( 1, ios::out ); 9 | 10 | // This text is getting compressed and sent to stdout. 11 | // To prove this, run 'test | zcat'. 12 | os << "Hello, Mommy" << endl; 13 | 14 | os << setcompressionlevel( Z_NO_COMPRESSION ); 15 | os << "hello, hello, hi, ho!" << endl; 16 | 17 | setcompressionlevel( os, Z_DEFAULT_COMPRESSION ) 18 | << "I'm compressing again" << endl; 19 | 20 | os.close(); 21 | 22 | return 0; 23 | 24 | } 25 | -------------------------------------------------------------------------------- /zlib/contrib/iostream2/zstream_test.cpp: -------------------------------------------------------------------------------- 1 | #include "zstream.h" 2 | #include 3 | #include 4 | #include 5 | 6 | void main() { 7 | char h[256] = "Hello"; 8 | char* g = "Goodbye"; 9 | ozstream out("temp.gz"); 10 | out < "This works well" < h < g; 11 | out.close(); 12 | 13 | izstream in("temp.gz"); // read it back 14 | char *x = read_string(in), *y = new char[256], z[256]; 15 | in > y > z; 16 | in.close(); 17 | cout << x << endl << y << endl << z << endl; 18 | 19 | out.open("temp.gz"); // try ascii output; zcat temp.gz to see the results 20 | out << setw(50) << setfill('#') << setprecision(20) << x << endl << y << endl << z << endl; 21 | out << z << endl << y << endl << x << endl; 22 | out << 1.1234567890123456789 << endl; 23 | 24 | delete[] x; delete[] y; 25 | } 26 | -------------------------------------------------------------------------------- /zlib/contrib/iostream3/README: -------------------------------------------------------------------------------- 1 | These classes provide a C++ stream interface to the zlib library. It allows you 2 | to do things like: 3 | 4 | gzofstream outf("blah.gz"); 5 | outf << "These go into the gzip file " << 123 << endl; 6 | 7 | It does this by deriving a specialized stream buffer for gzipped files, which is 8 | the way Stroustrup would have done it. :-> 9 | 10 | The gzifstream and gzofstream classes were originally written by Kevin Ruland 11 | and made available in the zlib contrib/iostream directory. The older version still 12 | compiles under gcc 2.xx, but not under gcc 3.xx, which sparked the development of 13 | this version. 14 | 15 | The new classes are as standard-compliant as possible, closely following the 16 | approach of the standard library's fstream classes. It compiles under gcc versions 17 | 3.2 and 3.3, but not under gcc 2.xx. This is mainly due to changes in the standard 18 | library naming scheme. The new version of gzifstream/gzofstream/gzfilebuf differs 19 | from the previous one in the following respects: 20 | - added showmanyc 21 | - added setbuf, with support for unbuffered output via setbuf(0,0) 22 | - a few bug fixes of stream behavior 23 | - gzipped output file opened with default compression level instead of maximum level 24 | - setcompressionlevel()/strategy() members replaced by single setcompression() 25 | 26 | The code is provided "as is", with the permission to use, copy, modify, distribute 27 | and sell it for any purpose without fee. 28 | 29 | Ludwig Schwardt 30 | 31 | 32 | DSP Lab 33 | Electrical & Electronic Engineering Department 34 | University of Stellenbosch 35 | South Africa 36 | -------------------------------------------------------------------------------- /zlib/contrib/iostream3/TODO: -------------------------------------------------------------------------------- 1 | Possible upgrades to gzfilebuf: 2 | 3 | - The ability to do putback (e.g. putbackfail) 4 | 5 | - The ability to seek (zlib supports this, but could be slow/tricky) 6 | 7 | - Simultaneous read/write access (does it make sense?) 8 | 9 | - Support for ios_base::ate open mode 10 | 11 | - Locale support? 12 | 13 | - Check public interface to see which calls give problems 14 | (due to dependence on library internals) 15 | 16 | - Override operator<<(ostream&, gzfilebuf*) to allow direct copying 17 | of stream buffer to stream ( i.e. os << is.rdbuf(); ) 18 | -------------------------------------------------------------------------------- /zlib/contrib/iostream3/test.cc: -------------------------------------------------------------------------------- 1 | /* 2 | * Test program for gzifstream and gzofstream 3 | * 4 | * by Ludwig Schwardt 5 | * original version by Kevin Ruland 6 | */ 7 | 8 | #include "zfstream.h" 9 | #include // for cout 10 | 11 | int main() { 12 | 13 | gzofstream outf; 14 | gzifstream inf; 15 | char buf[80]; 16 | 17 | outf.open("test1.txt.gz"); 18 | outf << "The quick brown fox sidestepped the lazy canine\n" 19 | << 1.3 << "\nPlan " << 9 << std::endl; 20 | outf.close(); 21 | std::cout << "Wrote the following message to 'test1.txt.gz' (check with zcat or zless):\n" 22 | << "The quick brown fox sidestepped the lazy canine\n" 23 | << 1.3 << "\nPlan " << 9 << std::endl; 24 | 25 | std::cout << "\nReading 'test1.txt.gz' (buffered) produces:\n"; 26 | inf.open("test1.txt.gz"); 27 | while (inf.getline(buf,80,'\n')) { 28 | std::cout << buf << "\t(" << inf.rdbuf()->in_avail() << " chars left in buffer)\n"; 29 | } 30 | inf.close(); 31 | 32 | outf.rdbuf()->pubsetbuf(0,0); 33 | outf.open("test2.txt.gz"); 34 | outf << setcompression(Z_NO_COMPRESSION) 35 | << "The quick brown fox sidestepped the lazy canine\n" 36 | << 1.3 << "\nPlan " << 9 << std::endl; 37 | outf.close(); 38 | std::cout << "\nWrote the same message to 'test2.txt.gz' in uncompressed form"; 39 | 40 | std::cout << "\nReading 'test2.txt.gz' (unbuffered) produces:\n"; 41 | inf.rdbuf()->pubsetbuf(0,0); 42 | inf.open("test2.txt.gz"); 43 | while (inf.getline(buf,80,'\n')) { 44 | std::cout << buf << "\t(" << inf.rdbuf()->in_avail() << " chars left in buffer)\n"; 45 | } 46 | inf.close(); 47 | 48 | return 0; 49 | 50 | } 51 | -------------------------------------------------------------------------------- /zlib/contrib/masmx64/bld_ml64.bat: -------------------------------------------------------------------------------- 1 | ml64.exe /Flinffasx64 /c /Zi inffasx64.asm 2 | ml64.exe /Flgvmat64 /c /Zi gvmat64.asm 3 | -------------------------------------------------------------------------------- /zlib/contrib/masmx64/readme.txt: -------------------------------------------------------------------------------- 1 | Summary 2 | ------- 3 | This directory contains ASM implementations of the functions 4 | longest_match() and inflate_fast(), for 64 bits x86 (both AMD64 and Intel EM64t), 5 | for use with Microsoft Macro Assembler (x64) for AMD64 and Microsoft C++ 64 bits. 6 | 7 | gvmat64.asm is written by Gilles Vollant (2005), by using Brian Raiter 686/32 bits 8 | assembly optimized version from Jean-loup Gailly original longest_match function 9 | 10 | inffasx64.asm and inffas8664.c were written by Chris Anderson, by optimizing 11 | original function from Mark Adler 12 | 13 | Use instructions 14 | ---------------- 15 | Assemble the .asm files using MASM and put the object files into the zlib source 16 | directory. You can also get object files here: 17 | 18 | http://www.winimage.com/zLibDll/zlib124_masm_obj.zip 19 | 20 | define ASMV and ASMINF in your project. Include inffas8664.c in your source tree, 21 | and inffasx64.obj and gvmat64.obj as object to link. 22 | 23 | 24 | Build instructions 25 | ------------------ 26 | run bld_64.bat with Microsoft Macro Assembler (x64) for AMD64 (ml64.exe) 27 | 28 | ml64.exe is given with Visual Studio 2005, Windows 2003 server DDK 29 | 30 | You can get Windows 2003 server DDK with ml64 and cl for AMD64 from 31 | http://www.microsoft.com/whdc/devtools/ddk/default.mspx for low price) 32 | -------------------------------------------------------------------------------- /zlib/contrib/masmx86/bld_ml32.bat: -------------------------------------------------------------------------------- 1 | ml /coff /Zi /c /Flmatch686.lst match686.asm 2 | ml /coff /Zi /c /Flinffas32.lst inffas32.asm 3 | -------------------------------------------------------------------------------- /zlib/contrib/masmx86/readme.txt: -------------------------------------------------------------------------------- 1 | 2 | Summary 3 | ------- 4 | This directory contains ASM implementations of the functions 5 | longest_match() and inflate_fast(). 6 | 7 | 8 | Use instructions 9 | ---------------- 10 | Assemble using MASM, and copy the object files into the zlib source 11 | directory, then run the appropriate makefile, as suggested below. You can 12 | donwload MASM from here: 13 | 14 | http://www.microsoft.com/downloads/details.aspx?displaylang=en&FamilyID=7a1c9da0-0510-44a2-b042-7ef370530c64 15 | 16 | You can also get objects files here: 17 | 18 | http://www.winimage.com/zLibDll/zlib124_masm_obj.zip 19 | 20 | Build instructions 21 | ------------------ 22 | * With Microsoft C and MASM: 23 | nmake -f win32/Makefile.msc LOC="-DASMV -DASMINF" OBJA="match686.obj inffas32.obj" 24 | 25 | * With Borland C and TASM: 26 | make -f win32/Makefile.bor LOCAL_ZLIB="-DASMV -DASMINF" OBJA="match686.obj inffas32.obj" OBJPA="+match686c.obj+match686.obj+inffas32.obj" 27 | 28 | -------------------------------------------------------------------------------- /zlib/contrib/minizip/Makefile: -------------------------------------------------------------------------------- 1 | CC=cc 2 | CFLAGS=-O -I../.. 3 | 4 | UNZ_OBJS = miniunz.o unzip.o ioapi.o ../../libz.a 5 | ZIP_OBJS = minizip.o zip.o ioapi.o ../../libz.a 6 | 7 | .c.o: 8 | $(CC) -c $(CFLAGS) $*.c 9 | 10 | all: miniunz minizip 11 | 12 | miniunz: $(UNZ_OBJS) 13 | $(CC) $(CFLAGS) -o $@ $(UNZ_OBJS) 14 | 15 | minizip: $(ZIP_OBJS) 16 | $(CC) $(CFLAGS) -o $@ $(ZIP_OBJS) 17 | 18 | test: miniunz minizip 19 | ./minizip test readme.txt 20 | ./miniunz -l test.zip 21 | mv readme.txt readme.old 22 | ./miniunz test.zip 23 | 24 | clean: 25 | /bin/rm -f *.o *~ minizip miniunz 26 | -------------------------------------------------------------------------------- /zlib/contrib/minizip/Makefile.am: -------------------------------------------------------------------------------- 1 | lib_LTLIBRARIES = libminizip.la 2 | 3 | if COND_DEMOS 4 | bin_PROGRAMS = miniunzip minizip 5 | endif 6 | 7 | zlib_top_srcdir = $(top_srcdir)/../.. 8 | zlib_top_builddir = $(top_builddir)/../.. 9 | 10 | AM_CPPFLAGS = -I$(zlib_top_srcdir) 11 | AM_LDFLAGS = -L$(zlib_top_builddir) 12 | 13 | if WIN32 14 | iowin32_src = iowin32.c 15 | iowin32_h = iowin32.h 16 | endif 17 | 18 | libminizip_la_SOURCES = \ 19 | ioapi.c \ 20 | mztools.c \ 21 | unzip.c \ 22 | zip.c \ 23 | ${iowin32_src} 24 | 25 | libminizip_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0 -lz 26 | 27 | minizip_includedir = $(includedir)/minizip 28 | minizip_include_HEADERS = \ 29 | crypt.h \ 30 | ioapi.h \ 31 | mztools.h \ 32 | unzip.h \ 33 | zip.h \ 34 | ${iowin32_h} 35 | 36 | pkgconfigdir = $(libdir)/pkgconfig 37 | pkgconfig_DATA = minizip.pc 38 | 39 | EXTRA_PROGRAMS = miniunzip minizip 40 | 41 | miniunzip_SOURCES = miniunz.c 42 | miniunzip_LDADD = libminizip.la 43 | 44 | minizip_SOURCES = minizip.c 45 | minizip_LDADD = libminizip.la -lz 46 | -------------------------------------------------------------------------------- /zlib/contrib/minizip/MiniZip64_Changes.txt: -------------------------------------------------------------------------------- 1 | 2 | MiniZip 1.1 was derrived from MiniZip at version 1.01f 3 | 4 | Change in 1.0 (Okt 2009) 5 | - **TODO - Add history** 6 | 7 | -------------------------------------------------------------------------------- /zlib/contrib/minizip/configure.ac: -------------------------------------------------------------------------------- 1 | # -*- Autoconf -*- 2 | # Process this file with autoconf to produce a configure script. 3 | 4 | AC_INIT([minizip], [1.2.11], [bugzilla.redhat.com]) 5 | AC_CONFIG_SRCDIR([minizip.c]) 6 | AM_INIT_AUTOMAKE([foreign]) 7 | LT_INIT 8 | 9 | AC_MSG_CHECKING([whether to build example programs]) 10 | AC_ARG_ENABLE([demos], AC_HELP_STRING([--enable-demos], [build example programs])) 11 | AM_CONDITIONAL([COND_DEMOS], [test "$enable_demos" = yes]) 12 | if test "$enable_demos" = yes 13 | then 14 | AC_MSG_RESULT([yes]) 15 | else 16 | AC_MSG_RESULT([no]) 17 | fi 18 | 19 | case "${host}" in 20 | *-mingw* | mingw*) 21 | WIN32="yes" 22 | ;; 23 | *) 24 | ;; 25 | esac 26 | AM_CONDITIONAL([WIN32], [test "${WIN32}" = "yes"]) 27 | 28 | 29 | AC_SUBST([HAVE_UNISTD_H], [0]) 30 | AC_CHECK_HEADER([unistd.h], [HAVE_UNISTD_H=1], []) 31 | AC_CONFIG_FILES([Makefile minizip.pc]) 32 | AC_OUTPUT 33 | -------------------------------------------------------------------------------- /zlib/contrib/minizip/iowin32.h: -------------------------------------------------------------------------------- 1 | /* iowin32.h -- IO base function header for compress/uncompress .zip 2 | Version 1.1, February 14h, 2010 3 | part of the MiniZip project - ( http://www.winimage.com/zLibDll/minizip.html ) 4 | 5 | Copyright (C) 1998-2010 Gilles Vollant (minizip) ( http://www.winimage.com/zLibDll/minizip.html ) 6 | 7 | Modifications for Zip64 support 8 | Copyright (C) 2009-2010 Mathias Svensson ( http://result42.com ) 9 | 10 | For more info read MiniZip_info.txt 11 | 12 | */ 13 | 14 | #include 15 | 16 | 17 | #ifdef __cplusplus 18 | extern "C" { 19 | #endif 20 | 21 | void fill_win32_filefunc OF((zlib_filefunc_def* pzlib_filefunc_def)); 22 | void fill_win32_filefunc64 OF((zlib_filefunc64_def* pzlib_filefunc_def)); 23 | void fill_win32_filefunc64A OF((zlib_filefunc64_def* pzlib_filefunc_def)); 24 | void fill_win32_filefunc64W OF((zlib_filefunc64_def* pzlib_filefunc_def)); 25 | 26 | #ifdef __cplusplus 27 | } 28 | #endif 29 | -------------------------------------------------------------------------------- /zlib/contrib/minizip/make_vms.com: -------------------------------------------------------------------------------- 1 | $ if f$search("ioapi.h_orig") .eqs. "" then copy ioapi.h ioapi.h_orig 2 | $ open/write zdef vmsdefs.h 3 | $ copy sys$input: zdef 4 | $ deck 5 | #define unix 6 | #define fill_zlib_filefunc64_32_def_from_filefunc32 fillzffunc64from 7 | #define Write_Zip64EndOfCentralDirectoryLocator Write_Zip64EoDLocator 8 | #define Write_Zip64EndOfCentralDirectoryRecord Write_Zip64EoDRecord 9 | #define Write_EndOfCentralDirectoryRecord Write_EoDRecord 10 | $ eod 11 | $ close zdef 12 | $ copy vmsdefs.h,ioapi.h_orig ioapi.h 13 | $ cc/include=[--]/prefix=all ioapi.c 14 | $ cc/include=[--]/prefix=all miniunz.c 15 | $ cc/include=[--]/prefix=all unzip.c 16 | $ cc/include=[--]/prefix=all minizip.c 17 | $ cc/include=[--]/prefix=all zip.c 18 | $ link miniunz,unzip,ioapi,[--]libz.olb/lib 19 | $ link minizip,zip,ioapi,[--]libz.olb/lib 20 | $ mcr []minizip test minizip_info.txt 21 | $ mcr []miniunz -l test.zip 22 | $ rename minizip_info.txt; minizip_info.txt_old 23 | $ mcr []miniunz test.zip 24 | $ delete test.zip;* 25 | $exit 26 | -------------------------------------------------------------------------------- /zlib/contrib/minizip/miniunzip.1: -------------------------------------------------------------------------------- 1 | .\" Hey, EMACS: -*- nroff -*- 2 | .TH miniunzip 1 "Nov 7, 2001" 3 | .\" Please adjust this date whenever revising the manpage. 4 | .\" 5 | .\" Some roff macros, for reference: 6 | .\" .nh disable hyphenation 7 | .\" .hy enable hyphenation 8 | .\" .ad l left justify 9 | .\" .ad b justify to both left and right margins 10 | .\" .nf disable filling 11 | .\" .fi enable filling 12 | .\" .br insert line break 13 | .\" .sp insert n+1 empty lines 14 | .\" for manpage-specific macros, see man(7) 15 | .SH NAME 16 | miniunzip - uncompress and examine ZIP archives 17 | .SH SYNOPSIS 18 | .B miniunzip 19 | .RI [ -exvlo ] 20 | zipfile [ files_to_extract ] [-d tempdir] 21 | .SH DESCRIPTION 22 | .B minizip 23 | is a simple tool which allows the extraction of compressed file 24 | archives in the ZIP format used by the MS-DOS utility PKZIP. It was 25 | written as a demonstration of the 26 | .IR zlib (3) 27 | library and therefore lack many of the features of the 28 | .IR unzip (1) 29 | program. 30 | .SH OPTIONS 31 | A number of options are supported. With the exception of 32 | .BI \-d\ tempdir 33 | these must be supplied before any 34 | other arguments and are: 35 | .TP 36 | .BI \-l\ ,\ \-\-v 37 | List the files in the archive without extracting them. 38 | .TP 39 | .B \-o 40 | Overwrite files without prompting for confirmation. 41 | .TP 42 | .B \-x 43 | Extract files (default). 44 | .PP 45 | The 46 | .I zipfile 47 | argument is the name of the archive to process. The next argument can be used 48 | to specify a single file to extract from the archive. 49 | 50 | Lastly, the following option can be specified at the end of the command-line: 51 | .TP 52 | .BI \-d\ tempdir 53 | Extract the archive in the directory 54 | .I tempdir 55 | rather than the current directory. 56 | .SH SEE ALSO 57 | .BR minizip (1), 58 | .BR zlib (3), 59 | .BR unzip (1). 60 | .SH AUTHOR 61 | This program was written by Gilles Vollant. This manual page was 62 | written by Mark Brown . The -d tempdir option 63 | was added by Dirk Eddelbuettel . 64 | -------------------------------------------------------------------------------- /zlib/contrib/minizip/minizip.1: -------------------------------------------------------------------------------- 1 | .\" Hey, EMACS: -*- nroff -*- 2 | .TH minizip 1 "May 2, 2001" 3 | .\" Please adjust this date whenever revising the manpage. 4 | .\" 5 | .\" Some roff macros, for reference: 6 | .\" .nh disable hyphenation 7 | .\" .hy enable hyphenation 8 | .\" .ad l left justify 9 | .\" .ad b justify to both left and right margins 10 | .\" .nf disable filling 11 | .\" .fi enable filling 12 | .\" .br insert line break 13 | .\" .sp insert n+1 empty lines 14 | .\" for manpage-specific macros, see man(7) 15 | .SH NAME 16 | minizip - create ZIP archives 17 | .SH SYNOPSIS 18 | .B minizip 19 | .RI [ -o ] 20 | zipfile [ " files" ... ] 21 | .SH DESCRIPTION 22 | .B minizip 23 | is a simple tool which allows the creation of compressed file archives 24 | in the ZIP format used by the MS-DOS utility PKZIP. It was written as 25 | a demonstration of the 26 | .IR zlib (3) 27 | library and therefore lack many of the features of the 28 | .IR zip (1) 29 | program. 30 | .SH OPTIONS 31 | The first argument supplied is the name of the ZIP archive to create or 32 | .RI -o 33 | in which case it is ignored and the second argument treated as the 34 | name of the ZIP file. If the ZIP file already exists it will be 35 | overwritten. 36 | .PP 37 | Subsequent arguments specify a list of files to place in the ZIP 38 | archive. If none are specified then an empty archive will be created. 39 | .SH SEE ALSO 40 | .BR miniunzip (1), 41 | .BR zlib (3), 42 | .BR zip (1). 43 | .SH AUTHOR 44 | This program was written by Gilles Vollant. This manual page was 45 | written by Mark Brown . 46 | 47 | -------------------------------------------------------------------------------- /zlib/contrib/minizip/minizip.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | includedir=@includedir@/minizip 5 | 6 | Name: minizip 7 | Description: Minizip zip file manipulation library 8 | Requires: 9 | Version: @PACKAGE_VERSION@ 10 | Libs: -L${libdir} -lminizip 11 | Libs.private: -lz 12 | Cflags: -I${includedir} 13 | -------------------------------------------------------------------------------- /zlib/contrib/minizip/mztools.h: -------------------------------------------------------------------------------- 1 | /* 2 | Additional tools for Minizip 3 | Code: Xavier Roche '2004 4 | License: Same as ZLIB (www.gzip.org) 5 | */ 6 | 7 | #ifndef _zip_tools_H 8 | #define _zip_tools_H 9 | 10 | #ifdef __cplusplus 11 | extern "C" { 12 | #endif 13 | 14 | #ifndef _ZLIB_H 15 | #include "zlib.h" 16 | #endif 17 | 18 | #include "unzip.h" 19 | 20 | /* Repair a ZIP file (missing central directory) 21 | file: file to recover 22 | fileOut: output file after recovery 23 | fileOutTmp: temporary file name used for recovery 24 | */ 25 | extern int ZEXPORT unzRepair(const char* file, 26 | const char* fileOut, 27 | const char* fileOutTmp, 28 | uLong* nRecovered, 29 | uLong* bytesRecovered); 30 | 31 | 32 | #ifdef __cplusplus 33 | } 34 | #endif 35 | 36 | 37 | #endif 38 | -------------------------------------------------------------------------------- /zlib/contrib/puff/Makefile: -------------------------------------------------------------------------------- 1 | CFLAGS=-O 2 | 3 | puff: puff.o pufftest.o 4 | 5 | puff.o: puff.h 6 | 7 | pufftest.o: puff.h 8 | 9 | test: puff 10 | puff zeros.raw 11 | 12 | puft: puff.c puff.h pufftest.o 13 | cc -fprofile-arcs -ftest-coverage -o puft puff.c pufftest.o 14 | 15 | # puff full coverage test (should say 100%) 16 | cov: puft 17 | @rm -f *.gcov *.gcda 18 | @puft -w zeros.raw 2>&1 | cat > /dev/null 19 | @echo '04' | xxd -r -p | puft 2> /dev/null || test $$? -eq 2 20 | @echo '00' | xxd -r -p | puft 2> /dev/null || test $$? -eq 2 21 | @echo '00 00 00 00 00' | xxd -r -p | puft 2> /dev/null || test $$? -eq 254 22 | @echo '00 01 00 fe ff' | xxd -r -p | puft 2> /dev/null || test $$? -eq 2 23 | @echo '01 01 00 fe ff 0a' | xxd -r -p | puft -f 2>&1 | cat > /dev/null 24 | @echo '02 7e ff ff' | xxd -r -p | puft 2> /dev/null || test $$? -eq 246 25 | @echo '02' | xxd -r -p | puft 2> /dev/null || test $$? -eq 2 26 | @echo '04 80 49 92 24 49 92 24 0f b4 ff ff c3 04' | xxd -r -p | puft 2> /dev/null || test $$? -eq 2 27 | @echo '04 80 49 92 24 49 92 24 71 ff ff 93 11 00' | xxd -r -p | puft 2> /dev/null || test $$? -eq 249 28 | @echo '04 c0 81 08 00 00 00 00 20 7f eb 0b 00 00' | xxd -r -p | puft 2> /dev/null || test $$? -eq 246 29 | @echo '0b 00 00' | xxd -r -p | puft -f 2>&1 | cat > /dev/null 30 | @echo '1a 07' | xxd -r -p | puft 2> /dev/null || test $$? -eq 246 31 | @echo '0c c0 81 00 00 00 00 00 90 ff 6b 04' | xxd -r -p | puft 2> /dev/null || test $$? -eq 245 32 | @puft -f zeros.raw 2>&1 | cat > /dev/null 33 | @echo 'fc 00 00' | xxd -r -p | puft 2> /dev/null || test $$? -eq 253 34 | @echo '04 00 fe ff' | xxd -r -p | puft 2> /dev/null || test $$? -eq 252 35 | @echo '04 00 24 49' | xxd -r -p | puft 2> /dev/null || test $$? -eq 251 36 | @echo '04 80 49 92 24 49 92 24 0f b4 ff ff c3 84' | xxd -r -p | puft 2> /dev/null || test $$? -eq 248 37 | @echo '04 00 24 e9 ff ff' | xxd -r -p | puft 2> /dev/null || test $$? -eq 250 38 | @echo '04 00 24 e9 ff 6d' | xxd -r -p | puft 2> /dev/null || test $$? -eq 247 39 | @gcov -n puff.c 40 | 41 | clean: 42 | rm -f puff puft *.o *.gc* 43 | -------------------------------------------------------------------------------- /zlib/contrib/puff/puff.h: -------------------------------------------------------------------------------- 1 | /* puff.h 2 | Copyright (C) 2002-2013 Mark Adler, all rights reserved 3 | version 2.3, 21 Jan 2013 4 | 5 | This software is provided 'as-is', without any express or implied 6 | warranty. In no event will the author be held liable for any damages 7 | arising from the use of this software. 8 | 9 | Permission is granted to anyone to use this software for any purpose, 10 | including commercial applications, and to alter it and redistribute it 11 | freely, subject to the following restrictions: 12 | 13 | 1. The origin of this software must not be misrepresented; you must not 14 | claim that you wrote the original software. If you use this software 15 | in a product, an acknowledgment in the product documentation would be 16 | appreciated but is not required. 17 | 2. Altered source versions must be plainly marked as such, and must not be 18 | misrepresented as being the original software. 19 | 3. This notice may not be removed or altered from any source distribution. 20 | 21 | Mark Adler madler@alumni.caltech.edu 22 | */ 23 | 24 | 25 | /* 26 | * See puff.c for purpose and usage. 27 | */ 28 | #ifndef NIL 29 | # define NIL ((unsigned char *)0) /* for no output option */ 30 | #endif 31 | 32 | int puff(unsigned char *dest, /* pointer to destination pointer */ 33 | unsigned long *destlen, /* amount of output space */ 34 | const unsigned char *source, /* pointer to source data pointer */ 35 | unsigned long *sourcelen); /* amount of input available */ 36 | -------------------------------------------------------------------------------- /zlib/contrib/puff/zeros.raw: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/zlib/contrib/puff/zeros.raw -------------------------------------------------------------------------------- /zlib/contrib/testzlib/testzlib.txt: -------------------------------------------------------------------------------- 1 | To build testzLib with Visual Studio 2005: 2 | 3 | copy to a directory file from : 4 | - root of zLib tree 5 | - contrib/testzlib 6 | - contrib/masmx86 7 | - contrib/masmx64 8 | - contrib/vstudio/vc7 9 | 10 | and open testzlib8.sln -------------------------------------------------------------------------------- /zlib/contrib/untgz/Makefile: -------------------------------------------------------------------------------- 1 | CC=cc 2 | CFLAGS=-g 3 | 4 | untgz: untgz.o ../../libz.a 5 | $(CC) $(CFLAGS) -o untgz untgz.o -L../.. -lz 6 | 7 | untgz.o: untgz.c ../../zlib.h 8 | $(CC) $(CFLAGS) -c -I../.. untgz.c 9 | 10 | ../../libz.a: 11 | cd ../..; ./configure; make 12 | 13 | clean: 14 | rm -f untgz untgz.o *~ 15 | -------------------------------------------------------------------------------- /zlib/contrib/untgz/Makefile.msc: -------------------------------------------------------------------------------- 1 | CC=cl 2 | CFLAGS=-MD 3 | 4 | untgz.exe: untgz.obj ..\..\zlib.lib 5 | $(CC) $(CFLAGS) untgz.obj ..\..\zlib.lib 6 | 7 | untgz.obj: untgz.c ..\..\zlib.h 8 | $(CC) $(CFLAGS) -c -I..\.. untgz.c 9 | 10 | ..\..\zlib.lib: 11 | cd ..\.. 12 | $(MAKE) -f win32\makefile.msc 13 | cd contrib\untgz 14 | 15 | clean: 16 | -del untgz.obj 17 | -del untgz.exe 18 | -------------------------------------------------------------------------------- /zlib/contrib/vstudio/vc10/miniunz.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {048af943-022b-4db6-beeb-a54c34774ee2} 6 | cpp;c;cxx;def;odl;idl;hpj;bat;asm 7 | 8 | 9 | {c1d600d2-888f-4aea-b73e-8b0dd9befa0c} 10 | h;hpp;hxx;hm;inl;inc 11 | 12 | 13 | {0844199a-966b-4f19-81db-1e0125e141b9} 14 | rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe 15 | 16 | 17 | 18 | 19 | Source Files 20 | 21 | 22 | -------------------------------------------------------------------------------- /zlib/contrib/vstudio/vc10/minizip.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {c0419b40-bf50-40da-b153-ff74215b79de} 6 | cpp;c;cxx;def;odl;idl;hpj;bat;asm 7 | 8 | 9 | {bb87b070-735b-478e-92ce-7383abb2f36c} 10 | h;hpp;hxx;hm;inl;inc 11 | 12 | 13 | {f46ab6a6-548f-43cb-ae96-681abb5bd5db} 14 | rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe 15 | 16 | 17 | 18 | 19 | Source Files 20 | 21 | 22 | -------------------------------------------------------------------------------- /zlib/contrib/vstudio/vc10/testzlibdll.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {fa61a89f-93fc-4c89-b29e-36224b7592f4} 6 | cpp;c;cxx;def;odl;idl;hpj;bat;asm 7 | 8 | 9 | {d4b85da0-2ba2-4934-b57f-e2584e3848ee} 10 | h;hpp;hxx;hm;inl;inc 11 | 12 | 13 | {e573e075-00bd-4a7d-bd67-a8cc9bfc5aca} 14 | rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe 15 | 16 | 17 | 18 | 19 | Source Files 20 | 21 | 22 | -------------------------------------------------------------------------------- /zlib/contrib/vstudio/vc10/zlib.rc: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #define IDR_VERSION1 1 4 | IDR_VERSION1 VERSIONINFO MOVEABLE IMPURE LOADONCALL DISCARDABLE 5 | FILEVERSION 1, 2, 11, 0 6 | PRODUCTVERSION 1, 2, 11, 0 7 | FILEFLAGSMASK VS_FFI_FILEFLAGSMASK 8 | FILEFLAGS 0 9 | FILEOS VOS_DOS_WINDOWS32 10 | FILETYPE VFT_DLL 11 | FILESUBTYPE 0 // not used 12 | BEGIN 13 | BLOCK "StringFileInfo" 14 | BEGIN 15 | BLOCK "040904E4" 16 | //language ID = U.S. English, char set = Windows, Multilingual 17 | 18 | BEGIN 19 | VALUE "FileDescription", "zlib data compression and ZIP file I/O library\0" 20 | VALUE "FileVersion", "1.2.11\0" 21 | VALUE "InternalName", "zlib\0" 22 | VALUE "OriginalFilename", "zlibwapi.dll\0" 23 | VALUE "ProductName", "ZLib.DLL\0" 24 | VALUE "Comments","DLL support by Alessandro Iacopetti & Gilles Vollant\0" 25 | VALUE "LegalCopyright", "(C) 1995-2017 Jean-loup Gailly & Mark Adler\0" 26 | END 27 | END 28 | BLOCK "VarFileInfo" 29 | BEGIN 30 | VALUE "Translation", 0x0409, 1252 31 | END 32 | END 33 | -------------------------------------------------------------------------------- /zlib/contrib/vstudio/vc11/zlib.rc: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #define IDR_VERSION1 1 4 | IDR_VERSION1 VERSIONINFO MOVEABLE IMPURE LOADONCALL DISCARDABLE 5 | FILEVERSION 1, 2, 11, 0 6 | PRODUCTVERSION 1, 2, 11, 0 7 | FILEFLAGSMASK VS_FFI_FILEFLAGSMASK 8 | FILEFLAGS 0 9 | FILEOS VOS_DOS_WINDOWS32 10 | FILETYPE VFT_DLL 11 | FILESUBTYPE 0 // not used 12 | BEGIN 13 | BLOCK "StringFileInfo" 14 | BEGIN 15 | BLOCK "040904E4" 16 | //language ID = U.S. English, char set = Windows, Multilingual 17 | 18 | BEGIN 19 | VALUE "FileDescription", "zlib data compression and ZIP file I/O library\0" 20 | VALUE "FileVersion", "1.2.11\0" 21 | VALUE "InternalName", "zlib\0" 22 | VALUE "OriginalFilename", "zlibwapi.dll\0" 23 | VALUE "ProductName", "ZLib.DLL\0" 24 | VALUE "Comments","DLL support by Alessandro Iacopetti & Gilles Vollant\0" 25 | VALUE "LegalCopyright", "(C) 1995-2017 Jean-loup Gailly & Mark Adler\0" 26 | END 27 | END 28 | BLOCK "VarFileInfo" 29 | BEGIN 30 | VALUE "Translation", 0x0409, 1252 31 | END 32 | END 33 | -------------------------------------------------------------------------------- /zlib/contrib/vstudio/vc12/zlib.rc: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #define IDR_VERSION1 1 4 | IDR_VERSION1 VERSIONINFO MOVEABLE IMPURE LOADONCALL DISCARDABLE 5 | FILEVERSION 1, 2, 11, 0 6 | PRODUCTVERSION 1, 2, 11, 0 7 | FILEFLAGSMASK VS_FFI_FILEFLAGSMASK 8 | FILEFLAGS 0 9 | FILEOS VOS_DOS_WINDOWS32 10 | FILETYPE VFT_DLL 11 | FILESUBTYPE 0 // not used 12 | BEGIN 13 | BLOCK "StringFileInfo" 14 | BEGIN 15 | BLOCK "040904E4" 16 | //language ID = U.S. English, char set = Windows, Multilingual 17 | 18 | BEGIN 19 | VALUE "FileDescription", "zlib data compression and ZIP file I/O library\0" 20 | VALUE "FileVersion", "1.2.11\0" 21 | VALUE "InternalName", "zlib\0" 22 | VALUE "OriginalFilename", "zlibwapi.dll\0" 23 | VALUE "ProductName", "ZLib.DLL\0" 24 | VALUE "Comments","DLL support by Alessandro Iacopetti & Gilles Vollant\0" 25 | VALUE "LegalCopyright", "(C) 1995-2017 Jean-loup Gailly & Mark Adler\0" 26 | END 27 | END 28 | BLOCK "VarFileInfo" 29 | BEGIN 30 | VALUE "Translation", 0x0409, 1252 31 | END 32 | END 33 | -------------------------------------------------------------------------------- /zlib/contrib/vstudio/vc14/zlib.rc: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #define IDR_VERSION1 1 4 | IDR_VERSION1 VERSIONINFO MOVEABLE IMPURE LOADONCALL DISCARDABLE 5 | FILEVERSION 1, 2, 11, 0 6 | PRODUCTVERSION 1, 2, 11, 0 7 | FILEFLAGSMASK VS_FFI_FILEFLAGSMASK 8 | FILEFLAGS 0 9 | FILEOS VOS_DOS_WINDOWS32 10 | FILETYPE VFT_DLL 11 | FILESUBTYPE 0 // not used 12 | BEGIN 13 | BLOCK "StringFileInfo" 14 | BEGIN 15 | BLOCK "040904E4" 16 | //language ID = U.S. English, char set = Windows, Multilingual 17 | 18 | BEGIN 19 | VALUE "FileDescription", "zlib data compression and ZIP file I/O library\0" 20 | VALUE "FileVersion", "1.2.11\0" 21 | VALUE "InternalName", "zlib\0" 22 | VALUE "OriginalFilename", "zlibwapi.dll\0" 23 | VALUE "ProductName", "ZLib.DLL\0" 24 | VALUE "Comments","DLL support by Alessandro Iacopetti & Gilles Vollant\0" 25 | VALUE "LegalCopyright", "(C) 1995-2017 Jean-loup Gailly & Mark Adler\0" 26 | END 27 | END 28 | BLOCK "VarFileInfo" 29 | BEGIN 30 | VALUE "Translation", 0x0409, 1252 31 | END 32 | END 33 | -------------------------------------------------------------------------------- /zlib/contrib/vstudio/vc9/zlib.rc: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #define IDR_VERSION1 1 4 | IDR_VERSION1 VERSIONINFO MOVEABLE IMPURE LOADONCALL DISCARDABLE 5 | FILEVERSION 1, 2, 11, 0 6 | PRODUCTVERSION 1, 2, 11, 0 7 | FILEFLAGSMASK VS_FFI_FILEFLAGSMASK 8 | FILEFLAGS 0 9 | FILEOS VOS_DOS_WINDOWS32 10 | FILETYPE VFT_DLL 11 | FILESUBTYPE 0 // not used 12 | BEGIN 13 | BLOCK "StringFileInfo" 14 | BEGIN 15 | BLOCK "040904E4" 16 | //language ID = U.S. English, char set = Windows, Multilingual 17 | 18 | BEGIN 19 | VALUE "FileDescription", "zlib data compression and ZIP file I/O library\0" 20 | VALUE "FileVersion", "1.2.11\0" 21 | VALUE "InternalName", "zlib\0" 22 | VALUE "OriginalFilename", "zlibwapi.dll\0" 23 | VALUE "ProductName", "ZLib.DLL\0" 24 | VALUE "Comments","DLL support by Alessandro Iacopetti & Gilles Vollant\0" 25 | VALUE "LegalCopyright", "(C) 1995-2017 Jean-loup Gailly & Mark Adler\0" 26 | END 27 | END 28 | BLOCK "VarFileInfo" 29 | BEGIN 30 | VALUE "Translation", 0x0409, 1252 31 | END 32 | END 33 | -------------------------------------------------------------------------------- /zlib/doc/crc-doc.1.0.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/zlib/doc/crc-doc.1.0.pdf -------------------------------------------------------------------------------- /zlib/examples/README.examples: -------------------------------------------------------------------------------- 1 | This directory contains examples of the use of zlib and other relevant 2 | programs and documentation. 3 | 4 | enough.c 5 | calculation and justification of ENOUGH parameter in inftrees.h 6 | - calculates the maximum table space used in inflate tree 7 | construction over all possible Huffman codes 8 | 9 | fitblk.c 10 | compress just enough input to nearly fill a requested output size 11 | - zlib isn't designed to do this, but fitblk does it anyway 12 | 13 | gun.c 14 | uncompress a gzip file 15 | - illustrates the use of inflateBack() for high speed file-to-file 16 | decompression using call-back functions 17 | - is approximately twice as fast as gzip -d 18 | - also provides Unix uncompress functionality, again twice as fast 19 | 20 | gzappend.c 21 | append to a gzip file 22 | - illustrates the use of the Z_BLOCK flush parameter for inflate() 23 | - illustrates the use of deflatePrime() to start at any bit 24 | 25 | gzjoin.c 26 | join gzip files without recalculating the crc or recompressing 27 | - illustrates the use of the Z_BLOCK flush parameter for inflate() 28 | - illustrates the use of crc32_combine() 29 | 30 | gzlog.c 31 | gzlog.h 32 | efficiently and robustly maintain a message log file in gzip format 33 | - illustrates use of raw deflate, Z_PARTIAL_FLUSH, deflatePrime(), 34 | and deflateSetDictionary() 35 | - illustrates use of a gzip header extra field 36 | 37 | zlib_how.html 38 | painfully comprehensive description of zpipe.c (see below) 39 | - describes in excruciating detail the use of deflate() and inflate() 40 | 41 | zpipe.c 42 | reads and writes zlib streams from stdin to stdout 43 | - illustrates the proper use of deflate() and inflate() 44 | - deeply commented in zlib_how.html (see above) 45 | 46 | zran.c 47 | index a zlib or gzip stream and randomly access it 48 | - illustrates the use of Z_BLOCK, inflatePrime(), and 49 | inflateSetDictionary() to provide random access 50 | -------------------------------------------------------------------------------- /zlib/examples/zran.h: -------------------------------------------------------------------------------- 1 | /* zran.h -- example of zlib/gzip stream indexing and random access 2 | * Copyright (C) 2005, 2012, 2018 Mark Adler 3 | * For conditions of distribution and use, see copyright notice in zlib.h 4 | * Version 1.2 14 Oct 2018 Mark Adler */ 5 | 6 | #include 7 | #include "zlib.h" 8 | 9 | /* Access point list. */ 10 | struct deflate_index { 11 | int have; /* number of list entries */ 12 | int gzip; /* 1 if the index is of a gzip file, 0 if it is of a 13 | zlib stream */ 14 | off_t length; /* total length of uncompressed data */ 15 | void *list; /* allocated list of entries */ 16 | }; 17 | 18 | /* Make one entire pass through a zlib or gzip compressed stream and build an 19 | index, with access points about every span bytes of uncompressed output. 20 | gzip files with multiple members are indexed in their entirety. span should 21 | be chosen to balance the speed of random access against the memory 22 | requirements of the list, about 32K bytes per access point. The return value 23 | is the number of access points on success (>= 1), Z_MEM_ERROR for out of 24 | memory, Z_DATA_ERROR for an error in the input file, or Z_ERRNO for a file 25 | read error. On success, *built points to the resulting index. */ 26 | int deflate_index_build(FILE *in, off_t span, struct deflate_index **built); 27 | 28 | /* Deallocate an index built by deflate_index_build() */ 29 | void deflate_index_free(struct deflate_index *index); 30 | 31 | /* Use the index to read len bytes from offset into buf. Return bytes read or 32 | negative for error (Z_DATA_ERROR or Z_MEM_ERROR). If data is requested past 33 | the end of the uncompressed data, then deflate_index_extract() will return a 34 | value less than len, indicating how much was actually read into buf. This 35 | function should not return a data error unless the file was modified since 36 | the index was generated, since deflate_index_build() validated all of the 37 | input. deflate_index_extract() will return Z_ERRNO if there is an error on 38 | reading or seeking the input file. */ 39 | int deflate_index_extract(FILE *in, struct deflate_index *index, off_t offset, 40 | unsigned char *buf, int len); 41 | -------------------------------------------------------------------------------- /zlib/gzclose.c: -------------------------------------------------------------------------------- 1 | /* gzclose.c -- zlib gzclose() function 2 | * Copyright (C) 2004, 2010 Mark Adler 3 | * For conditions of distribution and use, see copyright notice in zlib.h 4 | */ 5 | 6 | #include "gzguts.h" 7 | 8 | /* gzclose() is in a separate file so that it is linked in only if it is used. 9 | That way the other gzclose functions can be used instead to avoid linking in 10 | unneeded compression or decompression routines. */ 11 | int ZEXPORT gzclose(file) 12 | gzFile file; 13 | { 14 | #ifndef NO_GZCOMPRESS 15 | gz_statep state; 16 | 17 | if (file == NULL) 18 | return Z_STREAM_ERROR; 19 | state = (gz_statep)file; 20 | 21 | return state->mode == GZ_READ ? gzclose_r(file) : gzclose_w(file); 22 | #else 23 | return gzclose_r(file); 24 | #endif 25 | } 26 | -------------------------------------------------------------------------------- /zlib/inffast.h: -------------------------------------------------------------------------------- 1 | /* inffast.h -- header to use inffast.c 2 | * Copyright (C) 1995-2003, 2010 Mark Adler 3 | * For conditions of distribution and use, see copyright notice in zlib.h 4 | */ 5 | 6 | /* WARNING: this file should *not* be used by applications. It is 7 | part of the implementation of the compression library and is 8 | subject to change. Applications should only use zlib.h. 9 | */ 10 | 11 | void ZLIB_INTERNAL inflate_fast OF((z_streamp strm, unsigned start)); 12 | -------------------------------------------------------------------------------- /zlib/msdos/Makefile.emx: -------------------------------------------------------------------------------- 1 | # Makefile for zlib. Modified for emx 0.9c by Chr. Spieler, 6/17/98. 2 | # Copyright (C) 1995-1998 Jean-loup Gailly. 3 | # For conditions of distribution and use, see copyright notice in zlib.h 4 | 5 | # To compile, or to compile and test, type: 6 | # 7 | # make -fmakefile.emx; make test -fmakefile.emx 8 | # 9 | 10 | CC=gcc 11 | 12 | #CFLAGS=-MMD -O 13 | #CFLAGS=-O -DMAX_WBITS=14 -DMAX_MEM_LEVEL=7 14 | #CFLAGS=-MMD -g -DZLIB_DEBUG 15 | CFLAGS=-MMD -O3 $(BUTT) -Wall -Wwrite-strings -Wpointer-arith -Wconversion \ 16 | -Wstrict-prototypes -Wmissing-prototypes 17 | 18 | # If cp.exe is available, replace "copy /Y" with "cp -fp" . 19 | CP=copy /Y 20 | # If gnu install.exe is available, replace $(CP) with ginstall. 21 | INSTALL=$(CP) 22 | # The default value of RM is "rm -f." If "rm.exe" is found, comment out: 23 | RM=del 24 | LDLIBS=-L. -lzlib 25 | LD=$(CC) -s -o 26 | LDSHARED=$(CC) 27 | 28 | INCL=zlib.h zconf.h 29 | LIBS=zlib.a 30 | 31 | AR=ar rcs 32 | 33 | prefix=/usr/local 34 | exec_prefix = $(prefix) 35 | 36 | OBJS = adler32.o compress.o crc32.o gzclose.o gzlib.o gzread.o gzwrite.o \ 37 | uncompr.o deflate.o trees.o zutil.o inflate.o infback.o inftrees.o inffast.o 38 | 39 | TEST_OBJS = example.o minigzip.o 40 | 41 | all: example.exe minigzip.exe 42 | 43 | test: all 44 | ./example 45 | echo hello world | .\minigzip | .\minigzip -d 46 | 47 | %.o : %.c 48 | $(CC) $(CFLAGS) -c $< -o $@ 49 | 50 | zlib.a: $(OBJS) 51 | $(AR) $@ $(OBJS) 52 | 53 | %.exe : %.o $(LIBS) 54 | $(LD) $@ $< $(LDLIBS) 55 | 56 | 57 | .PHONY : clean 58 | 59 | clean: 60 | $(RM) *.d 61 | $(RM) *.o 62 | $(RM) *.exe 63 | $(RM) zlib.a 64 | $(RM) foo.gz 65 | 66 | DEPS := $(wildcard *.d) 67 | ifneq ($(DEPS),) 68 | include $(DEPS) 69 | endif 70 | -------------------------------------------------------------------------------- /zlib/nintendods/README: -------------------------------------------------------------------------------- 1 | This Makefile requires devkitARM (http://www.devkitpro.org/category/devkitarm/) and works inside "contrib/nds". It is based on a devkitARM template. 2 | 3 | Eduardo Costa 4 | January 3, 2009 5 | 6 | -------------------------------------------------------------------------------- /zlib/old/Makefile.emx: -------------------------------------------------------------------------------- 1 | # Makefile for zlib. Modified for emx/rsxnt by Chr. Spieler, 6/16/98. 2 | # Copyright (C) 1995-1998 Jean-loup Gailly. 3 | # For conditions of distribution and use, see copyright notice in zlib.h 4 | 5 | # To compile, or to compile and test, type: 6 | # 7 | # make -fmakefile.emx; make test -fmakefile.emx 8 | # 9 | 10 | CC=gcc -Zwin32 11 | 12 | #CFLAGS=-MMD -O 13 | #CFLAGS=-O -DMAX_WBITS=14 -DMAX_MEM_LEVEL=7 14 | #CFLAGS=-MMD -g -DZLIB_DEBUG 15 | CFLAGS=-MMD -O3 $(BUTT) -Wall -Wwrite-strings -Wpointer-arith -Wconversion \ 16 | -Wstrict-prototypes -Wmissing-prototypes 17 | 18 | # If cp.exe is available, replace "copy /Y" with "cp -fp" . 19 | CP=copy /Y 20 | # If gnu install.exe is available, replace $(CP) with ginstall. 21 | INSTALL=$(CP) 22 | # The default value of RM is "rm -f." If "rm.exe" is found, comment out: 23 | RM=del 24 | LDLIBS=-L. -lzlib 25 | LD=$(CC) -s -o 26 | LDSHARED=$(CC) 27 | 28 | INCL=zlib.h zconf.h 29 | LIBS=zlib.a 30 | 31 | AR=ar rcs 32 | 33 | prefix=/usr/local 34 | exec_prefix = $(prefix) 35 | 36 | OBJS = adler32.o compress.o crc32.o deflate.o gzclose.o gzlib.o gzread.o \ 37 | gzwrite.o infback.o inffast.o inflate.o inftrees.o trees.o uncompr.o zutil.o 38 | 39 | TEST_OBJS = example.o minigzip.o 40 | 41 | all: example.exe minigzip.exe 42 | 43 | test: all 44 | ./example 45 | echo hello world | .\minigzip | .\minigzip -d 46 | 47 | %.o : %.c 48 | $(CC) $(CFLAGS) -c $< -o $@ 49 | 50 | zlib.a: $(OBJS) 51 | $(AR) $@ $(OBJS) 52 | 53 | %.exe : %.o $(LIBS) 54 | $(LD) $@ $< $(LDLIBS) 55 | 56 | 57 | .PHONY : clean 58 | 59 | clean: 60 | $(RM) *.d 61 | $(RM) *.o 62 | $(RM) *.exe 63 | $(RM) zlib.a 64 | $(RM) foo.gz 65 | 66 | DEPS := $(wildcard *.d) 67 | ifneq ($(DEPS),) 68 | include $(DEPS) 69 | endif 70 | -------------------------------------------------------------------------------- /zlib/old/README: -------------------------------------------------------------------------------- 1 | This directory contains files that have not been updated for zlib 1.2.x 2 | 3 | (Volunteers are encouraged to help clean this up. Thanks.) 4 | -------------------------------------------------------------------------------- /zlib/old/descrip.mms: -------------------------------------------------------------------------------- 1 | # descrip.mms: MMS description file for building zlib on VMS 2 | # written by Martin P.J. Zinser 3 | 4 | cc_defs = 5 | c_deb = 6 | 7 | .ifdef __DECC__ 8 | pref = /prefix=all 9 | .endif 10 | 11 | OBJS = adler32.obj, compress.obj, crc32.obj, gzio.obj, uncompr.obj,\ 12 | deflate.obj, trees.obj, zutil.obj, inflate.obj, infblock.obj,\ 13 | inftrees.obj, infcodes.obj, infutil.obj, inffast.obj 14 | 15 | CFLAGS= $(C_DEB) $(CC_DEFS) $(PREF) 16 | 17 | all : example.exe minigzip.exe 18 | @ write sys$output " Example applications available" 19 | libz.olb : libz.olb($(OBJS)) 20 | @ write sys$output " libz available" 21 | 22 | example.exe : example.obj libz.olb 23 | link example,libz.olb/lib 24 | 25 | minigzip.exe : minigzip.obj libz.olb 26 | link minigzip,libz.olb/lib,x11vms:xvmsutils.olb/lib 27 | 28 | clean : 29 | delete *.obj;*,libz.olb;* 30 | 31 | 32 | # Other dependencies. 33 | adler32.obj : zutil.h zlib.h zconf.h 34 | compress.obj : zlib.h zconf.h 35 | crc32.obj : zutil.h zlib.h zconf.h 36 | deflate.obj : deflate.h zutil.h zlib.h zconf.h 37 | example.obj : zlib.h zconf.h 38 | gzio.obj : zutil.h zlib.h zconf.h 39 | infblock.obj : zutil.h zlib.h zconf.h infblock.h inftrees.h infcodes.h infutil.h 40 | infcodes.obj : zutil.h zlib.h zconf.h inftrees.h infutil.h infcodes.h inffast.h 41 | inffast.obj : zutil.h zlib.h zconf.h inftrees.h infutil.h inffast.h 42 | inflate.obj : zutil.h zlib.h zconf.h infblock.h 43 | inftrees.obj : zutil.h zlib.h zconf.h inftrees.h 44 | infutil.obj : zutil.h zlib.h zconf.h inftrees.h infutil.h 45 | minigzip.obj : zlib.h zconf.h 46 | trees.obj : deflate.h zutil.h zlib.h zconf.h 47 | uncompr.obj : zlib.h zconf.h 48 | zutil.obj : zutil.h zlib.h zconf.h 49 | -------------------------------------------------------------------------------- /zlib/old/os2/zlib.def: -------------------------------------------------------------------------------- 1 | ; 2 | ; Slightly modified version of ../nt/zlib.dnt :-) 3 | ; 4 | 5 | LIBRARY Z 6 | DESCRIPTION "Zlib compression library for OS/2" 7 | CODE PRELOAD MOVEABLE DISCARDABLE 8 | DATA PRELOAD MOVEABLE MULTIPLE 9 | 10 | EXPORTS 11 | adler32 12 | compress 13 | crc32 14 | deflate 15 | deflateCopy 16 | deflateEnd 17 | deflateInit2_ 18 | deflateInit_ 19 | deflateParams 20 | deflateReset 21 | deflateSetDictionary 22 | gzclose 23 | gzdopen 24 | gzerror 25 | gzflush 26 | gzopen 27 | gzread 28 | gzwrite 29 | inflate 30 | inflateEnd 31 | inflateInit2_ 32 | inflateInit_ 33 | inflateReset 34 | inflateSetDictionary 35 | inflateSync 36 | uncompress 37 | zlibVersion 38 | gzprintf 39 | gzputc 40 | gzgetc 41 | gzseek 42 | gzrewind 43 | gztell 44 | gzeof 45 | gzsetparams 46 | zError 47 | inflateSyncPoint 48 | get_crc_table 49 | compress2 50 | gzputs 51 | gzgets 52 | -------------------------------------------------------------------------------- /zlib/os400/README400: -------------------------------------------------------------------------------- 1 | ZLIB version 1.2.11 for OS/400 installation instructions 2 | 3 | 1) Download and unpack the zlib tarball to some IFS directory. 4 | (i.e.: /path/to/the/zlib/ifs/source/directory) 5 | 6 | If the installed IFS command suppors gzip format, this is straightforward, 7 | else you have to unpack first to some directory on a system supporting it, 8 | then move the whole directory to the IFS via the network (via SMB or FTP). 9 | 10 | 2) Edit the configuration parameters in the compilation script. 11 | 12 | EDTF STMF('/path/to/the/zlib/ifs/source/directory/os400/make.sh') 13 | 14 | Tune the parameters according to your needs if not matching the defaults. 15 | Save the file and exit after edition. 16 | 17 | 3) Enter qshell, then work in the zlib OS/400 specific directory. 18 | 19 | QSH 20 | cd /path/to/the/zlib/ifs/source/directory/os400 21 | 22 | 4) Compile and install 23 | 24 | sh make.sh 25 | 26 | The script will: 27 | - create the libraries, objects and IFS directories for the zlib environment, 28 | - compile all modules, 29 | - create a service program, 30 | - create a static and a dynamic binding directory, 31 | - install header files for C/C++ and for ILE/RPG, both for compilation in 32 | DB2 and IFS environments. 33 | 34 | That's all. 35 | 36 | 37 | Notes: For OS/400 ILE RPG programmers, a /copy member defining the ZLIB 38 | API prototypes for ILE RPG can be found in ZLIB/H(ZLIB.INC). 39 | In the ILE environment, the same definitions are available from 40 | file zlib.inc located in the same IFS include directory as the 41 | C/C++ header files. 42 | Please read comments in this member for more information. 43 | 44 | Remember that most foreign textual data are ASCII coded: this 45 | implementation does not handle conversion from/to ASCII, so 46 | text data code conversions must be done explicitely. 47 | 48 | Mainly for the reason above, always open zipped files in binary mode. 49 | -------------------------------------------------------------------------------- /zlib/watcom/watcom_f.mak: -------------------------------------------------------------------------------- 1 | # Makefile for zlib 2 | # OpenWatcom flat model 3 | # Last updated: 28-Dec-2005 4 | 5 | # To use, do "wmake -f watcom_f.mak" 6 | 7 | C_SOURCE = adler32.c compress.c crc32.c deflate.c & 8 | gzclose.c gzlib.c gzread.c gzwrite.c & 9 | infback.c inffast.c inflate.c inftrees.c & 10 | trees.c uncompr.c zutil.c 11 | 12 | OBJS = adler32.obj compress.obj crc32.obj deflate.obj & 13 | gzclose.obj gzlib.obj gzread.obj gzwrite.obj & 14 | infback.obj inffast.obj inflate.obj inftrees.obj & 15 | trees.obj uncompr.obj zutil.obj 16 | 17 | CC = wcc386 18 | LINKER = wcl386 19 | CFLAGS = -zq -mf -3r -fp3 -s -bt=dos -oilrtfm -fr=nul -wx 20 | ZLIB_LIB = zlib_f.lib 21 | 22 | .C.OBJ: 23 | $(CC) $(CFLAGS) $[@ 24 | 25 | all: $(ZLIB_LIB) example.exe minigzip.exe 26 | 27 | $(ZLIB_LIB): $(OBJS) 28 | wlib -b -c $(ZLIB_LIB) -+adler32.obj -+compress.obj -+crc32.obj 29 | wlib -b -c $(ZLIB_LIB) -+gzclose.obj -+gzlib.obj -+gzread.obj -+gzwrite.obj 30 | wlib -b -c $(ZLIB_LIB) -+deflate.obj -+infback.obj 31 | wlib -b -c $(ZLIB_LIB) -+inffast.obj -+inflate.obj -+inftrees.obj 32 | wlib -b -c $(ZLIB_LIB) -+trees.obj -+uncompr.obj -+zutil.obj 33 | 34 | example.exe: $(ZLIB_LIB) example.obj 35 | $(LINKER) -ldos32a -fe=example.exe example.obj $(ZLIB_LIB) 36 | 37 | minigzip.exe: $(ZLIB_LIB) minigzip.obj 38 | $(LINKER) -ldos32a -fe=minigzip.exe minigzip.obj $(ZLIB_LIB) 39 | 40 | clean: .SYMBOLIC 41 | del *.obj 42 | del $(ZLIB_LIB) 43 | @echo Cleaning done 44 | -------------------------------------------------------------------------------- /zlib/watcom/watcom_l.mak: -------------------------------------------------------------------------------- 1 | # Makefile for zlib 2 | # OpenWatcom large model 3 | # Last updated: 28-Dec-2005 4 | 5 | # To use, do "wmake -f watcom_l.mak" 6 | 7 | C_SOURCE = adler32.c compress.c crc32.c deflate.c & 8 | gzclose.c gzlib.c gzread.c gzwrite.c & 9 | infback.c inffast.c inflate.c inftrees.c & 10 | trees.c uncompr.c zutil.c 11 | 12 | OBJS = adler32.obj compress.obj crc32.obj deflate.obj & 13 | gzclose.obj gzlib.obj gzread.obj gzwrite.obj & 14 | infback.obj inffast.obj inflate.obj inftrees.obj & 15 | trees.obj uncompr.obj zutil.obj 16 | 17 | CC = wcc 18 | LINKER = wcl 19 | CFLAGS = -zq -ml -s -bt=dos -oilrtfm -fr=nul -wx 20 | ZLIB_LIB = zlib_l.lib 21 | 22 | .C.OBJ: 23 | $(CC) $(CFLAGS) $[@ 24 | 25 | all: $(ZLIB_LIB) example.exe minigzip.exe 26 | 27 | $(ZLIB_LIB): $(OBJS) 28 | wlib -b -c $(ZLIB_LIB) -+adler32.obj -+compress.obj -+crc32.obj 29 | wlib -b -c $(ZLIB_LIB) -+gzclose.obj -+gzlib.obj -+gzread.obj -+gzwrite.obj 30 | wlib -b -c $(ZLIB_LIB) -+deflate.obj -+infback.obj 31 | wlib -b -c $(ZLIB_LIB) -+inffast.obj -+inflate.obj -+inftrees.obj 32 | wlib -b -c $(ZLIB_LIB) -+trees.obj -+uncompr.obj -+zutil.obj 33 | 34 | example.exe: $(ZLIB_LIB) example.obj 35 | $(LINKER) -fe=example.exe example.obj $(ZLIB_LIB) 36 | 37 | minigzip.exe: $(ZLIB_LIB) minigzip.obj 38 | $(LINKER) -fe=minigzip.exe minigzip.obj $(ZLIB_LIB) 39 | 40 | clean: .SYMBOLIC 41 | del *.obj 42 | del $(ZLIB_LIB) 43 | @echo Cleaning done 44 | -------------------------------------------------------------------------------- /zlib/win32/VisualC.txt: -------------------------------------------------------------------------------- 1 | 2 | To build zlib using the Microsoft Visual C++ environment, 3 | use the appropriate project from the contrib/vstudio/ directory. 4 | -------------------------------------------------------------------------------- /zlib/win32/zlib.def: -------------------------------------------------------------------------------- 1 | ; zlib data compression library 2 | EXPORTS 3 | ; basic functions 4 | zlibVersion 5 | deflate 6 | deflateEnd 7 | inflate 8 | inflateEnd 9 | ; advanced functions 10 | deflateSetDictionary 11 | deflateGetDictionary 12 | deflateCopy 13 | deflateReset 14 | deflateParams 15 | deflateTune 16 | deflateBound 17 | deflatePending 18 | deflatePrime 19 | deflateSetHeader 20 | inflateSetDictionary 21 | inflateGetDictionary 22 | inflateSync 23 | inflateCopy 24 | inflateReset 25 | inflateReset2 26 | inflatePrime 27 | inflateMark 28 | inflateGetHeader 29 | inflateBack 30 | inflateBackEnd 31 | zlibCompileFlags 32 | ; utility functions 33 | compress 34 | compress2 35 | compressBound 36 | uncompress 37 | uncompress2 38 | gzopen 39 | gzdopen 40 | gzbuffer 41 | gzsetparams 42 | gzread 43 | gzfread 44 | gzwrite 45 | gzfwrite 46 | gzprintf 47 | gzvprintf 48 | gzputs 49 | gzgets 50 | gzputc 51 | gzgetc 52 | gzungetc 53 | gzflush 54 | gzseek 55 | gzrewind 56 | gztell 57 | gzoffset 58 | gzeof 59 | gzdirect 60 | gzclose 61 | gzclose_r 62 | gzclose_w 63 | gzerror 64 | gzclearerr 65 | ; large file functions 66 | gzopen64 67 | gzseek64 68 | gztell64 69 | gzoffset64 70 | adler32_combine64 71 | crc32_combine64 72 | ; checksum functions 73 | adler32 74 | adler32_z 75 | crc32 76 | crc32_z 77 | adler32_combine 78 | crc32_combine 79 | ; various hacks, don't look :) 80 | deflateInit_ 81 | deflateInit2_ 82 | inflateInit_ 83 | inflateInit2_ 84 | inflateBackInit_ 85 | gzgetc_ 86 | zError 87 | inflateSyncPoint 88 | get_crc_table 89 | inflateUndermine 90 | inflateValidate 91 | inflateCodesUsed 92 | inflateResetKeep 93 | deflateResetKeep 94 | gzopen_w 95 | -------------------------------------------------------------------------------- /zlib/win32/zlib1.rc: -------------------------------------------------------------------------------- 1 | #include 2 | #include "../zlib.h" 3 | 4 | #ifdef GCC_WINDRES 5 | VS_VERSION_INFO VERSIONINFO 6 | #else 7 | VS_VERSION_INFO VERSIONINFO MOVEABLE IMPURE LOADONCALL DISCARDABLE 8 | #endif 9 | FILEVERSION ZLIB_VER_MAJOR,ZLIB_VER_MINOR,ZLIB_VER_REVISION,0 10 | PRODUCTVERSION ZLIB_VER_MAJOR,ZLIB_VER_MINOR,ZLIB_VER_REVISION,0 11 | FILEFLAGSMASK VS_FFI_FILEFLAGSMASK 12 | #ifdef _DEBUG 13 | FILEFLAGS 1 14 | #else 15 | FILEFLAGS 0 16 | #endif 17 | FILEOS VOS__WINDOWS32 18 | FILETYPE VFT_DLL 19 | FILESUBTYPE 0 // not used 20 | BEGIN 21 | BLOCK "StringFileInfo" 22 | BEGIN 23 | BLOCK "040904E4" 24 | //language ID = U.S. English, char set = Windows, Multilingual 25 | BEGIN 26 | VALUE "FileDescription", "zlib data compression library\0" 27 | VALUE "FileVersion", ZLIB_VERSION "\0" 28 | VALUE "InternalName", "zlib1.dll\0" 29 | VALUE "LegalCopyright", "(C) 1995-2017 Jean-loup Gailly & Mark Adler\0" 30 | VALUE "OriginalFilename", "zlib1.dll\0" 31 | VALUE "ProductName", "zlib\0" 32 | VALUE "ProductVersion", ZLIB_VERSION "\0" 33 | VALUE "Comments", "For more information visit http://www.zlib.net/\0" 34 | END 35 | END 36 | BLOCK "VarFileInfo" 37 | BEGIN 38 | VALUE "Translation", 0x0409, 1252 39 | END 40 | END 41 | -------------------------------------------------------------------------------- /zlib/zlib.3.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Qualys/log4jscanwin/eca118375ac31f62a1b0722083d0fef566a9d868/zlib/zlib.3.pdf -------------------------------------------------------------------------------- /zlib/zlib.map: -------------------------------------------------------------------------------- 1 | ZLIB_1.2.0 { 2 | global: 3 | compressBound; 4 | deflateBound; 5 | inflateBack; 6 | inflateBackEnd; 7 | inflateBackInit_; 8 | inflateCopy; 9 | local: 10 | deflate_copyright; 11 | inflate_copyright; 12 | inflate_fast; 13 | inflate_table; 14 | zcalloc; 15 | zcfree; 16 | z_errmsg; 17 | gz_error; 18 | gz_intmax; 19 | _*; 20 | }; 21 | 22 | ZLIB_1.2.0.2 { 23 | gzclearerr; 24 | gzungetc; 25 | zlibCompileFlags; 26 | } ZLIB_1.2.0; 27 | 28 | ZLIB_1.2.0.8 { 29 | deflatePrime; 30 | } ZLIB_1.2.0.2; 31 | 32 | ZLIB_1.2.2 { 33 | adler32_combine; 34 | crc32_combine; 35 | deflateSetHeader; 36 | inflateGetHeader; 37 | } ZLIB_1.2.0.8; 38 | 39 | ZLIB_1.2.2.3 { 40 | deflateTune; 41 | gzdirect; 42 | } ZLIB_1.2.2; 43 | 44 | ZLIB_1.2.2.4 { 45 | inflatePrime; 46 | } ZLIB_1.2.2.3; 47 | 48 | ZLIB_1.2.3.3 { 49 | adler32_combine64; 50 | crc32_combine64; 51 | gzopen64; 52 | gzseek64; 53 | gztell64; 54 | inflateUndermine; 55 | } ZLIB_1.2.2.4; 56 | 57 | ZLIB_1.2.3.4 { 58 | inflateReset2; 59 | inflateMark; 60 | } ZLIB_1.2.3.3; 61 | 62 | ZLIB_1.2.3.5 { 63 | gzbuffer; 64 | gzoffset; 65 | gzoffset64; 66 | gzclose_r; 67 | gzclose_w; 68 | } ZLIB_1.2.3.4; 69 | 70 | ZLIB_1.2.5.1 { 71 | deflatePending; 72 | } ZLIB_1.2.3.5; 73 | 74 | ZLIB_1.2.5.2 { 75 | deflateResetKeep; 76 | gzgetc_; 77 | inflateResetKeep; 78 | } ZLIB_1.2.5.1; 79 | 80 | ZLIB_1.2.7.1 { 81 | inflateGetDictionary; 82 | gzvprintf; 83 | } ZLIB_1.2.5.2; 84 | 85 | ZLIB_1.2.9 { 86 | inflateCodesUsed; 87 | inflateValidate; 88 | uncompress2; 89 | gzfread; 90 | gzfwrite; 91 | deflateGetDictionary; 92 | adler32_z; 93 | crc32_z; 94 | } ZLIB_1.2.7.1; 95 | -------------------------------------------------------------------------------- /zlib/zlib.pc.cmakein: -------------------------------------------------------------------------------- 1 | prefix=@CMAKE_INSTALL_PREFIX@ 2 | exec_prefix=@CMAKE_INSTALL_PREFIX@ 3 | libdir=@INSTALL_LIB_DIR@ 4 | sharedlibdir=@INSTALL_LIB_DIR@ 5 | includedir=@INSTALL_INC_DIR@ 6 | 7 | Name: zlib 8 | Description: zlib compression library 9 | Version: @VERSION@ 10 | 11 | Requires: 12 | Libs: -L${libdir} -L${sharedlibdir} -lz 13 | Cflags: -I${includedir} 14 | -------------------------------------------------------------------------------- /zlib/zlib.pc.in: -------------------------------------------------------------------------------- 1 | prefix=@prefix@ 2 | exec_prefix=@exec_prefix@ 3 | libdir=@libdir@ 4 | sharedlibdir=@sharedlibdir@ 5 | includedir=@includedir@ 6 | 7 | Name: zlib 8 | Description: zlib compression library 9 | Version: @VERSION@ 10 | 11 | Requires: 12 | Libs: -L${libdir} -L${sharedlibdir} -lz 13 | Cflags: -I${includedir} 14 | --------------------------------------------------------------------------------