You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Adding key from X509 certificate using xmlSecOpenSSLAppKeyLoad and xmlSecOpenSSLAppKeyLoadMemory does not add the certificate to the key's "keyCert" member
#545
Closed
lsh123 opened this issue
Feb 23, 2023
Discussed in
#535
· 1 comment
Originally posted by fnyberg-vcc February 22, 2023
Hi
I have a X509 certificate containing a key I want to be used to verify an XML. So after looking at the documentation it seems like I should add the key from the certificate to the key store using the code:
I get NULL back. Upon a small investigation, I found that xmlSecCryptoAppKeyLoad and xmlSecOpenSSLAppKeyLoadMemory adds the cert to the stack ctx->certsList but not as ctx->keyCert. From my understanding, a key retrieved from a cert should always have that cert added as ctx->keyCert. Am I missing something or misunderstanding the process? Although I found a workaround using xmlSecOpenSSLKeyDataX509AdoptKeyCert, I would like to know if this behavior is intended.
The text was updated successfully, but these errors were encountered:
Discussed in #535
Originally posted by fnyberg-vcc February 22, 2023
Hi
I have a X509 certificate containing a key I want to be used to verify an XML. So after looking at the documentation it seems like I should add the key from the certificate to the key store using the code:
This adds the key from the cert fine as the XML signature gets verified using the added key, but when I try to retrieve the certificate using:
I get NULL back. Upon a small investigation, I found that
xmlSecCryptoAppKeyLoad
andxmlSecOpenSSLAppKeyLoadMemory
adds the cert to the stackctx->certsList
but not asctx->keyCert
. From my understanding, a key retrieved from a cert should always have that cert added asctx->keyCert
. Am I missing something or misunderstanding the process? Although I found a workaround usingxmlSecOpenSSLKeyDataX509AdoptKeyCert
, I would like to know if this behavior is intended.The text was updated successfully, but these errors were encountered: