title: Oracle - How to configure Oracle 21c XE for SSL traffic encryption?
body: <p>I am new to Oracle and I am trying to configure an Oracle 21c XE database (<a href="https://github.com/oracle/docker-images/tree/main/OracleDatabase/SingleInstance/dockerfiles/21.3.0" rel="nofollow noreferrer">built from the official Dockerfile</a>) to encrypt traffic using SSL/TLS (just for encryption, not for mutual authentication). My configuration files are:</p>
  <p>/opt/oracle/oradata/dbconfig/XE/listener.ora</p>
  <pre><code># listener.ora Network Configuration File:
  
  SID_LIST_LISTENER =
    (SID_LIST =
      (SID_DESC =
        (SID_NAME = PLSExtProc)
        (ORACLE_HOME = /opt/oracle/product/21c/dbhomeXE)
        (PROGRAM = extproc)
      )
    )
  
  LISTENER =
    (DESCRIPTION_LIST =
      (DESCRIPTION =
        (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC_FOR_XE))
        (ADDRESS = (PROTOCOL = TCPS)(HOST = 0.0.0.0)(PORT = 1521))
      )
    )
  
  DEFAULT_SERVICE_LISTENER = (XE)
  
  # Extra configuration to enable SSL
  
  SSL_CLIENT_AUTHENTICATION = FALSE
  
  WALLET_LOCATION =
    (SOURCE =
      (METHOD = FILE)
      (METHOD_DATA =
        (DIRECTORY = /opt/my_wallet/)
      )
    )
  </code></pre>
  <p>/opt/oracle/oradata/dbconfig/XE/sqlnet.ora</p>
  <pre><code>NAMES.DIRECTORY_PATH= (TNSNAMES, EZCONNECT, HOSTNAME)
  
  # Extra configuration to enable SSL
  
  SSL_CLIENT_AUTHENTICATION = FALSE
  
  WALLET_LOCATION =
    (SOURCE =
      (METHOD = FILE)
      (METHOD_DATA =
        (DIRECTORY = /opt/my_wallet/)
      )
    )
  SSL_CIPHER_SUITES = (SSL_RSA_WITH_AES_256_CBC_SHA, SSL_RSA_WITH_3DES_EDE_CBC_SHA)
  </code></pre>
  <p>/opt/oracle/oradata/dbconfig/XE/tnsnames.ora</p>
  <pre><code># tnsnames.ora Network Configuration File:
  
  XE =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = TCPS)(HOST = 0.0.0.0)(PORT = 1521))
      (CONNECT_DATA =
        (SERVER = DEDICATED)
        (SERVICE_NAME = XE)
      )
    )
  
  LISTENER_XE =
    (ADDRESS = (PROTOCOL = TCPS)(HOST = 0.0.0.0)(PORT = 1521))
  
  EXTPROC_CONNECTION_DATA =
    (DESCRIPTION =
       (ADDRESS_LIST =
         (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC_FOR_XE))
       )
       (CONNECT_DATA =
         (SID = PLSExtProc)
         (PRESENTATION = RO)
       )
    )
  </code></pre>
  <p>I also added a self-signed certificate to the wallet referenced in the configuration files.</p>
  <p>When trying to connect with <code>sqlplus system/&lt;password&gt;@XE</code> it returns <code>ORA-12514: TNS:listener does not currently know of service requested in connect descriptor.</code></p>
  <p>I have tried making different changes to the previous configuration, but I am always getting the same error. Am I missing something?</p>
  <p>Thanks in advance.</p>