PDF validation

Validating PDF locks

PDFs can have locks created by different PDF signature vendors and SWF will, by default, check for known locks in the documents you upload. If a known lock is found, the PDF is refused and the user can not create an errand with that PDF. To continue with that document, remove the lock and upload again.

To decide what message should be shown if a lock is detected, update the following attribute in the PdfValidation.properties file that can be located in you overlay folder:

pdf-validation-locked=Your message here. Include file name with %s

Checking for previous signatures

When a PDF is uploaded to SWF, a check for previously added signatures will also be conducted. If any previously added signatures are found, a warning will be shown to the user. However, the user can still decide to continue with the document since it is only a warning.

The above functionality is enabled by default, but if you wish to disable it, this can be done by adding this to your config file:

"signingOrders": {
	"disableDocumentChecks": true
}

The property to control message in the PdfValidation.properties file:

 pdf-validation-signed=Your message here. Include file name with %s
 pdf-validation-sign-page=This is a message if a sign page has been found which can make it unable to sign with further signatures. Include file name with %s

Validating PDF flavours

The application can be configured to validate PDF/A conformance validation on PDF files, when a signing order is created. The purpose of this function is to warn the user if the uploaded file does not meet the standards required by organisation policy.

Configure the system by indicating what PDF/A flavours are allowed. If NO_FLAVOUR is configured, all PDF/A flavours will be accepted. If no flavour at all is configured, the validation is skipped.

Tag Description
NO_FLAVOUR All PDF/A flavours
PDFA_1_A  1a PDF Version 1 Level A
PDFA_1_B  1a PDF Version 1 Level B
PDFA_2_A 2a PDF Version 2 Level A
PDFA_2_B 2b PDF Version 2 Level B
PDFA_2_U 2u PDF Version 2 Level U
PDFA_3_A 3a PDF Version 3 Level A
PDFA_3_B 3b PDF Version 3 Level B
PDFA_3_U 3u PDF Version 3 Level U
PDFA_4 4 PDF Version 4
PDFA_4_F 4 PDF Version 4 Level F
PDFA_4_E 4 PDF Version 4 Level E
PDFUA_1 ua1 PDF Version 1
WCAG2_1 wcag PDF version 2.1

Example configuration to allow 1a PDF Version 1 Level A and 3a PDF Version 3 Level A

"usePdfAFlavours": ["PDFA_1_A", "PDFA_3_A"]

See reference

To control the message shown to the user, add this property to your PdfValidation.properties file:

pdf-a1a-validation-failed=Error message for if a document did not adhere to the flavours configured. Include file name with %s
pdf-a1a-validation-error=Error message for if a validation could not be conducted. Include file name with %s

The default behavior to warn the user can be changed to reject the invalid PDF and not allow the order to be created at all. This will disable the "Create" button in the final step and also present a red warning text if the PDF standard is not met.

To activate the function, add "rejectInvalidPdfA": true to the signingOrders section of the config.json.