2
1
mirror of https://github.com/qpdf/qpdf.git synced 2025-02-12 16:48:25 +00:00

3728 Commits

Author SHA1 Message Date
m-holger
642a1110ed Code tidy QPDFWriter::willFilterStream 2025-01-31 15:34:02 +00:00
Jay Berkenbilt
018cf0eb54
Merge pull request #1284 from cbwoyak/zlib_find_library
Use NAMES keyword in find_library call
2025-01-29 07:50:22 -05:00
m-holger
712a471184
Merge pull request #1116 from m-holger/ca
Add copy annotation test
2025-01-28 23:20:35 +00:00
m-holger
73af7567d1 Add copy annotation test
Test fixing /P entry.
2025-01-28 16:26:21 +00:00
m-holger
bde5a446ab
Merge pull request #1307 from m-holger/pages
Fix QPDF::getAllPagesInternal warning
2025-01-28 15:59:52 +00:00
m-holger
b079859c4c
Merge pull request #1306 from m-holger/foreign
Fix QPDF::copyForeignObject warning
2025-01-28 15:58:27 +00:00
Jay Berkenbilt
622592fed2
Merge pull request #1339 from jberkenbilt/stefre-doc-patches
Stefre doc patches
2025-01-28 07:16:41 -05:00
Jay Berkenbilt
e571478901 Run generate_auto_jobs with doc typo fixes 2025-01-28 06:52:51 -05:00
Jay Berkenbilt
c5febb2cd6 Merge branch 'patch-1' of https://github.com/StefRe/qpdf into main 2025-01-28 06:52:08 -05:00
m-holger
cc95f4731e Fix QPDF::copyForeignObject warning
Provide correct obj_gen and offset.
2025-01-28 11:01:18 +00:00
m-holger
b7bf9f3d3c Fix QPDF::getAllPagesInternal warning
Provide correct obj_gen.
2025-01-28 10:15:15 +00:00
m-holger
ef891178f8
Merge pull request #1338 from m-holger/qpdf-11-revert
Exclude #1272, #1289, #1297 and #1301 from qpdf 11.10
2025-01-27 22:34:59 +00:00
Jay Berkenbilt
740dd509b0 Fix yaml format in .readthedocs.yaml 2025-01-27 18:31:12 +00:00
m-holger
0d5c57c151 Revert "Merge pull request #1272 from m-holger/xref_table"
This reverts commit ff2a78f579ebdd06b417e34260a17dba06e71137, reversing
changes made to 8f54319f7a6514110f4b05cbbf1cb1c9fc8cb6a0.
2025-01-16 16:40:08 +00:00
m-holger
f1800410b6 Revert "Merge pull request #1289 from m-holger/fuzz"
This reverts commit 0e92cf6bf399249c603c3d0212e898fd29e71fcd, reversing
changes made to 7d34b89a69e8e89c098dd373442f7df809c28eff.
2025-01-16 16:36:48 +00:00
m-holger
efb2e8f613 Revert "Merge pull request #1297 from m-holger/qpdf_objects"
This reverts commit c648b9a018105a3c30b3e7f3c5f8a058d3ddd92c, reversing
changes made to 12b67a3227df6b6df3a4f5f098e11cce173ff7d5.
2025-01-16 16:15:11 +00:00
m-holger
4bf09ff1cd Revert "Merge pull request #1301 from m-holger/typo"
This reverts commit 54cf0e519c49e3fb44c7ca1de95a1fffbafc211c, reversing
changes made to c648b9a018105a3c30b3e7f3c5f8a058d3ddd92c.
2025-01-16 16:13:27 +00:00
Jay Berkenbilt
531f6877a8 Tweak test files to work around fixed ghostscript bug
Ghostscript 10.0.2 failed to handle the files changed in this commit,
but ghostscript 10.0.4 handles them fine as do earlier versions. These
files all have hybird xref in the form of a file with an xref table
appended with a section that has an xref stream. They all have
/PageLabels pointing to 107 0 R in the original file, with 107 higher
than the highest object. The spec says that this should be treated as
null, which results in /PageLabels null, which results in ghostscript
errors in that version. While ghostscript 10.0.2 may be handling the
file incorrectly, the file does something that's not really kosher,
and it's easier to fix the files, which had not been changed since the
very first open source release of qpdf, than to try to work around the
issue.

This was discovered with the GitHub actions runner was bumped to
Ubuntu 24.04, which contains the buggy version of ghostscript. I was
not able to find a specific ghostscript issue that addressed this, but
the problem went away in either 10.0.3 or 10.0.4.

Commenting out /PageLabels without changing offsets was a pragmatic
move to avoid having to regenerate the xref tables manually. I just
had to manually edit the binary xref stream to change the offset of
one item (the new object 1), which I put at the end to avoid breaking
other things.
2025-01-05 17:29:03 -05:00
Jay Berkenbilt
ef9616775e Fix headers for rijndael.h 2024-12-14 11:02:33 -05:00
Jay Berkenbilt
0e65d9c246 Fix shell globbing for mingw
Why did this ever work? Hard to say...perhaps a library we linked
against was setting `int _dowildcard = -1;` somewhere and no longer
is. Apparently linking with CRT_glob.o has been the way to do this for
a very long time, and we've just been lucky that it worked all this
time.
2024-12-14 11:02:33 -05:00
Steffen Rehberg
c6c2b63086
DOC: Fix some typos in cli.rst 2024-11-19 17:10:32 +01:00
m-holger
3ea83e9993
Merge pull request #1308 from m-holger/fuzz
Validate key length in Pl_AES_PDF constructor
2024-11-08 22:29:36 +00:00
m-holger
64e9839710 Validate key length in Pl_AES_PDF constructor 2024-11-08 17:35:28 +00:00
m-holger
54cf0e519c
Merge pull request #1301 from m-holger/typo
Fix gratuitous calls to bad_subsections in Xref_table::subsections
2024-10-29 00:12:30 +00:00
m-holger
1eb5df92f4 Fix gratuitous calls to bad_subsections in Xref_table::subsections 2024-10-25 11:16:45 +01:00
m-holger
c648b9a018
Merge pull request #1297 from m-holger/qpdf_objects
Add inner class QPDF::Objects to encapsulate reading and managing of objects
2024-10-17 14:03:41 +01:00
m-holger
acc57ca090 Add QPDF::Objects destructor
Also, make obj_cache private and rename to table.
2024-10-09 12:02:34 +01:00
m-holger
336d783325 Move calculations from QPDF::getObjectCount to Objects::next_id 2024-10-09 11:55:29 +01:00
m-holger
113ea4e7ae Add new method Objects::all 2024-10-09 11:39:44 +01:00
m-holger
9e03dc54cc Add new method Objects::swap 2024-10-09 11:39:17 +01:00
m-holger
83fc18af09 Add new method Objects::replace 2024-10-09 11:27:40 +01:00
m-holger
6c9903062f Add new method Objects::get 2024-10-09 11:27:28 +01:00
m-holger
83443c116d Make ObjCache of inner class of QPDF::Objects and rename to Entry 2024-10-09 11:09:18 +01:00
m-holger
b5a5780019 Make Xref_table an inner class of QPDF::Objects 2024-10-09 09:53:57 +01:00
m-holger
a3f693c8f9 Move private methods in QPDF_objects to QPDF::Objects 2024-10-09 08:58:57 +01:00
m-holger
2015f71c7d Add new inner class to QPDF::Objects 2024-10-07 14:18:59 +01:00
m-holger
83897e8789 Split QPDF.cc into QPDF.cc and QPDF_objects.cc
Move methods responsible for loading or keeping track of objects to
QPDF_objects.cc.
2024-10-07 14:10:18 +01:00
m-holger
9f0cc086b1 Copy QPDF.cc to new QPDF_objects 2024-10-06 17:45:29 +01:00
m-holger
12b67a3227
Merge pull request #1282 from m-holger/next
Add new protected inline method Pipeline::next
2024-10-06 15:59:42 +01:00
m-holger
c916dcf973 Add new protected inline method Pipeline::next
Also, tidy pipeline constructors and make subclasses final where possible.
2024-10-06 15:10:13 +01:00
m-holger
2cb2412fbf
Merge pull request #1294 from m-holger/fuzz
Add additional xref and object stream sanity checks
2024-09-28 01:02:32 +01:00
m-holger
c2ff89ae11 Add additional fuzz test cases 2024-09-28 00:36:32 +01:00
m-holger
192525226f Validate that offsets in object streams are strictly increasing 2024-09-28 00:28:17 +01:00
m-holger
1b6a504d42 Add sanity check for xref stream /Size entry 2024-09-28 00:25:31 +01:00
m-holger
529501aa41
Merge pull request #1293 from m-holger/pr1287
Tweak #1287 comments
2024-09-27 12:26:30 +01:00
m-holger
43a88e1d28 Tweak #1287 comments 2024-09-27 11:58:46 +01:00
m-holger
638bf5f9ae
Merge pull request #1287 from mslichao/mslichao/capifreebuf
Add C API qpdf_oh_free_buffer to release memory allocated by stream data functions
2024-09-27 11:34:54 +01:00
m-holger
1796365713
Merge branch 'main' into mslichao/capifreebuf 2024-09-27 11:31:55 +01:00
m-holger
50d385c858
Merge pull request #1274 from m-holger/meta
Add new commands --remove-metadata and --remove-info
2024-09-27 11:26:34 +01:00
m-holger
0198ff7e48
Merge pull request #1291 from m-holger/fuzz
In QPDFWordTokenFinder::check limit the token length
2024-09-24 01:55:36 +01:00