-
Notifications
You must be signed in to change notification settings - Fork 0
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
ASN1.parse() error #7
Comments
It seems your RSA private key is not valid in PEM format. I suggest checking import 'dart:convert';
print(utf8.decode(chaveBytes)); And it should be like the following in text form:
|
Another information for you. I checked my certificate at: |
Hi, since the stack trace shows the error is from Thanks. |
I'm doing a function that i'm signing a XML.
Before i was testing with the same certificate, and it does successfully.
Now, i'm doing some tests, but unfortunally, when i test with another certificate, it occurs a new error, in ASN1.parse function.
Can anyone help me with this??
That's my CallStack:
#0 ASN1Object.parse (package:ninja_asn1/src/ninja_asn1_base.dart:120:9)
#1 ASN1Sequence.parse (package:ninja_asn1/src/ninja_asn1_base.dart:211:33)
#2 new ASN1Sequence.decode (package:ninja_asn1/src/ninja_asn1_base.dart:180:70)
#3 new RSAPrivateKey.fromASN1 (package:ninja/asymmetric/rsa/rsa.dart:271:32)
#4 new RSAPrivateKey.fromPEM (package:ninja/asymmetric/rsa/rsa.dart:325:26)
#5 RSASHA1.getSignature (package:xml_crypto/src/signed_xml.dart:980:31)
#6 SignedXml._calculateSignatureValue (package:xml_crypto/src/signed_xml.dart:291:16)
#7 SignedXml.computeSignature (package:xml_crypto/src/signed_xml.dart:659:7)
#8 FNfeNfceGerais.assinarDocumento (package:vip12/funcoes/nfeNfce/fNfeNfceGerais.dart:67:15)
e: UnimplementedError
message: null
That's urgent, please, someone help me, i need answers!
The text was updated successfully, but these errors were encountered: