Fix writeXrefTable to handle PDFs with multiple revisions

- Refactor xref table writing logic to correctly parse existing entries
- Add support for variable first object ID in xref table
- Implement dynamic calculation of new xref entries
- Improve error handling and reporting

This change resolves issue #4 with malformed xref tables when signing PDFs
that have undergone multiple revisions.
This commit is contained in:
Paul van Brouwershaven
2024-07-07 16:31:43 +02:00
committed by Paul van Brouwershaven
parent e6e59033a0
commit a0da9873d4
2 changed files with 49 additions and 36 deletions

BIN
testfiles/testfile16.pdf Normal file

Binary file not shown.