Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. C#
  4. Add extension to X509Certificate

Add extension to X509Certificate

Scheduled Pinned Locked Moved C#
helpcryptographydebuggingquestion
1 Posts 1 Posters 2 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • L Offline
    L Offline
    Liborac_
    wrote on last edited by
    #1

    Hi, I need to add x509Extension to x509Certificate2 class but i dont know how (i read somewhere its not possible so im not sure about it). Lets imagine this code :

    X509Certificate2 cert;
    X509Extension ext;

    cert.Extensions.Add (ext); // since here its ok i can see the collection in debug mode and it is present.

    byte [] b = cert.export (X509contentType.Cert);
    X509Certificate2 cert2 = new X509Certificate2 (b);

    // Here comes the problem ... there is no my extension in the cert2 collection. Btw: I create it by calling c function CertCreateSelfSignCertficate. Is there any way to add my extension to created certificate or the only way to add it is in the creation time? i rack my brain with this issue for several days so any help would be very appreciated. thanks Libor

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups