Step-by-Step Guide to Enabling TCPS (SSL/TLS) in Oracle Database
Oracle TCPS (TCP with SSL/TLS) ensures secure encrypted communication between clients and the database. This guide provides a step-by-step approach to enabling TCPS in Oracle 12c, 19c, and later.
🔹 Prerequisites
Before proceeding, ensure you have:
✅ Oracle Database Enterprise Edition installed.
✅ Oracle Wallet Manager (OWM) or orapki
command-line utility.
✅ Admin access to the database and server.
🔹 Step 1: Create and Configure Oracle Wallet
Oracle Wallet is required to store SSL certificates for TCPS communication.
📌 Option 1: Using orapki
(Command Line)
Run the following commands to create a self-signed certificate and wallet:
📌 Explanation:
- Creates a wallet (
-wallet /u01/app/oracle/wallet
). - Generates a self-signed certificate (
-self_signed -validity 365
). - Enables auto-login for the wallet.
🔹 Step 2: Enable TCPS in the Oracle Listener
Modify the listener.ora file ($ORACLE_HOME/network/admin/listener.ora
) to include TCPS support:
📌 Explanation:
- TCP (1521) for standard connections.
- TCPS (2484) for SSL/TLS secured connections.
🔹 Restart the Listener
Verify the listener is running with TCPS:
🔹 Step 3: Configure SQL*Net for Secure TCPS Connections
Edit sqlnet.ora ($ORACLE_HOME/network/admin/sqlnet.ora
) and add:
📌 Explanation:
- Disables client authentication (
SSL_CLIENT_AUTHENTICATION = FALSE
). - Defines wallet location (
WALLET_LOCATION
). - Forces TLS v1.2 (
SSL_VERSION = TLSv1.2
).
🔹 Step 4: Configure TCPS in TNSNAMES.ORA
Edit tnsnames.ora ($ORACLE_HOME/network/admin/tnsnames.ora
) to define a TCPS service:
📌 Explanation:
- TCPS protocol enabled (
PROTOCOL = TCPS
). - Uses SSL certificate for authentication (
SSL_SERVER_CERT_DN
).
🔹 Step 5: Validate TCPS Connection
Run the following command to test secure TCPS connection:
Verify that the connection is using TCPS:
📌 Expected Output:
If the output shows TCPS, the connection is secured via SSL/TLS.
Post a Comment
Post a Comment