Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

I need put text or image in my signature without change the file structure. If I change, all my oldest signatures will be invalid. It's possible?? #199

Closed
taotaow2n opened this issue Oct 27, 2023 · 8 comments

Comments

@taotaow2n
Copy link

taotaow2n commented Oct 27, 2023

Describe the bug and the expected behaviour
I need put text or image in my signature without change the file structure. If I change, all my oldest signatures will be invalid. It's possible??,thank you very much

@vbuch
Copy link
Owner

vbuch commented Oct 27, 2023

The most important thing a signature states is that the content was not altered since the application of the signature. If you alter any bit of the file the signature will be invalid and editors will say something like "File was modified after it was signed".

@vbuch vbuch added the question label Oct 27, 2023
@taotaow2n
Copy link
Author

taotaow2n commented Oct 29, 2023

hi,https://github.com/RippleRurigaki/sPDF.js ,this project can do it ,Support for incremental updates,Add a new signature without modifying the PDF document. Existing content, including signatures, will be maintained.
Can it be integrated into 'node-signpdf'? I think it's cool @vbuch

@vbuch
Copy link
Owner

vbuch commented Oct 30, 2023

@taotaow2n incremental updates will allow you to add content on top of the previous revisions of the file, yes. But that is still a change AFTER the signature so the viewer should warn you that the file was altered after it was signed. You can then sign it additionally (again with incremental updates). The new signature will be valid, the previous one will still say "altered after me".

Maybe see https://github.com/vbuch/node-signpdf/blob/develop/packages/signpdf/src/signpdf.test.js#L211

@taotaow2n
Copy link
Author

@vbuch Thank you for your reply. I tried what you said and it worked. But how can I put text or image in my signature? Looking forward to your reply, thank you

@vbuch
Copy link
Owner

vbuch commented Nov 2, 2023

@taotaow2n if I have some time today and will try to prepare an example of the above.

@vbuch
Copy link
Owner

vbuch commented Nov 3, 2023

@taotaow2n I couldn't finish it. Hope I'll find the time for that today. But here is the general idea: develop...feature/with-visible-widget#diff-a728ac89daf3c377e68e4e25a1ab6cc17f921cfcba4499cad818c546c1975da2R79
Note that this requires a change in the placeholder helprs so that they can accept the widgetRect prop.

@vbuch vbuch added the visual label Nov 3, 2023
@vbuch
Copy link
Owner

vbuch commented Nov 3, 2023

PR: #200

@vbuch
Copy link
Owner

vbuch commented Nov 24, 2023

@vbuch vbuch closed this as completed Nov 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants