CPM - Example ODBC Connection Strings

CPM - Example ODBC Connection Strings

118
Created On 11/10/26 11:01 AM - Last Modified 11/10/26 15:58 PM


Objective


 

Many of the database-type CPM plugins utilize an ODBC (Open Database Connectivity) driver, installed on the CPM server, to connect to remote databases.  One of the available methods for this connection is an ODBC connection string.  An ODBC connection string is comprised of a sequence of keywords and their corresponding values.  The format of the string, including the specific keywords used, depends on the type of database installed on the target.

 

Note: Configuring a valid connection string is a prerequisite (the same as configuring valid permissions and ensuring the correct network ports are open) that must be completed before the plugin can be tested.  For direct assistance in doing so, please involve your DBA and/or database vendor Support.  You may refer to the respective Idira CPM plugin documentation as a supplemental resource.

 

This article attempts to provide some initial assistance with configuring a valid connection string.  The examples provided are sourced directly from the respective official database vendor documentation.  Please refer to the official database vendor documentation and/or work with your DBA, as needed.

 

Note: Before attempting to use the CPM plugin itself, we strongly recommend testing the ODBC connection string via Powershell on the CPM.  To do so, please follow the steps in this KB: How can I test ODBC connection strings outside of CPM

 



Environment


12.2;14.5 Privileged Access Manager (PAM, self-hosted);Privilege Cloud Central Policy Manager (CPM)

Procedure


 

The tables below detail example ODBC connection strings for each of the various database-type CPM plugins that utilize such strings.  It is important to note that the specific ODBC driver shown in each example is for illustration purposes only.  Refer to the CPM plugin documentation to determine which drivers are supported for use.  Refer to the respective database vendor documentation for instructions on how to install the driver.

 

Note: The connection string examples from the official database vendor documentation supersede any and all connection string examples shown in the respective CPM plugin documentation, as well as this article.

 

 

SQL Database
VendorDocumentationConnection String ExamplesNotes

Microsoft SQL Server


Microsoft Azure SQL Database


Amazon RDS for SQL Server

Microsoft

 

Idira


Microsoft

 

Idira


Amazon

 

Idira

--The examples below are valid for all current SQL Database plugins.

Driver={ODBC Driver 18 for SQL Server};Server=%ADDRESS%,%PORT%;[Database=%DATABASE%;]Uid=%USER%; Pwd=%LOGONPASSWORD%;Encrypt=No;

-The 'Encrypt' keyword denotes whether or not SLL/TLS is enabled for the connection.

-Wrapping values in brackets ( [] ) tells the plugin to treat them as optional.  This works for all of the database plugins.

Driver={ODBC Driver 17 for SQL Server};Server=%ADDRESS%;Database=%DATABASE%;Uid=%USER%; Pwd=%LOGONPASSWORD%;Trusted_Connection=yes;Encrypt=yes;-When testing via Powershell, setting the 'Trusted_Connection' keyword to Yes tells the ODBC driver that, when attempting to connect to the target, utilize the credentials of the user running Powershell. 
Driver={ODBC Driver 18 for SQL Server};Server=%ADDRESS%,%PORT%;Database=%DATABASE%;Uid=%USER%; Pwd=%LOGONPASSWORD%;Encrypt=Yes;-When the server instance needs to be specified, the connection string value for the address keyword stays the same.  In PVWA, update the address property in the format of "server\instance".

 

Oracle Database
VendorDocumentationConnection String ExamplesNotes

Oracle Database


Amazon RDS for Oracle


Oracle Cloud Autonomous Database

Oracle

 

Idira


Amazon

 

Idira


Oracle

 

Idira

--The examples below are valid for all current Oracle Database plugins.

Driver={Oracle in instantclient_21_18};Dbq=//%ADDRESS%:%PORT%/%DATABASE%;Uid=%USER%;Pwd=%LOGONPASSWORD%;

-The double forward slashes in front of the address value may or may not be needed, dependent upon the configuration of the target.
Driver={Oracle in instantclient_19_26};Dbq=%TNSSERVICENAME%;Uid=%USER%;Pwd=%LOGONPASSWORD%;-Omitting the port and database values tells ODBC to look for the presence of a tnsnames.ora file on the CPM.
Driver={Oracle in instantclient_21_8};Dbq=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=%ADDRESS%)(PORT=%PORT%))(CONNECT_DATA=(SID=%DATABASE%)));Uid=%USER%;Pwd=%LOGONPASSWORD%;-This example denotes inserting an entry from tnsnames.ora into the string itself.

 

MySQL Server
VendorDocumentationConnection String ExamplesNotes

Oracle MySQL


Azure Database for MySQL


Amazon RDS for MySQL

MySQL

 

Idira


Microsoft

 

Idira


Amazon

 

Idira

--The examples below are valid for all current MySQL Database plugins.

Driver={MySQL ODBC 8.0.42 Unicode Driver};Server=%ADDRESS%;Database=%DATABSE%; User=%USER%;Port=%PORT%;Password=%LOGONPASSWORD%-Some documentation still denotes utilizing the 'Option' keyword, with a value of '3'.  This is deprecated and no longer needed.
Driver={MySQL ODBC 5.1.13 Driver};Server=%ADDRESS%;Database=%DATABSE%; User=%USER%;Password=%LOGONPASSWORD%;sslca=<path_to_ca-cert>;sslcert=<path_to_client-cert>;sslkey=<path_to_client-key>;sslverify=1;-While this example shows the correct syntax for enabling an SSL connection, this has not been tested with the plugin, thus it is not directly supported.

 

PostgreSQL
VendorDocumentationConnection String ExamplesNotes

PostgreSQL


Azure Database for PostgreSQL

 


Amazon RDS for PostgreSQL


Fujitsu Enterprise Postgres

PostgreSQL

 

Idira 


Microsoft

 

Idira 


Amazon

 

Idira


Fujitsu

 

Idira

--The examples below are valid for all current PostgreSQL Database plugins.

Note: The Fujitsu Enterprise Postgres plugin utilizes its own ODBC driver: 'Fujitsu Enterprise Postgres Unicode 16'.

Driver={PostgreSQL UNICODE};Server=%ADDRESS%;[Database=%DATABASE%;]Uid=%USER%;Pwd=%LOGONPASSWORD%;[Port=%PORT%];-Default string, with port and database set as optional.
Driver={PostgreSQL UNICODE};Server=%ADDRESS%;Database=%DATABASE%;Port=%PORT%; Uid=%USER%;Pwd=%LOGONPASSWORD%;sslmode=require;-This example shows the correct syntax for enabling an SSL connection.  Installation of the relevant certificate must be done first.

 

MariaDB
VendorDocumentationConnection String ExamplesNotes

 
MariaDB Server


Amazon RDS for MariaDB

MariaDB

 

Idira


Amazon

 

Idira

--The examples below are valid for all current MariaDB Database plugins.
Driver={MariaDB ODBC 3.1 Driver};Server=%ADDRESS%;[Database=%DATABASE%;]Uid=%USER%;Pwd=%LOGONPASSWORD%;[Port=%PORT%]-Default string, with port and database set as optional.
Driver={MariaDB ODBC 3.1 Driver};Server=%ADDRESS%;Database=%DATABASE%;Uid=%USER%; Pwd=%LOGONPASSWORD%;sslca=<path_to_ca-cert>;sslcert=<path_to_client-cert>;sslkey=<path_to_client-key>;sslverify=1;-While this example shows the correct syntax for enabling an SSL connection, this has not been tested with the plugin, thus it is not directly supported.

 

Other Database Types
VendorDocumentationConnection String ExamplesNotes
AWS Redshift

Amazon

 

Idira

Driver={Amazon Redshift (x86)};Server=%ADDRESS%;Database=%DATABASE%; Port=%PORT%;Uid=%USER%;Pwd=%LOGONPASSWORD%;-Additional keywords exist, such as 'sslmode'.  Refer to AWS documentation.
IBM Netezza

IBM

 

Idira

Driver={NetezzaSQL};servername=%ADDRESS%;port=%PORT%; database=%DATABASE%;username=%USER%;password=%LOGONPASSWORD%;-Additional keywords exist, such as 'schemaname'.  Refer to IBM documentation.
SAP HANA

SAP

 

Idira

Driver={HDBODBC32};ServerNode=%ADDRESS%:%PORT%; DatabaseName=%DATABASE%;Uid=%USER%;Pwd=%LOGONPASSWORD%;-This is the default connection string.  Wrap keyword/value pairs in brackets ( [] ) to make them optional.
Driver={HDBODBC32};ServerNode=%ADDRESS%;Uid=%USER%; Pwd=%LOGONPASSWORD%;Encrypt=yes;-Additional keywords exist, and are required, in order for a secure session to be established.  Refer to SAP documentation.
Snowflake Data Warehouse

Snowflake

 

Idira

Driver={SnowflakeDSIIDriver};Server=%ADDRESS%; UID=%USER%;PWD=%LOGONPASSWORD%;-Additional keywords exist, such as 'database' and 'port'.  Refer to Snowflake documentation.
Sybase ASE Database

SAP

 

Idira

Driver={Adaptive Server Enterprise}ServerName=%ADDRESS%,%PORT%; DatabaseName=%DATABASE%;UID=%USER%;PWD=%LOGONPASSWORD%;-Additional keywords exist, and are required, in order for a secure session to be established.  Refer to SAP documentation.

 

 



Actions
  • Print
  • Copy Link

    https://knowledgebase.paloaltonetworks.com/KCSArticleDetail?id=kA1hj000000177bCAA&lang=en_US&refURL=http%3A%2F%2Fknowledgebase.paloaltonetworks.com%2FKCSArticleDetail