20

PDF/A is an ISO-standardized version of the Portable Document Format (PDF) specialized for the digital preservation of electronic documents.

(http://en.wikipedia.org/wiki/PDF/A)

This is great, but are there any free tools for checking the compliance of a single PDF file with any of the PDF/A sub-standards (PDF/A-1, PDF/A-2, PDF/A-3)?

On this (old) website I have found a list of commercially available tools:

  • Acrobat 8 Preflight (developed by callas software)
  • PDF Tools AG: 3-Heights PDF Validator
  • LuraTech: LuraDocument PDF Validator
  • Seal Systems: PDF Checker
  • Intarsys: PDF/A Live!
  • callas: pdfaPilot
  • Apago: PDF Appraiser (sold by Actino)

However, given the importance of this subject, I hope that there is some sort of freely available tool. As a vision, it would be nice if an established open-source PDF toolkit such as poppler supported such an analysis.

  • 1
    Do you want to check whether the document claims to be PDF/A compliant, or do you want to really check whether it is PDF/A compliant? In the first case, you would need a tool to display the metadata, such as Adobe Reader. In the second case, you most likely won't get around a commercial tool (because determining the compliance is not a trivial task). – Max Wyss Mar 23 '15 at 17:21
  • 1
    I want to check for compliance. I am aware that this is not a trivial task. Still, there are many highly complex and high-quality PDF codes out there that are open source (ghostscript and poppler, just to name two), so I think it is not a fair assumption to infer the availability of free or OS software from the complexity of the task :-). But I guess you also have some experience in the field and did an internet search? :) – Jan-Philip Gehrcke Mar 23 '15 at 18:02
  • 3
    There is no such thing as a free PDF/A validator. The European Commission has started a project to create such a validator. You can read more about it here: pdfa.org/news/… As it is not a trivial task, you can imagine that this project is far from completed. I am not aware of any deliverables that are already available. – Bruno Lowagie Mar 24 '15 at 10:46
9

There is JHove. JHove is an open source tool for "validating" PDF/A compliance -- to a certain degree. Many libraries/institutions use it, so from this point of view it is a good answer to my question.

Recently, an article has been published about JHove in the context of modern document storage systems: http://www.pdfa.org/wp-content/uploads/2014/12/PDF_A_JHOVE_Friese_28112014_en1.pdf

To quote from it:

JHOVE is an open source tool for identifying, characterizing and validating common formats such as pdf, tiff, jpeg, aiff and wave. JHOVE includes validation modules for twelve different file formats, including PDF.

and

s many memory institutions primarily use the PDF format and the quality of their files is not always enough of an argument for converting them to PDF/A, I believe that a standard PDF validator remains as necessary as it always has been. In general, JHOVE will continue to be used, despite its limitations, and decisions regarding the archivability of a given file will be dependent on the results JHOVE gives.

JHOVE can still be useful, provided users understand its error reports and are aware of ways to resolve them. So far there is not a great deal of documentation on this issue. Both nestor (AG Format Recognition) and the Open Preservation Foundation aim to do their part to improve this situation soon.

Here is a listing of JHove error message: http://wiki.opf-labs.org/display/KB/JHOVE+Error+Messages

4

PDFBox

You might want to check out the (open source) Apache PDFBox library:

https://pdfbox.apache.org

This includes a PDF/A validator (PDF/A-1b only) which is pretty good. I would recommend to check out PDFBox 2.0.0 (which is currently a release candidate); you can find it here:

https://pdfbox.apache.org/download.cgi#20x

Then download the pre-built Preflight standalone binary (currently preflight-app-2.0.0-RC1.jar).

The following blog post summarises some work we did with Apache Preflight as part of a research project (it contains links to some further resources that you might find useful):

https://www.bitsgalore.org/2015/07/08/why-pdfa-validation-matters-part-2

VeraPDF

On a side note, Bruno Lowagie mentioned a new EU-funded validator. This is now known as VeraPDF; they just (October 2015) published an early release that fully covers PDF/a1b (and partial support of PDF/A-1a, PDF/A-2 & PDF/A-3). More info here:

http://verapdf.org/2015/11/02/complete-pdfa-1b-coverage-now-available-in-0-6-release-of-verapdf/

This is still in its early stages, but they seem to be making quick progress, so definitely something to keep an eye on.

  • +1 for VeraPDF. – jhyot Jan 27 '16 at 20:44
3

You can use veraPDF:

  • open source (veraPDF is dual-licensed under the GNU General Public License v3 or later (GPLv3+) and Mozilla Public License v2 or later (MPLv2+).)
  • Linux, Mac OS X, Microsoft Windows
  • written in Java
  • CLI or GUI

enter image description here

enter image description here

enter image description here

enter image description hereenter image description here

Usage: veraPDF [options] FILES
  Options:
    -x, --extract
       Extracts and reports PDF features.
       Default: false
    --fixmetadata
       Performs metadata fixes.
       Default: false
    -f, --flavour
       Chooses built-in Validation Profile flavour, e.g. '1b'. Alternatively,
       supply '0' or no argument for automatic flavour detection based on a file
's
       metadata.
       Default: 0
       Possible Values: [0, 1a, 1b, 2a, 2b, 2u, 3a, 3b, 3u]
    --format
       Chooses output format.
       Default: mrr
       Possible Values: [xml, mrr, text]
    -h, --help
       Shows this message and exits.
       Default: false
    -l, --list
       Lists built-in Validation Profiles.
       Default: false
    --maxfailures
       Sets maximum amount of failed checks.
       Default: -1
    --maxfailuresdisplayed
       Sets maximum amount of failed checks displayed for each rule.
       Default: 100
    -o, --off
       Turns off PDF/A validation
       Default: false
    --policyfile
       Select a policy schematron or XSL file.
    --prefix
       Sets file name prefix for any fixed files.
       Default: veraFixMd_
    -p, --profile
       Loads a Validation Profile from given path and exits if loading fails.
       This overrides any choice or default implied by the -f / --flavour option
.
    -r, --recurse
       Recurses through directories. Only files with .pdf extensions are
       processed.
       Default: false
    --savefolder
       Sets output directory for any fixed files.
       Default: <empty string>
    --success, --passed
       Logs successful validation checks.
       Default: false
    -v, --verbose
       Adds failed test information to text output.
       Default: false
    --version
       Displays veraPDF version information.
       Default: false

veraPDF is processing STDIN and is expecting an EOF marker.
If this isn't your intention you can terminate by typing an EOF equivalent:
 - Linux or Mac users should type CTRL-D
 - Windows users should type CTRL-Z

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.