1

The setup is simple:

  • bc-fips-1.0.0.jar and bcpkix-fips-1.0.0.jar for the security provider
  • oracle jdbc driver version 12.1.0.2
  • server: Oracle Database 12c Standard Edition 12.1.0.2.0

The application:

Security.addProvider(new BouncyCastleFipsProvider());
Class.forName("oracle.jdbc.driver.OracleDriver");
Connection connection = DriverManager.getConnection("jdbc:oracle:thin:@host:1521:db","user","pass");
connection.close();

The exception:

java.sql.SQLException: ORA-01005: null password given; logon denied

at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:450)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:392)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:385)
at oracle.jdbc.driver.T4CTTIfun.processError(T4CTTIfun.java:1018)
at oracle.jdbc.driver.T4CTTIoauthenticate.processError(T4CTTIoauthenticate.java:501)
at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:522)
at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:257)
at oracle.jdbc.driver.T4CTTIoauthenticate.doOAUTH(T4CTTIoauthenticate.java:437)
at oracle.jdbc.driver.T4CTTIoauthenticate.doOAUTH(T4CTTIoauthenticate.java:954)
at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:639)
at oracle.jdbc.driver.PhysicalConnection.connect(PhysicalConnection.java:666)
at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:32)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:566)
at java.sql.DriverManager.getConnection(DriverManager.java:664)
at java.sql.DriverManager.getConnection(DriverManager.java:247)
at Main.main(Main.java:56)

Any idea?

Andrei Matei
  • 1,049
  • 2
  • 10
  • 23
  • What is the relationship with bouncycastle ? – Egl Feb 22 '17 at 14:07
  • well, I can't really tell, but it's the only thing that I add to the code and it fails. I can't see the whole picture – Andrei Matei Feb 22 '17 at 14:49
  • Have you tried -Doracle.jdbc.thinLogonCapability=o3 as pointed in http://stackoverflow.com/questions/38609280/java-sql-sqlexception-ora-01005-null-password-given-logon-denied ? – Egl Feb 22 '17 at 18:39
  • thanks for the tip, but now it fails with: "java.sql.SQLException: ORA-28040: No matching authentication protocol" – Andrei Matei Feb 24 '17 at 08:22

1 Answers1

0

In the meantime, we found that the error occurs only using the version 12.1.0.2 of the JDBC driver.

Version 12.1.0.1 works fine!

Andrei Matei
  • 1,049
  • 2
  • 10
  • 23