POST request to search certificate #405
Unanswered
Dominik26-1
asked this question in
Q&A
Replies: 1 comment
-
What do you get back? Write it down to a file and inspect it. Perhaps it's base64 encoded? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi all,
I am trying to retrieve newly created certificate according to subject SN.
I am using API endpoint ejbca-rest-api/v1/certificate/search but response I got is in DER format with string value.
I need to convert and retrieve original information about subject, but I cannot use x509.load_der_x509_certificate(cert_der, default_backend()) python method, because DER format string throwing error :
Traceback (most recent call last):
File "c:\Users\domin\Documents\school\DP\Program\generate_cert.py", line 155, in
cert = x509.load_der_x509_certificate(cert_der, default_backend())
File "C:\Users\domin\AppData\Local\Programs\Python\Python310\lib\site-packages\cryptography\x509\base.py", line 594, in load_der_x509_certificate
return rust_x509.load_der_x509_certificate(data)
ValueError: error parsing asn1 value: ParseError { kind: UnexpectedTag { actual: Tag { value: 13, constructed: false, class: Application } } }
Thanks for advice, how can I get certificate values from response certificate DER string?
Beta Was this translation helpful? Give feedback.
All reactions