Search code examples
c#x509certificate2pkcs#12

C#. p12 contains two certificates. How to get them?


I have a p12 certificate that contains several certificates. How to get a collection of these certificates?

Code:

new X509Certificate2(bytes, pass);

returns last. Thx!


Solution

  • This is a duplicate of Importing all certificates contained in a .p12 file

    You might want to consider searching a little harder ;-)