Hi, You will have to go through Openssl source code.
Have a look at following files: 1. x509_v3.c (around line 74), You will find the following method: int X509v3_get_ext_by_NID(const STACK_OF(X509_EXTENSION) *x, int nid, int lastpos) { ASN1_OBJECT *obj; obj=OBJ_nid2obj(nid); if (obj == NULL) return(-2); return(X509v3_get_ext_by_OBJ(x,obj,lastpos)); } Hope this helps. On Wed, Jul 25, 2012 at 7:08 AM, Puneet Khunteta <khunteta.pun...@gmail.com>wrote: > Hello, > > I am an user of openssl library. > I am seeking for a method to get the "Extended Key Usage" field from the > X509 certificate . > I will be grateful if you can provide me a sample code in c. > > Thanks > Puneet K. > -- Regards, *Sukalp Bhople.*