rsatrio / pdf-signature-check Goto Github PK
View Code? Open in Web Editor NEWSimple Checking of PDF Digital Signature CLI
License: MIT License
Simple Checking of PDF Digital Signature CLI
License: MIT License
Hello!
Abobe pdf reader verify signature successful, but with you utility with jdk8 i got error:
2022-08-16 14:13:32,163 INFO com.rizky.pdf.cli.CheckPdfSignature [CheckPdfSignature] Signature null Filter:Adobe.PPKLite
2022-08-16 14:13:32,166 INFO com.rizky.pdf.cli.CheckPdfSignature [CheckPdfSignature] Signature null SubFilter:ETSI.CAdES.detached
2022-08-16 14:13:32,166 INFO com.rizky.pdf.cli.CheckPdfSignature [CheckPdfSignature] Signature null ContactInfo:John Doe
2022-08-16 14:13:32,166 INFO com.rizky.pdf.cli.CheckPdfSignature [CheckPdfSignature] Signature null Reason:My organization
2022-08-16 14:13:32,222 INFO com.rizky.pdf.cli.CheckPdfSignature [CheckPdfSignature] Digest Algorithm used:2.16.840.1.101.3.4.2.1
2022-08-16 14:13:32,222 INFO com.rizky.pdf.cli.CheckPdfSignature [CheckPdfSignature] Signature ID 3db6c5776c110dc461090d962382d96d contains timestamp
2022-08-16 14:13:32,258 ERROR com.rizky.pdf.cli.CheckPdfSignature [CheckPdfSignature] Error processing Signature
java.security.spec.InvalidKeySpecException: java.security.InvalidKeyException: Invalid RSA public key
at java.base/sun.security.rsa.RSAKeyFactory.engineGeneratePublic(RSAKeyFactory.java:239)
at java.base/java.security.KeyFactory.generatePublic(KeyFactory.java:352)
at com.rizky.pdf.cli.CheckPdfSignature.processSignature(CheckPdfSignature.java:149)
at com.rizky.pdf.cli.CheckPdfSignature.lambda$call$0(CheckPdfSignature.java:66)
at java.base/java.util.ArrayList.forEach(ArrayList.java:1540)
at com.rizky.pdf.cli.CheckPdfSignature.call(CheckPdfSignature.java:64)
at com.rizky.pdf.cli.CheckPdfSignature.call(CheckPdfSignature.java:32)
at picocli.CommandLine.executeUserObject(CommandLine.java:1953)
at picocli.CommandLine.access$1300(CommandLine.java:145)
at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2352)
at picocli.CommandLine$RunLast.handle(CommandLine.java:2346)
at picocli.CommandLine$RunLast.handle(CommandLine.java:2311)
at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2179)
at picocli.CommandLine.execute(CommandLine.java:2078)
at com.rizky.pdf.cli.MainCli.main(MainCli.java:17)
Caused by: java.security.InvalidKeyException: Invalid RSA public key
at java.base/sun.security.rsa.RSAPublicKeyImpl.parseKeyBits(RSAPublicKeyImpl.java:189)
at java.base/sun.security.x509.X509Key.decode(X509Key.java:390)
at java.base/sun.security.x509.X509Key.decode(X509Key.java:401)
at java.base/sun.security.rsa.RSAPublicKeyImpl.<init>(RSAPublicKeyImpl.java:122)
at java.base/sun.security.rsa.RSAKeyFactory.generatePublic(RSAKeyFactory.java:330)
at java.base/sun.security.rsa.RSAKeyFactory.engineGeneratePublic(RSAKeyFactory.java:235)
... 14 common frames omitted
Caused by: java.io.IOException: DerInputStream.getLength(): lengthTag=79, too big.
at java.base/sun.security.util.DerInputStream.getLength(DerInputStream.java:606)
at java.base/sun.security.util.DerValue.<init>(DerValue.java:257)
at java.base/sun.security.util.DerInputStream.getDerValue(DerInputStream.java:457)
at java.base/sun.security.rsa.RSAPublicKeyImpl.parseKeyBits(RSAPublicKeyImpl.java:178)
... 19 common frames omitted
2022-08-16 14:13:32,260 INFO com.rizky.pdf.cli.MainCli [MainCli] Elapsed Time: 351 ms
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.