Configuring an httpEndpoint to use an SSL configuration other than the default

By default, an httpEndpoint element uses the server default SSL configuration, defaultSSLConfig. You can configure an httpEndpoint to use an SSL configuration other than the default SSL configuration.

About this task

You can configure an httpEndpoint to use an SSL configuration in multiple ways. The following examples show different ways to configure an httpEndpoint to use an SSL configuration other than the default SSL configuration.

Procedure

  • Set the SSL options directly on the httpEndpoint.
    The following example shows how to set the SSL options on the httpEndpoint, and assumes that you have as SSL configuration that is named wasListenerSSLConfig already defined that is not in this example:
    <httpEndpoint id="defaultHttpEndpoint"
      host="${listener.host}"
      httpPort="${http.port}"
      httpsPort="${https.port}">
      <sslOptions sslRef="wasListenerSSLConfig" />
    </httpEndpoint>
  • Reference an sslOption element in the httpEndpoint.
    The following example shows how to reference an sslOption element, and assumes that you have an SSL configuration that is named wasListenerSSLConfig already defined that is not in this example:
    <sslOptions id="mySSLOptions" sslRef="wasListenerSSLConfig" />
    
    <httpEndpoint id="defaultHttpEndpoint"
      host="${listener.host}"
      httpPort="${http.port}"
      httpsPort="${https.port}"
      sslOptionsRef="mySSLOptions"
    />
  • Change the default sslOptions element to point to an SSL configuration other than the default SSL configuration.
    This option does not alter the httpEndpoint. The following example shows how to change the default sslOptions element, and assumes that you have an SSL configuration that is named wasListenerSSLConfig already defined that is not in this example:
    <sslOptions id="defaultSSLOptions" sslRef="wasListenerSSLConfig" />