-
Simplified and reorganized logic for handling /DecodeParms in streams. Ensured proper initialization and updated filter checks for lossy and specialized compression, improving code clarity and maintainability.
-
Moved the conditional check for /DecodeParms inconsistency into the loop to ensure clearer handling when filters are non-empty. This improves code structure and maintains robustness for edge cases encountered in the wild.
-
Simplified the logic for handling /DecodeParms by using `as_array` and modernized code with `auto` and `emplace_back`. This improves code readability and aligns with modern C++ practices.
-
Removed the unnecessary `filterable` variable and streamlined the logic for handling stream decoding parameters. These changes eliminate redundant checks, improve readability, and ensure clarity in flow control for filter processing.
-
Replaced manual array handling with cleaner iteration using `as_array`. This improves code readability and ensures more robust processing of stream filter arrays.
-
Simplify and reorganize parsing logic to replace explicit filter name collection with direct filter creation. Added validation for unsupported filters, ensuring filters are cleared and errors returned when necessary. This improves code clarity and robustness.
-
Moved stream filter factory logic into `Members::filter_factory` for better encapsulation and maintainability. Removed redundant static filter factory map and improved error handling for invalid stream filter configurations.
-
Moved `expand_filter_name` calls to maintain uniformity and avoid redundant processing in filter handling. This ensures cleaner and more structured code without changing functionality.
-
Moved the filter abbreviation expansion logic from a static map to a new `expand_filter_name` method in `QPDF_Stream::Members`. This simplifies the code, improves maintainability, and consolidates the logic for easier testing and updates.
-
Bump version to 12.3.0 and C++ to C++-20
-
During xref recovery reject /Page objects with multiple errors
-
When validating the pages tree after xref recovery do not tree dictionaries as page objects if more than 2 of the following are true: - the dictionary is direct - the /Type entry is missing or is not /Page - the dictionary does not contain a valid /Parent entry - the dictionary does not contain or inherit a valid /MediaBox - the dictionary does not contain or inherit a /Resources dictionary Such dictionaries are very unlikely to be page objects and trying to process them may cause excessive run time and memory usage.
-
Refine xref table reconstruction
-
Bump version to 12.2.1
-
Fix QPDFFormFieldObjectHelper::getChoices (fixes #1433)
-
During xref table reconstruction ignore uncompressed object entries found in xref streams. The xref table gets populated with entries for the objects actually found in the file. The entries for uncompressed object in xref streams are redundant and potentially incorrect.
-
Add additional sanity check during xref recovery
-
Enhance Windows build for local dev
-
* Remove dependency on `perl`, now only required for maintenance activities and running the test suite. * Exercise building qpdf and running executables from JetBrains CLion without any special additional tooling beyond pre-built external libraries. This replaces the `copy_dlls` with a powershell script, written mostly by ChatGPT, starting from the bash script below. The copy_dlls script had a lot of logic that was no longer needed. ```bash #!/bin/bash set -eo pipefail exe="$1" dest="$2" mingw_bin_dir="$3" if [[ $mingw_bin_dir == "" ]]; then echo >&2 "Usage: $(basename $0) exe dest mingw-bin-dir" exit 2 fi get_dlls() { objdump -p "$1" | grep 'DLL Name:' | awk '{print $NF}' } declare -a dlls dlls=($(get_dlls "$exe")) declare -A seen while [[ ${#dlls[@]} -gt 0 ]]; do i="${dlls[0]}" dlls=("${dlls[@]:1}") if [[ ${seen[$i]} == 1 ]]; then continue fi seen[$i]=1 full="$mingw_bin_dir/$i" if [[ -f "$full" ]]; then cp "$full" $dest/ dlls+=($(get_dlls "$full")) fi done ``` -
Return the display value if the choices entry is an array of strings rather than a single string. Test file is need-appearances.pdf modified to contain one array entry.
-
Do not copy duplicate pages during xref recovery.
-
During xref reconstruction reject unreasonably large objects
-
Reject objects containing arrays or dictionaries with more than 5000 elements. We are by definition dealing with damaged files, and such objects are extremely likely to be invalid or malicious.
-
Don't set tree root /Limits in NNTreeIterator::resetLimits (fixes #1435)
-
Bump version to 12.1.1
-
Fix android build issues (fixes #950)
-
Implement QPDFFormFieldObjectHelper::isChecked
-
Detect shared /Kids arrays in pages tree
-
API was defined, but .cc had no implementation. PDF 2.0 manual is surprisingly unclear as to on/off values, giving /Yes in an example and /Off in descriptive text as "not on".
-
In QPDF::getAllPagesInternal include the /Kids array in the visited set for loop detection. Fixes oss-fuzz issue 411312393
-
Refactor QPDFFormFieldObjectHelper ValueSetter::writeAppearance