开发者

Create X.509 Authorization Certificate

开发者 https://www.devze.com 2023-02-03 04:09 出处:网络
Can we programmatically create X.509 Certificate which contains arbitrary attributes e.g. Age, Gender, Designation etc.

Can we programmatically create X.509 Certificate which contains arbitrary attributes e.g. Age, Gender, Designation etc.

I need to create Authorization Certificate, which client application will present to server application before executing the required function.

开发者_开发百科I am using Java and C#, so any solution/suggestion is good for me.


Have a look at this site for a start.

Create keystore

keytool -genkey -alias youralias -keyalg RSA -keypass yourpassword123 -keystore yourKeystoreRSAMD5 -storepass store123 -sigalg MD5WITHRSA -validity 9999 -dname "CN=Common Name, OU=XYZ, O=Your company name, L=Your Town, S=Region, C=Countryname"

Export cert file in PEM format

keytool -export -alias youralias -file rsamd5YourKey.cer -keystore yourKeystoreRSAMD5 -storepass store123
0

精彩评论

暂无评论...
验证码 换一张
取 消