如何从API Manager的.pem
导出公钥(wso2carbon.jks
)?我想把它放在我的linux服务器的/etc/ssl/certs/ca-certificates.crt
中。我这样做,上面是解决问题like me
答案 0 :(得分:3)
在<APIM_HOME>/repository/resources/security/
运行此命令。这将创建一个证书文件wso2.crt
。
keytool -export -alias wso2carbon -file wso2.crt -keystore wso2carbon.jks
默认密钥库的密码为wso2carbon
。
答案 1 :(得分:2)
您可以使用openssl提取服务器的公钥。
启动服务器
执行命令&#34; openssl s_client -connect:&#34; 例如openssl s_client -connect localhost:8243
从结果中复制证书(BEGIN CERTIFICATE到END CERTIFICATE)
-----开始证书----- MIICNTCCAZ6gAwIBAgIES343gjANBgkqhkiG9w0BAQUFADBVMQswCQYDVQQGEwJV UzELMAkGA1UECAwCQ0ExFjAUBgNVBAcMDU1vdW50YWluIFZpZXcxDTALBgNVBAoM BFdTTzIxEjAQBgNVBAMMCWxvY2FsaG9zdDAeFw0xMDAyMTkwNzAyMjZaFw0zNTAy MTMwNzAyMjZaMFUxCzAJBgNVBAYTAlVTMQswCQYDVQQIDAJDQTEWMBQGA1UEBwwN TW91bnRhaW4gVmlldzENMAsGA1UECgwEV1NPMjESMBAGA1UEAwwJbG9jYWxob3N0 MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCUp / oV1vWc8 / TkQSiAvTousMzO M4asB2iltr2QKozni5aVFu818MpOLZIr8LMnTzWllJvvaA5RAAdpbECb + 48FjbBe 0hseUdN5HpwvnH / DW8ZccGvk53I6Orq7hLCv1ZHtuOCokghz / ATrhyPq + QktMfXn RS4HrKGJTzxaCcU7OQIDAQABoxIwEDAOBgNVHQ8BAf8EBAMCBPAwDQYJKoZIhvcN AQEFBQADgYEAW5wPR7cr1LAdq + IrR44iQlRG5ITCZXY9hI0PygLP2rHANh + PYfTm xbuOnykNGyhM6FjFLbW2uZHQTY1jMrPprjOrmyK5sjJRO4d1DeGHT / YnIjs9JogR Kv4XHECwLtIVdAbIdWHEtVZJyMSktcyysFcvuhPQK8Qc / E / Wq8uHSCo = -----结束证书-----