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

Signature is invalid #17

Open
tomasantunes opened this issue Sep 5, 2022 · 0 comments
Open

Signature is invalid #17

tomasantunes opened this issue Sep 5, 2022 · 0 comments

Comments

@tomasantunes
Copy link

When I sign the PDF with an external signature I get the following error when reading it with Acrobat: "There are errors in the formatting or information contained in this signature."

Here is the code I used:

    var dt = new Date().getTime();
    var filename = __dirname + "\\output_pdf\\" + "fatura" + dt + ".pdf";

    var dt2 = new Date().toISOString();

    const outputPath = await addSignaturePlaceholderToPdf({
        file: pdfFile,
        out: filename,
        estimatedsize: 30000,
        certlevel: CertificationLevels.NotCertified,
        reason: 'I want to sign the document',
        location: 'Porto',
        contact: 'JOÃO SILVA',
        date: dt2,
      });
      

      var dt3 = new Date().getTime();
      var filename2 = __dirname + "\\output_pdf\\" + "fatura" + dt + "b.pdf";
      
      const outputPath2 = await signPdf({
        file: filename,
        out: filename2,
        signature: signature,
      });
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant