Click here to Skip to main content
14,428,340 members
Rate this:
Please Sign up or sign in to vote.
I generated csr_code and csr_key using csr api call but now i want to generate certificate using csr_code. i was try many way but i didn't get success to generate certificate.

What I have tried:

var pfxBuilder = cert.ToPfx(privateKey);
var pfx = pfxBuilder.Build("my-cert", "abcd1234");
System.IO.File.WriteAllBytes("./my-cert.pfx", pfx);
Updated 21-Oct-19 22:55pm

1 solution

Rate this:
Please Sign up or sign in to vote.

Solution 1

See this CodeProject article: Creating Self-signed Certificates[^]
This is batch file oriented, but you can call these using: Process.Start Method (System.Diagnostics) | Microsoft Docs[^]

Here is a programmatic way: X.509 certificates - Rebex.NET[^]

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100