Hello everybody,
We are trying to embed ZUGFeRD XML into a PDF/A file to produce a valid ZUGFeRD
e-invoice. To validate the result, we use the Mustang Projekt CLI
(https://www.mustangproject.org/commandline/) using this command:
$ java -jar Mustang-CLI-2.16.2.jar --action validate --no-notice --source
Beleg_245210299_20241201_out.pdf
However, the PDF/A file seems to be invalid, since we receive this error
message:
<?xml version="1.0" encoding="UTF-8"?>
<validation filename="Beleg_245210299_20241201_out.pdf" datetime="2025-02-14
13:16:52">
<pdf>ValidationResult [flavour=3u, totalAssertions=695,
assertions=[TestAssertion [ruleId=RuleId [specification=ISO 19005-3:2012,
clause=6.2.2, testNumber=2], status=failed, message=A content stream that
references other objects, such as images and fonts that are necessary to fully
render or process the stream, shall have an explicitly associated Resources
dictionary as described in ISO 32000-1:2008, 7.8.3, location=Location
[level=CosDocument, context=root/document[0]/pages[0](9 0 obj
PDPage)/contentStream[0](14 0 obj
PDContentStream)/operators[0]/xObject[0]/contentStream[0](17 0 obj
PDContentStream)], locationContext=null, errorMessage=A content stream refers
to resource(s) F1 not defined in an explicitly associated Resources
dictionary]], isCompliant=false]
<info>
<signature>unknown</signature>
<duration unit="ms">652</duration>
</info>
<summary status="invalid"/>
</pdf>
<xml>
<info>
<version>2</version>
<profile>urn:cen.eu:en16931:2017</profile>
<validator version="2.16.2"/>
<rules>
<fired>177</fired>
<failed>0</failed>
</rules>
<duration unit="ms">1270</duration>
</info>
<summary status="valid"/>
</xml>
<summary status="invalid"/>
</validation>
Can anybody point out how to “fix” the resource dictionary for the font using
PDFBox? Are there any examples? Attached is the resulting PDF/A file including
the ZUGFeRD XML which causes the error.
Thank you very much for your help!
Kind regards,
Simon Grossmann
Senior DevOps Engineer & Consultant
PROMATIS software GmbH | Pforzheimer Str. 160 | 76275 Ettlingen, Deutschland
[email protected]<mailto:[email protected]> |
www.promatis.de<https://www.promatis.de> | Tel.: +49 7243 2179 222
[Bild]
Pflichtangaben/Mandatory Disclosure Statement:
https://promatis.com/de/impressum/
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]