Mac platform
Connect using SQL developer tool
Download the SQL Developer.
Download SSL certificate from Service Overview page.
Import
crt/pemto JKS file.keytool -import -alias testalias -file TessellCA.crt -keypass keypass -keystore test.jks -storepass test@123Update JKS path in SQL Developer JVM command-line
File path
~/.sqldeveloper/22.2.1/product.confAddVMOption -Djavax.net.ssl.trustStore=/Users/<user>/Desktop/test.jksAddVMOption -Djavax.net.ssl.trustStoreType=JKSAddVMOption -Djavax.net.ssl.trustStorePassword=test@123Restart the SQL Developer.
Add a new connection and select options like below.

Add Custom JDBC url.
jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS=(PROTOCOL=TCPS)(PORT=1521)(HOST=oraclesi19c<service name>-ppmno.qabyoaupg001.tsl-barc.cloud))(CONNECT_DATA=(SERVICE_NAME=orcl))(SECURITY=(ssl_server_cert_dn="CN=oraclesi19c<service name>-ppmno.qabyoaupg001.tsl-barc.cloud")))Verify the connection mode.
SELECT sys_context('USERENV', 'NETWORK_PROTOCOL') as network_protocol, sys_context('USERENV', 'AUTHENTICATION_METHOD') as authentication_method FROM dual;
Connect using python code
x86 platform
The steps are same as Linux setup.
Apple M* Chip
Tools/Lib
Latest Oracle instant libraries are not available for Apple M* platform so we have to use Rosetta to use x86_64 libraries.
Run the terminal with Rosetta support
Download Mac x86 Oracle instant libraries from https://www.oracle.com/cis/database/technologies/instant-client/macos-intel-x86-downloads.html and unzip it.
Download and unzip SQLcl https://www.oracle.com/database/sqldeveloper/technologies/sqlcl/download/.
Setup oracle wallet
Steps are same as Linux.
Now you can connect to DB using either sqlplus or python. sqlplus steps are same as Linux but make sure you run x86 sqlplus client from Rosetta enabled terminal.
Connect using Python (Rosetta enabled terminal)
import oracledb
import cryptography
import os
cs = '''<user>/<password>@(DESCRIPTION = (ADDRESS = (PROTOCOL = TCPS)(HOST = oraclessl<service name>dnd-efwyu.qarel.tsl-barc.cloud)(PORT = 1521))(CONNECT_DATA = (SERVICE_NAME = <service name>))(SECURITY = (SSL_SERVER_CERT_DN = "CN=oraclessl<service name>dnd-efwyu.qarel.tsl-barc.cloud")))'''
oracledb.init_oracle_client(lib_dir="/Users/<user>/orainscli/instantclient_19_8/")
connection = oracledb.connect(user="<user>", password="<password>", dsn=cs)
cursor = connection.cursor()
cur = cursor.execute("SELECT sys_context('USERENV', 'NETWORK_PROTOCOL') as network_protocol, sys_context('USERENV', 'AUTHENTICATION_METHOD') as authentication_method FROM dual")
print(cur.fetchall())
connection.close()
Last updated
Was this helpful?