2016-08-17 3 views
0

Apache Tomcatサーバー(バージョン7.0.35)にSSL証明書をインストールすることが任されています。これは私が少しの指針を期待して前に経験したことではありません!私がオンラインで見つけたメモは、新しいインストールをカバーするだけのようです。Apache Tomcat/7.0.35 SSL証明書のインストール

ファイルserver.xmlを見ると、そこには既存のSSL証明書とキーストア設定があることがわかります。

server.xmlに既に存在するものがある場合は、新しいSSL証明書を生成して追加するプロセスを教えてください。たとえば、既存のインスタンスを削除する必要があるのですか?または単に新しいインスタンスを追加できますか?キーストアファイルにさらに変更が必要ですか?

答えて

0
Go to bin folder in server 
Run the command 
keytool -genkey -keyalg RSA -alias selfsigned -keystore keystore.jks -storepass password -validity 360 -keysize 2048 

then 

keytool -list -keystore keystore.jks 


In conf\server.xml edit it as 

//... 
<!-- Define a SSL HTTP/1.1 Connector on port 8443 
     This connector uses the JSSE configuration, when using APR, the 
     connector should be using the OpenSSL style configuration 
     described in the APR documentation --> 

<Connector port="8443" protocol="HTTP/1.1" SSLEnabled="true" 
       maxThreads="150" scheme="https" secure="true" 
       clientAuth="false" sslProtocol="TLS" 
      keystoreFile="my key store file path" 
      keystorePass="password" /> 
//... 

keystorePass = "password"は、 "keytool"コマンドでキーストアに割り当てたパスワードです。

enter image description here

enter image description here

次にURL https://localhost:8443/

enter image description here

+0

を打つ私は.PFX形式で提供された証明書を追加する方法を、ご返信Abhijitいただきありがとうございます。これは可能ですか? – NAP50

+0

はい、その可能性がありますし、これはあなたのために働くことができますし、私に目を与えてください... .jkの代わりに.pfxとして拡張子を使用 –

+0

Abhijitを説明してくれてありがとう。 – NAP50