s1seven / schema-tools

Tools to create, validate and render certificates using Material Identity JSON schemas
https://materialidentity.org/
Apache License 2.0
1 stars 1 forks source link

feat: make the PDF read only #251

Closed stiebitzhofer closed 7 months ago

stiebitzhofer commented 7 months ago

Description

What keywords did you search in schema-tools issues before filing this one ?

Is this a BUG REPORT or FEATURE REQUEST ? FEATURE

What you expected to happen: The attribute permissions.modifying shall be set to false. The reasoning is that PDF Readers warn the user that the document will lose PDF/A compliance in case of modifications.

Bildschirmfoto 2024-03-02 um 12 43 10

Outline:

const docDefinition = {
  permissions: {
    modifying: false
  }
}
christophbuehler commented 7 months ago

The feature to add permissions in pdf-lib is on the roadmap. It may be possible to achieve this already using low-level apis, but I suggest postponing this until it is officially supported.

stiebitzhofer commented 7 months ago

Ok