none
Reading OID fields from a x509 certificate RRS feed

  • Question

  • Hi,

    I'm trying to read the value of an OID field (2.16.76.1.3.3) from a X509 digital certificate, but seems that it is impossible to do so using the X509Certificate2 class.

    I have a web application available under a SSL connection, that request for the client certificate:

    HttpClientCertificate cert = Request.ClientCertificate;

    After this, I instantiate a X509Certificate2 object:

    X509Certificate2 x509 = new X509Certificate2(cert.Certificate);

    I could do this two steps correctly, but I can't read the OID=2.16.76.1.3.3 field neither from cert nor from x509 objects. The referenced OID is a "Subject Alternative Name - OtherName" field. I also have tried to use the Extensions property (with the X509Extension class), but there are only some extensions into this property, without the one I am interested for.

    Is it possible to use other class to solve this problem? Maybe CAPICOM!? It would be nice to provide the OID to and method and get their value directly. Why it is not implemented into X509Certificate2 class?

    I would be grateful for any help.

    Thanks!
    Tuesday, July 8, 2008 10:05 PM