PostgreSQL database connection for Oracle WebLogic Server

IBM Content Navigator supports connections to a PostgreSQL database on Oracle WebLogic Server using Non-SSL, SSL with password-based authentication, or SSL with certificate-based authentication.

Prerequisites

Before you configure the PostgreSQL database connection, ensure that you have completed the following tasks:

  • Created a PostgreSQL database for IBM Content Navigator. For more information, see Creating a PostgreSQL database for IBM Content Navigator.
  • Installed the PostgreSQL JDBC driver on the IBM Content Navigator server.
  • If you plan to use SSL connections, obtained the necessary SSL certificates from your database administrator.
  • Gathered the required connection parameters. For more information, see the worksheet for your configuration type.

About PostgreSQL authentication methods

You can configure IBM Content Navigator to connect to PostgreSQL using one of the following authentication methods:
SSL connection
Modes
  • sslmode=require - Requires SSL but does not verify the server certificate
  • sslmode=verify-ca - Requires SSL and verifies the server certificate against a trusted CA
  • sslmode=verify-full - Requires SSL, verifies the server certificate, and checks that the server hostname matches the certificate
Authentication types
SSL with password-based authentication
Encrypted connection by using SSL with username and password credentials. This method provides secure data transmission while using standard password authentication.

Connection URL format:

jdbc:postgresql://hostname:port/database_name?ssl=true&sslmode=<ssmode>

Example: jdbc:postgresql://localhost:5432/ICNDB?ssl=true&sslmode=require

SSL with certificate-based authentication
Encrypted connection by using SSL with client certificates for authentication. This method provides the highest level of security by using certificate-based authentication in addition to encryption.

Connection URL format:

postgresql://hostname:port/database_name?ssl=true&sslmode=<sslmode>&sslcert=/path/to/client.crt&sslkey=/path/to/client.key&sslrootcert=/path/to/root.crt

If the private key is encrypted, add the sslpassword parameter:

&sslpassword=key_password

PostgreSQL with SSL certificate-based authentication is supported for both IBM Content Navigator databases and Content Platform Engine global configuration database (GCD) and object store databases.

Non-SSL connection
Standard connection without encryption. Use this method for development or testing environments where security is not a primary concern.

The JDBC driver file is typically named postgresql-version.jar. Place the driver in the $DOMAIN_HOME/lib directory or add it to the WebLogic Server class path.

Configuration requirements

To configure a PostgreSQL connection for IBM Content Navigator on Oracle WebLogic Server, you need the following information:

JDBC driver files
The PostgreSQL JDBC driver file, typically named postgresql-version.jar. This file must be placed in the $DOMAIN_HOME/lib directory or added to the WebLogic Server class path.
Connection parameters
  • Database hostname or IP address
  • Port number (default is 5432)
  • Database name
  • Database username and password
SSL certificates (for SSL connections)

For SSL with password-based authentication using verify-ca or verify-full modes:

  • PostgreSQL server certificate must be imported into the WebLogic Server truststore
  • Root certificate file path

For SSL with certificate-based authentication:

  • Client certificate file (client.crt)
  • Client private key file (client.key)
  • Root certificate file (root.crt)
  • These files must be placed in a secure location accessible to the WebLogic Server
  • The WebLogic Server process must have read permissions for these files

Configuring the connection

Use the IBM Content Navigator Configuration and Deployment Tool to configure the PostgreSQL connection. The tool creates the data source with the appropriate settings for your chosen authentication method.

For information about the parameters required by the Configuration and Deployment Tool, see the worksheet for your database configuration.

When configuring the data source in WebLogic Administration Console:

  • Select PostgreSQL as the database type
  • Select PostgreSQL's Driver (Type 4) Versions: Any as the database driver
  • Specify the connection URL with the appropriate SSL parameters based on your authentication method
Tip: When using SSL connections, you can modify the connection URL in the advanced options to include the SSL parameters.

Verification

After you configure the PostgreSQL database connection, IBM Content Navigator can connect to the PostgreSQL database by using the specified authentication method.

To verify the connection:

  • Test the data source configuration in the WebLogic Administration Console
  • For SSL connections, verify that the SSL mode is correctly configured in the connection URL
  • For certificate-based authentication, verify that the client certificate files are accessible and have correct permissions
  • Check the WebLogic and PostgreSQL server logs for any connection errors

Post-configuration tasks

After you configure the database connection, complete the following tasks:

Tip: For more information about PostgreSQL SSL configuration, see Configuring an SSL connection for PostgreSQL External link opens a new window or tab.