Added ZUGFeRD.PDF-csharp to list of valid PDF creators

This commit is contained in:
Stephan
2025-04-16 20:07:36 +02:00
committed by GitHub
parent 17bc5c483f
commit fe6c64a1a0

View File

@@ -267,7 +267,8 @@ public class PDFValidator extends Validator {
final byte[] pdfMachineSignature = "pdfMachine from Broadgun Software".getBytes(StandardCharsets.UTF_8);
final byte[] ghostscriptSignature = "%%Invocation:".getBytes(StandardCharsets.UTF_8);
final byte[] cibpdfbrewerSignature = "CIB pdf brewer".getBytes(StandardCharsets.UTF_8);
final byte[] lexofficeSignature = "lexoffice".getBytes(StandardCharsets.UTF_8);
final byte[] lexofficeSignature = "lexoffice".getBytes(StandardCharsets.UTF_8);
final byte[] s2IndustriesSignature = "s2industries.ZUGFeRD.PDF".getBytes(StandardCharsets.UTF_8); // https://github.com/stephanstapel/ZUGFeRD-csharp
if (ByteArraySearcher.contains(fileContents, symtraxSignature)) {
Signature = "Symtrax";
@@ -287,6 +288,8 @@ public class PDFValidator extends Validator {
Signature = "CIB pdf brewer";
} else if (ByteArraySearcher.contains(fileContents, lexofficeSignature)) {
Signature = "Lexware office";
} else if (ByteArraySearcher.contains(fileContents, s2IndustriesSignature)) {
Signature = "ZUGFeRD.PDF-csharp";
}
context.setSignature(Signature);