How to change SQL connection property to accept trust certificate in WebFOCUS

How to change SQL connection property to accept trust certificate in WebFOCUS

book

Article ID: KB0070543

calendar_today

Updated On:

Products Versions
ibi WebFOCUS WebFOCUS version 82 to 92x

Description

If the SQL Server is running with SSL-encrypted communication WebFOCUS installation fails with the below error in install.log

url=jdbc:sqlserver://NA00SQSH101-SAL:41433;DatabaseName=Webfocus_Prod
userid=Webfocus
pswd=*****
driver=com.microsoft.sqlserver.jdbc.SQLServerDriver
EXCEPTION:SQL exception
IBIJDBCExceptions: ERROR_NOT_IBIJDBCExceptions
"encrypt" property is set to "true" and "trustServerCertificate" property is set to "false" but the driver could not establish a secure connection to SQL Server by using Secure Sockets Layer (SSL) encryption: Error: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target. ClientConnectionId:df18754f-9d87-406d-a2a9-ffd4be94741f
com.microsoft.sqlserver.jdbc.SQLServerConnection.terminate(SQLServerConnection.java:4026)
com.microsoft.sqlserver.jdbc.TDSChannel.enableSSL(IOBuffer.java:1954)
com.microsoft.sqlserver.jdbc.SQLServerConnection.login(SQLServerConnection.java:3172)
java.sql.DriverManager.getConnection(DriverManager.java:664)
com.ibi.webfocus.setup.WFConnection.testConnection(Unknown Source)
com.ibi.webfocus.setup.WFConnection.main(Unknown Source)

 STDERR: EXITCODE:0


INFO: Jan 22 2024_AT:02:18:53 EST
INFO: CONNECTED=N Database connectivity failed, Please ensure that your Database is running and the correct values were entered for the Database.


INFO: SetupConnectionPanelMsg...
INFO: setup DB connection failure msg:
INFO: MSG_LABEL=Database connectivity failed.
INFO: MSG_BODY=Please ensure that your Database is running and 
the correct values were entered for the Database. 

Repository tables will not be created and WebFOCUS will not 
work as is. You may continue with this error or correct the 
connection problem and go back to the previous panel 
to test again.
ERROR: Failed to connect to Microsoft SQL Server

Issue/Introduction

How to change SQL connection property to accept trust certificate in WebFOCUS

Resolution

WebFOCUS is using the JDBC functionality to connect to the Repository Database vendors.
When using the basic options, the installers tries to get details based on the specific DB vendor that you have selected.
The installer then converts this information in a JDCB URL format.

The installer doesn't have the ability to convert information for a MSSQL secure connection, instead you should select the Generic JDBC Driver.
You can specify the path to the JDBC Driver, the classname, and the JDBC URL  in install.cfg which will include the specific vendor options.

e.g.
JDBC Class: com.microsoft.sqlserver.jdbc.SQLServerDriver
JDBC URL: jdbc:sqlserver://localhost:1433;databaseName=WebFOCUS82;encrypt=true;trustServerCertificate=true