Hi,
Iam facing a problem regarding the extracting the Extended Key usage
attribute.
My requirement is to know if Extended Key Usage attribute Nid_OCSP_sign is
present.
I tried the following way
X509 *pCert; /* The certificate */
int iVal;
iVal = X509_get_ext_by_NID(pCert, NID_OCSP_sign, -1);
if(iVal >= 0)
printf("Extended Key Usage Attribute NID_OCSP_sign present");
Here Iam getting iVal as -1 indicating that it is not present.
But when I try to print the certificate using X509_print(), I can see this
extension present. Is there anything wrong with the code Iam using ?
I request you to help me in finding the bug.
Awaiting your valuable response...
Regards
Suram
______________________________________________________________________
OpenSSL Project http://www.openssl.org
User Support Mailing List [EMAIL PROTECTED]
Automated List Manager [EMAIL PROTECTED]