vbuch / node-signpdf

Simple signing of PDFs in node.
MIT License
696 stars 175 forks source link

AdES digital signature #71

Closed ioprea closed 3 years ago

ioprea commented 4 years ago

Describe the bug and the expected behaviour I have been trying out the lib, but I am not sure whether it generates PAdES compliant signatures. I have tried validating it here https://ec.europa.eu/cefdigital/DSS/webapp-demo/validation which seems like the only tool for PAdES validation but I have been getting 'The signature/seal is not a valid AdES digital signature!'. I don't know if I am doing something wrong or if that's the expected behaviour.

Is it a bug in signing or in the helpers? Haven't seen anything similar

To Reproduce Sign a document using the library, I have tested it on a dummy.pdf nothing special with different certificates. Just upload the original and signed file to the validation platform specified above. It offer detailed information regarding the signature

Screenshot 2020-04-27 at 12 23 20
vbuch commented 4 years ago

True. We have not created AdES with node-signpdf but rather only an ES. AFAIK the only thing you need more is a trusted issuer. But I havent gone through the details of that. Some code changes may be needed if we want to produce PAdES. Someone needs to research this. I think #70 is about the same issue.

vbuch commented 4 years ago

BTW Reading through the spec, I think the signed documents produced here are PAdES Basic (section 5.1)

ioprea commented 4 years ago

Indeed it is PAdES Basic, over the next few weeks I will be looking over generating an AdES signature, it seems like there is only a Java lib that does it, will try to implement it in nodejs.

kas84 commented 4 years ago

@ioprea did you manage to do it? What’s the java library that does it?

agustif commented 4 years ago

Interested on seeing this through, maybe I can contribute? Let me know where you left it of @ioprea if you wish !

HamidOsouli-zz commented 3 years ago

Same issue here.

stale[bot] commented 3 years ago

This issue has been automatically marked as stale because it has not had activity in the past 90 days. It will be closed if no further activity occurs. Thank you for your contributions.

sanchezandoni commented 3 years ago

Hi! Any news on this issue?