Thursday

Cryptography - Make X509 Certificate for SAML 2.0 in Base 64 format


Every now and then I have to create X509 certificates for SAML 2.0 based IdP. I use Windows 7 to generate these certificates. But the problem I usually face is that most of the instructions I find out there are geared towards Windows XP or Windows Server which doesn't work for me.

I have compiled the following instructions which will work for any Windows OS.


This is end to my Google search for finding instructions for generating X509 certificates on Windows 7:
  1. Open command prompt as Admin
  2. Create Certificate and Private Key files
    1. makecert -r -pe -sky exchange -n "cn=www.idp.com" -sv idp.pvk idp.cer
  3. Convert the PVK file to a PFX file
    1. pvk2pfx -pvk idp.pvk -spc idp.cer -pfx idp.pfx -po password –f
  4. Install .cer file in personal store
  5. Export the newly installed certificate from personal store to Base64 format, using MMC
  6. Open the certificate in notepad and put it in metadata file if you have to.

No comments:

Post a Comment

Your comments are highly appreciated!