aboutsummaryrefslogtreecommitdiffstats
path: root/libqpdf/QPDFObjectHandle.cc
AgeCommit message (Collapse)Author
2021-02-22Change from QPDF{Array,Dict}Items to aitems() and ditems()Jay Berkenbilt
2021-02-21QPDFObjectHandle::copyStreamJay Berkenbilt
2021-02-21Enhance QPDFMatrix APIJay Berkenbilt
2021-02-21Fix isPagesObject and isPageObjectJay Berkenbilt
There are lots of things with /Kids that are not pages. Repair the pages tree, then do a reliable check.
2021-02-20Allow --rotate=0Jay Berkenbilt
2021-02-15Add QPDFObjectHandle::parse for strings with contextJay Berkenbilt
2021-02-14Add functional versions of QPDFObjectHandle::replaceStreamDataJay Berkenbilt
Also fix a bug in checking consistency of length for stream data providers. Length should not be checked or recorded if the provider says it failed to generate the data.
2021-02-13QUtil::double_to_string: trim trailing zeroes with option to disableJay Berkenbilt
2021-01-31Improve memory safety of dict/array iteratorsJay Berkenbilt
2021-01-30Add C++ iterator API around array and dictionary objectsJay Berkenbilt
2021-01-29Make QPDFObjectHandle::is* return false for uninitialized objectsJay Berkenbilt
2021-01-17Add warn() to QPDF's public APIJay Berkenbilt
2021-01-02Make more QPDFPageObjectHelper methods work with form XObjectJay Berkenbilt
2021-01-02Bug fix: avoid extraneous pipeline finish calls with multiple contentsJay Berkenbilt
Avoid calling finish() multiple times on the pipeline passed to pipeContentStreams. This commit also fixes a bug in which qpdf was not exiting with the proper exit status if warnings found while splitting pages; this was exposed by a test case that changed.
2021-01-02Add several methods for working with form XObjects (fixes #436)Jay Berkenbilt
Make some more methods in QPDFPageObjectHelper work with form XObjects, provide forEach methods to walk through nested form XObjects, possibly recursively. This should make it easier to work with form XObjects from user code.
2021-01-02QPDFPageObjectHelper: getPageImages -> getImagesJay Berkenbilt
2021-01-02QPDFPageObjectHelper::getPageImages: support form XObjectsJay Berkenbilt
2021-01-01Add QPDFObjectHandle::isFormXObjectJay Berkenbilt
2020-12-28Add QPDFObjectHandle::setFilterOnWriteJay Berkenbilt
2020-12-26Add QPDFObjectHandle::makeDirect(bool allow_streams)Jay Berkenbilt
2020-11-11Treat direct page as runtime rather than logic error (fuzz issue 27393)Jay Berkenbilt
2020-10-23Avoid merging adjacent tokens when concatenating contents (fixes #444)Jay Berkenbilt
2020-04-16Fix warnings reported by -Wshadow=local (fixes #431)Jay Berkenbilt
2020-04-06Allow propagation of errors and retry through StreamDataProviderJay Berkenbilt
StreamDataProvider::provideStreamData now has a rich enough API for it to effectively proxy to pipeStreamData.
2020-04-04Avoid potential segfault in warning methodsJay Berkenbilt
2020-04-03Add QPDFObjectHandle::unsafeShallowCopyJay Berkenbilt
2020-04-03Performance: remove Members indirection for QPDFObjectHandleJay Berkenbilt
2020-03-31Refactor QPDFPageObjectHelper::removeUnreferencedResources()Jay Berkenbilt
Refactor removeUnreferencedResources to prepare for filtering form XObjects.
2019-10-22Parse Contents in signature dictionary without encryptionMasamichi Hosoda
Various PDF digital signing tools do not encrypt /Contents value in signature dictionary. Adobe Acrobat Reader DC can handle a PDF with the /Contents value not encrypted. Write Contents in signature dictionary without encryption Tests ensure that string /Contents are not handled specially when not found in sig dicts.
2019-10-22Add QPDFObject::getParsedOffset()Masamichi Hosoda
2019-09-20Correct reversed Rectangle coordinates (fixes #363)Jay Berkenbilt
2019-09-20Warn for duplicated dictionary keys (fixes #345)Jay Berkenbilt
2019-08-26Fix fuzz issue 16301Jay Berkenbilt
2019-08-23Pass offset and length to ParserCallbacks::handleObjectJay Berkenbilt
2019-08-22Test for direct, rather than resolved nulls in parserJay Berkenbilt
Just because we know an indirect reference is null, doesn't mean we shouldn't keep it indirect.
2019-08-22Protect against coding error of re-entrant parsingJay Berkenbilt
2019-08-20Handle invalid name tokens symmetrically for PDF < 1.2 (fixes #332)Jay Berkenbilt
2019-08-18Shallow copy arrays without removing sparsenessJay Berkenbilt
2019-08-18Use SparseOHArray in parsingJay Berkenbilt
2019-08-18Refactor QPDF_Array in preparation for using SparseOHArrayJay Berkenbilt
2019-08-18SparseOHArrayJay Berkenbilt
2019-06-25Convert some cases of logic_error to runtime_errorJay Berkenbilt
There were a few cases that could be caused by invalid input rather than bugs in the code which were throwing logic_error instead of runtime_error.
2019-06-22Add missing #include <cstring>Jay Berkenbilt
2019-06-21Fix bugs found by fuzz testsJay Berkenbilt
* Several assertions in linearization were not always true; change them to run time errors * Handle a few cases of uninitialized objects * Handle pages with no contents when doing form operations * Handle invalid page tree nodes when traversing pages
2019-06-21Fix sign and conversion warnings (major)Jay Berkenbilt
This makes all integer type conversions that have potential data loss explicit with calls that do range checks and raise an exception. After this commit, qpdf builds with no warnings when -Wsign-conversion -Wconversion is used with gcc or clang or when -W3 -Wd4800 is used with MSVC. This significantly reduces the likelihood of potential crashes from bogus integer values. There are some parts of the code that take int when they should take size_t or an offset. Such places would make qpdf not support files with more than 2^31 of something that usually wouldn't be so large. In the event that such a file shows up and is valid, at least qpdf would raise an error in the right spot so the issue could be legitimately addressed rather than failing in some weird way because of a silent overflow condition.
2019-06-21Change QPDFObjectHandle::pipeStreamData's encode_flags typeJay Berkenbilt
Change from unsigned long to int since we pass enumerated type values to this field.
2019-06-21Add new integer accessors to QPDFObjectHandleJay Berkenbilt
2019-06-15Give up reading objects with too many consecutive errorsJay Berkenbilt
2019-04-21Tighten isPageObject (fixes #310)Jay Berkenbilt
2019-02-01Make inline image token exactly contain the image dataJay Berkenbilt
Do not include the trailing EI, and handle cases where EI is not preceded by a delimiter. Such cases have been seen in the wild.