You use SSL for secure Instant Messaging communications. This chapter provides instructions on setting up SSL for Instant Messaging in the following sections:
Instant Messaging supports the Secure Sockets Layer (SSL) protocol, for encrypted communications and for certificate-based authentication of Instant Messaging servers. Instant Messaging server supports SSL version 3.0.
Instant Messaging multiplexor and Instant Messenger also support SSL for encrypted communication between the client and the multiplexor.
Enabling SSL for Instant Messaging server requires the following:
Obtaining and installing a certificate for your Instant Messaging server, and configuring the Instant Messaging server to trust the Certification Authority’s certificate.
Ensuring that each Instant Messaging server that needs to communicate using SSL with your server, obtains and installs a certificate.
Turning on SSL in the server by setting the appropriate parameters in the iim.conf file.
Enabling SSL between the multiplexor and Instant Messenger requires the following:
For more information about managing certificates, see the Web Server and Application Server product documentation at http://docs.sun.com.
To enable SSL, you need to request a certificate. You can request the certificate using Sun JavaTM System Web Serveror Sun JavaTM System Application Server.
Type the following URL for starting the administration server in your browser:
http://hostname.domain-name:administration_port |
A window prompting you for a user name and password appears.
Type the administration user name and password you specified during the Web Server or Application Server installation.
The Administration Server page appears.
Create a separate Web Server or Application Server instance.
For more information on installing multiple instances of the server, see the product documentation at http://docs.sun.com/.
Create a trust database to store the public and private keys, referred as the key-pair file.
The key-pair file is used for SSL encryption.
For information on creating a trust database, see the Web Server or Application Server product documentation at http://docs.sun.com/.
Request a certificate from the Certificate Authority.
For more information on requesting a certificate, see the Web Server or Application Server product documentation at http://docs.sun.com/.
After you receive the server certificate from your Certificate Authority, you need to install the certificate and create databases for secure communication.
Type the following URL for starting the administration server in your browser:
http://hostname.domain-name:administration_port |
A window appears, prompting you for a user name and password.
Type the administration user name and password you specified during the Web Server or Application Server installation.
The Administration Server page appears.
Install the server certificate.
For more information on installing the certificate, see the Web Server or Application Server product documentation at http://docs.sun.com
Change to your Web Server or Application Server’s /alias directory.
Copy the database files from the /alias directory to the Instant Messaging server's im_cfg_base directory.
cp https-serverid-hostname-cert8.db /etc/opt/SUNWiim/default/config/cert8.db |
cp https-serverid-hostname-key3.db /etc/opt/SUNWiim/default/config/key3.db |
cp secmod.db /etc/opt/SUNWiim/default/config/secmod.db |
The end user on which the Instant Messaging server runs should have Read permission on cert7.db, key3.db, and secmod.db files. In addition, if you created multiple instances of Instant Messaging, the name of the /default directory will vary depending on the instance.
See Table 3–1 for default locations for im_cfg_base.
Change to your Instant Messaging server's im_cfg_base directory.
See Instant Messaging Server Directory Structure for information on locating im_cfg_base.
Create a file named sslpassword.conf using an editor of your choice.
Enter the following line in sslpassword.conf.
Internal (Software) Token:password |
Where password is the password you specified when you created the trust database.
Save and close sslpassword.conf.
Ensure that all Instant Messenger end users have Ownership and Read permission on sslpassword.conf.
Verify that SSL is working properly.
You can do this a number of ways, for example by following the steps in Invoking the Secure Version of Instant Messenger.
Log in to the Web Server or Application Server as an administrator.
Remove the server instance that you created while requesting the certificate.
Table 10–1 lists the parameters in iim.conf for enabling SSL between Instant Messenger and multiplexor. It also lists the description and the default value of these parameters.
Table 10–1 Instant Messenger and Multiplexor SSL Parameters
Parameter |
Default Value |
Description |
---|---|---|
iim_mux.usessl |
off |
If the value is set to on, the multiplexor requires an SSL handshake for each connection it accepts, before exchanging any application data. |
iim_mux.secconfigdir |
Solaris: /etc/opt/SUNWiim/default/config Linux: /etc/opt/sun/im/default/config |
This directory contains the key and certificate databases. It usually contains the security module database. In addition, if you created multiple instances of Instant Messaging, the name of the /default directory will vary depending on the instance. See Creating Multiple Instances from a Single Instant Messaging Installation for more information. |
iim_mux.keydbprefix |
(Empty string) |
This value should contain the key database filename prefix. The key database file name must always end with key3.db. If the Key database contains a prefix, for example This-Database-key3.db, then value of this parameter is This-Database. |
iim_mux.certdbprefix |
(Empty string) |
This value should contain the certificate database filename prefix. The certificate database file name must always end with cert7.db. If the certificate database contains a prefix, for example Secret-stuff-cert7.db, then value of this parameter is Secret-stuff. |
iim_mux.secmodfile |
secmod.db |
This value should contain the name of the security module file. |
iim_mux.certnickname |
Server-Cert |
This value should contain the name of the certificate you entered while installing the certificate. The certificate name is case-sensitive. |
iim_mux.keystorepasswordfile |
sslpassword.conf |
This value should contain the relative path and the name of the file containing the password for the key database. This file should contain the following line: Internal (Software) Token:password Where password is the password protecting the key database. |
Open iim.conf.
See iim.conf File Syntax for instructions on locating and modifying iim.conf.
Add the values from Table 10–1 to the multiplexor configuration parameters in iim.conf.
The following is an example of iim.conf with the multiplexor configuration parameters included:
! IIM multiplexor configuration ! ============================= ! ! Multiplexor specific options ! IP address and listening port for the multiplexor. ! WARNING: If this value is changed, the port value of ’-server’ ! argument in the client’s im.html and im.jnlp files should ! also be changed to match this. iim_mux.listenport = "siroe.com:5222" ! The IM server and port the multiplexor talks to. iim_mux.serverport = "siroe.com:45222" ! Number of instances of the multiplexor. iim_mux.numinstances = "1" ! Maximum number of threads per instance iim_mux.maxthreads = "10" ! Maximum number of concurrent connections per multiplexor process iim_mux.maxsessions = "1000" iim_mux.usessl = "on" iim_mux.secconfigdir = "/etc/opt/SUNWiim/default/config" iim_mux.keydbprefix = "This-Database" iim_mux.certdbprefix = "Secret-stuff" iim_mux.secmodfile = "secmod.db" iim_mux.certnickname = "Server_Cert" iim_mux.keystorepasswordfile = "sslpassword.conf" |
The secure version of Instant Messenger can be invoked by accessing imssl.html or imssl.jnlp from your web browser. These files are located under the resource directory, the base directory under which all the Instant Messenger resources are stored.
The links to these applet descriptor files can also be added to index.html.
Before you can activate SSL, you must create a certificate database, obtain and install a server certificate, and trust the CA’s certificate as described earlier.
Table 10–2 lists the parameters in iim.conf used to enable SSL between two Instant Messaging servers. It also contains the description and the default value of these parameters.
Table 10–2 Server-to-Server SSL Configuration Parameters
Parameter |
Default Value |
Description |
---|---|---|
iim_server.secconfigdir |
Solaris: /etc/opt/SUNWiim/default/config Linux: /etc/opt/sun/im/default/config |
This directory contains the key and certificate databases. It usually contains the security module database. If you created multiple instances of Instant Messaging, the name of the /default directory will vary depending on the instance. See Creating Multiple Instances from a Single Instant Messaging Installation for more information. |
iim_server.keydbprefix |
None |
This value should contain the key database filename prefix. The key database file name must always end with key3.db. If the Key database contains a prefix, for example This-Database-key3.db, then value of this parameter is This-Database. |
iim_server.certdbprefix |
None |
This value should contain the certificate database filename prefix. The certificate database file name must always end with cert7.db. If the certificate database contains a prefix, for example Secret-stuff-cert7.db, then value of this parameter is Secret-stuff. |
iim_server.secmodfile |
secmod.db |
This value should contain the name of the security module file. |
iim_server.certnickname |
Server-Cert |
This value should contain the name of the certificate you entered while installing the certificate. The certificate name is case-sensitive. |
iim_server.keystorepasswordfile |
sslpassword.conf |
This value should contain the relative path and the name of the file containing the password for the key database. This file should contain the following line: Internal (Software) Token:password Where password is the password protecting the key database. |
iim_server.trust_all_cert |
false |
If this value is true than the server will trust all certificates and will also add the certificate information into the log files. |
Set these iim.conf parameters:
iim_server.usesslport=true
iim_server.sslport=5223
These parameters should already be in the iim.conf file.
See iim.conf File Syntax for instructions on locating and modifying iim.conf.
Set the server-to-server configuration as described in Chapter 6, Federating Deployment of Multiple Instant Messaging Servers.
Add the following additional parameter to iim.conf:
iim_server.coserver1.usessl=true
Change the port number of the following parameter:
iim_server.coserver1.host=hostname:5223
The port number should be the SSL port of the other server.
Refresh the server configuration using imadmin.
imadmin refresh server |
Following is a section of iim.conf file with the required SSL configuration:
! Server to server communication port. iim_server.port = "5269” ! Should the server listen on the server to server ! communication port iim_server.useport = "True” ! Should this server listen for server-to-server communication ! using ssl port iim_server.usesslport = "True” iim_server.sslport=5223 iim_server.coservers=coserver1 iim_server.coserver1.serverid=Iamcompany22 iim_server.coserver1.password=secretforcompany22 iim_server.coserver1.usessl=true iim_server.coserver1.host=iim.i-zed.com:5223 iim_server.serverid=Iami-zed iim_server.password=secret4i-zed iim_server.secconfigdir = "/etc/opt/SUNWiim/default/config" iim_server.keydbprefix = "This-Database" iim_server.certdbprefix = "Secret-stuff" iim_server.secmodfile = "secmod.db" iim_server.certnickname = "Server_Cert" iim_server.keystorepasswordfile = "sslpassword.conf" |