smalot/pdfparser
Pdf parser library. Can read and extract information from pdf file.
v2.12.5
45M downloads/mo
#386 most downloaded on Packagist
smalot/pdfparser
What this package is like to depend on
Last release 4 months ago
17 Apr 2026
Ships fairly regularly
a new release about every 3 months
Rarely documented
notes for 10 of 70 stable releases
Nothing withdrawn
no release was ever pulled
13 years old
74 releases · first in 2013
4 releases in the last 12 months
see the full history below
Release timeline
72 releases · Sep 2013 to Apr 2026Releases
latest 60 of 74-
v2.12.517 Apr 2026Release notes
Open source →What's Changed
- Updated .gitattributes so less files will be distributed when someone downloads the package (by @williamdes in #792)
- For PHP 8.5: Fix chr() deprecation in ASCII85 last-tuple decoding by @Ciki in #793
New Contributors
- @williamdes made their first contribution in #792
- @Ciki made their first contribution in #793
Full Changelog: v2.12.4...v2.12.5
-
v2.12.410 Mar 2026Release notes
Open source →Bugfix release
Refining a change in the latest release:
Ignore Form as well as Image XObjects when assembling the text array for a PDFObject. by @rupertj in #783
When assembling the text array for an object, skip Forms that don't contain any text, instead of all Forms. by @rupertj in #789
Full Changelog: v2.12.3...v2.12.4
-
v2.12.308 Jan 2026Release notes
Open source →Security fix and refinements
Fix for potential Denial of Service vulnerability
Summary: The fix prevents the RawDataParser.php to enter an endless loop under certain circumstances which would lead to memory exhaustion.
Details: When parsing a specifically crafted, malformed PDF file, the low-level RawDataParser enters a state that leads to uncontrolled memory allocation. This continues until the PHP script exhausts its memory_limit and crashes with a fatal error. An attacker can leverage this vulnerability by submitting a small, malicious PDF file to any service using this library, causing the server process to crash and become unavailable.
Thank you Yang LUO (https://github.com/N0zoM1z0) for reporting this and the provided details on the matter. #787 contains further information.
Refinement to improve extracted texts
Ignore Form as well as Image XObjects when assembling the text array for a PDFObject. by @rupertj in #783
Full Changelog: v2.12.2...v2.12.3
-
v2.12.204 Sep 2025 -
v2.12.131 Jul 2025Release notes
Open source →What's Changed
- Stop Image XObjects being included as empty strings in PDFObject::getTextArray(). by @rupertj in #775
Internal
New Contributors
Full Changelog: v2.12.0...v2.12.1
-
v2.12.031 Mar 2025Release notes
Open source →What's Changed
- Fix incorrect parsing of bfrange (#631) by @nsfisis in #763
- More dedicated exceptions were added by @ThomasLandauer in #739 and #745
Internal changes
- chore: update phpunit.xml by @vitormattos in #757
- CI: added PHP 8.4 by @k00ni in #723
- Simplified Coding Style checks: PSR12 replaces Symfony, risky not allowed anymore by @k00ni in #737
- Introducing CONTRIBUTING.md by @k00ni in #744
- pull_request_template.md: Set path to CONTRIBUTING.md by @k00ni in #760
New Contributors
- @ThomasLandauer made their first contribution in #739
- @nsfisis made their first contribution in #763
Full Changelog: v2.11.0...v2.12.0
-
v2.11.016 Aug 2024Release notes
Open source →What's Changed
- Account for inline images in formatContent() by @GreyWyvern in #693
- Fix for two bugs related to Unicode translation support by Font objects by @unixnut in #698
- Fix for adjacent escaped slashes and escaped parentheses in strings by @GreyWyvern in #711
- Merge XMP Metadata if dc:format tag not found by @GreyWyvern in #722
- Implement missing cm command by @DominikDostal in #720
- fix typo and clarify sentence by @bernard-ng in #729
- fix: check that the previous xref is not the just processed xref by @tkegan in #727
Internal changes
New Contributors
- @DominikDostal made their first contribution in #720
- @bernard-ng made their first contribution in #729
- @tkegan made their first contribution in #727
Full Changelog: v.2.10.0...v2.11.0
-
v2.10.029 Apr 2024Release notes
Open source →What's Changed
- Prevent zero from being passed to array_chunk() by @GreyWyvern in #686
- Filter ElementHexa::decode() of non-hex chars by @GreyWyvern in #687
- Account for inaccurate offsets in getXrefData() by @GreyWyvern in #692
- Strengthen check for UTF-8 conformity in formatContent() by @GreyWyvern in #704
Internal changes
- improved documentation: Return page width and height from document by @vitormattos in #700
- Fixed CS issue in PDFObject.php by @k00ni in #695
Full Changelog: v2.9.0...v.2.10.0
-
v2.9.001 Mar 2024Release notes
Open source →What's Changed
- Fix returning empty text in some cases by @xAzoom in #666
- Baseencoding fallback by @GreyWyvern in #669
- Check for binary content in formatContent() before a problematic regexp by @GreyWyvern in #676
- Fixed latest coding style issues and refined a few PHP doc entries to match types by @k00ni in #677
- Fixes Scrutinizer integration (mostly failing tests) by @k00ni in #682
- Fixed a few coding style issues by @k00ni in #670
New Contributors
Full Changelog: v2.8.0...v2.9.0
-
v2.8.001 Dec 2023Nothing published for this version
-
v2.8.0-RC2no date pre-releaseNothing published for this version
-
v2.8.0-RC107 Nov 2023 pre-releaseNothing published for this version
-
v2.7.010 Aug 2023Nothing published for this version
-
v2.5.024 Apr 2023Nothing published for this version
-
v2.4.014 Mar 2023Nothing published for this version
-
v2.3.021 Dec 2022Nothing published for this version
-
v2.2.205 Dec 2022Nothing published for this version
-
v2.2.102 May 2022Nothing published for this version
-
v2.2.004 Apr 2022Nothing published for this version
-
v2.1.003 Feb 2022Nothing published for this version
-
v2.0.122 Nov 2021Nothing published for this version
-
v2.0.018 Oct 2021Nothing published for this version
-
v1.2.0-RC2no date pre-releaseNothing published for this version
-
v1.2.0-RC101 Oct 2021 pre-releaseNothing published for this version
-
v1.1.003 Aug 2021Nothing published for this version
-
v1.0.217 Jun 2021Nothing published for this version
-
v1.0.120 May 2021Nothing published for this version
-
v1.0.026 Apr 2021Release notes
Open source →d4148fd
This commit was created on GitHub.com and signed with GitHub’s verified signature . The key has expired.
GPG key ID: 4AEE18F83AFDEB23 Expired
Verified Learn about vigilant mode .
Highlights
-
Removed support for PHP 5.6 and 7.0, requires at least PHP 7.1 or newer❗
-
extended Config.php with white space characters: it allows developers to override regex for white space recognition ( #411 , thanks @LucianoHanna )
-
Fixed some test-infrastructure related issues ( #412 , #413 , #414 )
-
-
v0.19.013 Apr 2021Nothing published for this version
-
v0.18.225 Feb 2021Nothing published for this version
-
v0.18.105 Jan 2021Nothing published for this version
-
v0.18.030 Dec 2020Nothing published for this version
-
v0.17.129 Oct 2020Nothing published for this version
-
v0.17.012 Oct 2020Nothing published for this version
-
v0.16.231 Aug 2020Nothing published for this version
-
0.16.126 Jun 2020Nothing published for this version
-
v0.16.008 Jun 2020Nothing published for this version
-
v0.15.127 May 2020Nothing published for this version
-
v0.15.021 Apr 2020Nothing published for this version
-
v0.14.023 Jan 2019Nothing published for this version
-
v0.13.311 Jan 2019Nothing published for this version
-
v0.13.223 Jun 2018Nothing published for this version
-
v0.13.122 Jun 2018Nothing published for this version
-
v0.13.022 Jun 2018Nothing published for this version
-
v0.12.016 Mar 2018Nothing published for this version
-
v0.10.003 Jan 2017Nothing published for this version
-
v0.9.2605 Nov 2016Nothing published for this version
-
v0.9.2518 Sep 2015Nothing published for this version
-
v0.9.2426 May 2015Nothing published for this version
-
v0.9.2318 Mar 2015Nothing published for this version
-
v0.9.2221 Jan 2015Nothing published for this version
-
v0.9.2107 Jul 2014Nothing published for this version
-
v0.9.2016 Feb 2014Nothing published for this version
-
v0.9.1929 Jan 2014Nothing published for this version
-
v0.9.1828 Jan 2014Nothing published for this version
-
v0.9.1726 Jan 2014Nothing published for this version
-
v0.9.1625 Jan 2014Nothing published for this version
-
v0.9.1525 Jan 2014Nothing published for this version
-
v0.9.1425 Jan 2014Nothing published for this version
-
v0.9.1325 Jan 2014Nothing published for this version