此内容没有您所选择的语言版本。
11.13.2. SSL/TLS Authentication for Hot Rod
Hot Rod can be encrypted using SSL, and has the option to require client certification authentication.
Use the following procedure to secure the Hot Rod connector using SSL.
Procedure 11.2. Secure Hot Rod Using SSL/TLS
Generate a Keystore
Create a Java Keystore using the keytool application distributed with the JDK and add your certificate to it. The certificate can be either self signed, or obtained from a trusted CA depending on your security policy.Place the Keystore in the Configuration Directory
Put the keystore in the~/JDG_HOME/standalone/configuration
directory with thestandalone-hotrod-ssl.xml
file from the~/JDG_HOME/docs/examples/configs
directory.Declare an SSL Server Identity
Declare an SSL server identity within a security realm in the management section of the configuration file. The SSL server identity must specify the path to a keystore and its secret key.Copy to Clipboard Copied! Toggle word wrap Toggle overflow Add the Security Element
Add the security element to the Hot Rod connector as follows:<hotrod-connector socket-binding="hotrod" cache-container="local"> <security ssl="true" security-realm="ApplicationRealm" require-ssl-client-auth="false" /> </hotrod-connector>
<hotrod-connector socket-binding="hotrod" cache-container="local"> <security ssl="true" security-realm="ApplicationRealm" require-ssl-client-auth="false" /> </hotrod-connector>
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Server Authentication of Certificate
If you require the server to perform authentication of the client certificate, create a truststore that contains the valid client certificates and set therequire-ssl-client-auth
attribute totrue
.
Start the Server
Start the server using the following:This will start a server with a Hot Rod endpoint on port 11222. This endpoint will only accept SSL connections.bin/standalone.sh -c standalone-hotrod-ssl.xml
bin/standalone.sh -c standalone-hotrod-ssl.xml
Copy to Clipboard Copied! Toggle word wrap Toggle overflow