9.5. 转换 PFX 文件
智能卡工具需要特定格式的证书和密钥。您必须使用 OpenSSL 将从 Active Directory 导出的 PKCSautomationhub (.PFX)文件转换为单独的 PEM 格式的私钥和证书文件。
先决条件
- PFX 文件被复制到 IdM 客户端机器中。
流程
在 IdM 客户端上,将文件转换为 PEM 格式:
[root@idmclient1 ~]# openssl pkcs12 -in aduser1.pfx -out aduser1_cert_only.pem -clcerts -nodesEnter Import Password:将密钥提取到单独的文件中:
[root@idmclient1 ~]# openssl pkcs12 -in adduser1.pfx -nocerts -out adduser1.pem > aduser1.key将公共证书提取到单独的文件中:
[root@idmclient1 ~]# openssl pkcs12 -in adduser1.pfx -clcerts -nokeys -out aduser1_cert_only.pem > aduser1.crt此时,您可以将
aduser1.key和aduser1.crt存储在智能卡中。