Error during junitlisa execution: java.sql.SQLException: ORA-01017: invalid username/password; logon denied
search cancel

Error during junitlisa execution: java.sql.SQLException: ORA-01017: invalid username/password; logon denied

book

Article ID: 135837

calendar_today

Updated On:

Products

CA Application Test Service Virtualization

Issue/Introduction

Funning  JDBC test script using Junit lisa Test on an AIX machine.  

This is the error got at the junitlisa.log file:

2019-08-01 12:04:45,297Z (07:04) [C3P0PooledConnectionPoolManager[identityToken->147c9yea4ldq9pxnilo37|73f169bb]-HelperThread-#2] DEBUG com.mchange.v2.resourcepool.BasicResourcePool - An exception occurred while acquiring a poolable resource. Will retry.

java.sql.SQLException: ORA-01017: invalid username/password; logon denied

This is only happening while it call a subprocess and attempt a connection to a database. Credentials were already checked multiple times and they are fine.

Without the DB connection step, a simple test case can be executed without issues.

 

Environment

All supported DevTest releases.

Cause

Customer is using  IBM JDK on AIX machine and not DEVTEST JRE.

This exception is thrown because of a restriction imposed by default JDK. On a default JDK installation, AES is limited to 128 bit key size. In order to perform 256-bit AES encryption, you will need to download and install Java Cryptography Extension (JCE) Unlimited Strength Jurisdiction Policy Files. 

Resolution

Here are the steps to fix java.security.InvalidKeyException: Illegal key size exception:

 

This is the link related to the exception and solution

Fixing java.security.InvalidKeyException: Illegal key size exception

 

This is the link need to follow and let download jar with a compatible version of IBM java.

Downloading and installing the unrestricted JCE policy files

 

These are the files that need to be replaced-  local_policy.jar and US_export_policy.jar files