For maven users
If your project using maven, then you need to change in pom.xml
Use the ojdbc6.jar/ojdbc7.jar
instead of ojdbc14.jar
Use one of the following jars in your pom.xml as dependency.
<!-- ojdbc6.jar example -->
<dependency>
<groupId>com.oracle</groupId>
<artifactId>ojdbc6</artifactId>
<version>11.2.0</version>
</dependency>
OR,
<!-- ojdbc7.jar example -->
<dependency>
<groupId>com.oracle</groupId>
<artifactId>ojdbc7</artifactId>
<version>12.1.0.2</version>
</dependency>
Remove the following dependency from your pom.xml
<!-- https://mvnrepository.com/artifact/com.oracle/ojdbc14 -->
<dependency>
<groupId>com.oracle</groupId>
<artifactId>ojdbc14</artifactId>
<version>10.2.0.2.0</version>
</dependency>
For gradle users
Use the dependency in your build.gradle
// https://mvnrepository.com/artifact/oracle/ojdbc6
compile group: 'oracle', name: 'ojdbc6', version: '11.2.0.3'
or
// https://mvnrepository.com/artifact/cn.easyproject/ojdbc7
compile group: 'cn.easyproject', name: 'ojdbc7', version: '12.1.0.2.0'
Remove the dependency from your build.gradle
// https://mvnrepository.com/artifact/com.oracle/ojdbc14
compile group: 'com.oracle', name: 'ojdbc14', version: '10.2.0.2.0'
Resource Link:
https://blogs.oracle.com/dev2dev/entry/oracle_maven_repository_instructions_for
Add the following in oracle/network/admin/sqlnet.ora
file :
SQLNET.ALLOWED_LOGON_VERSION=8
SQLNET.ALLOWED_LOGON_VERSION_CLIENT=8
SQLNET.ALLOWED_LOGON_VERSION_SERVER=8
Why you will use 8?
Bug 14575666
In 12.1, the default value for the SQLNET.ALLOWED_LOGON_VERSION
parameter has been updated to 11. This means that database clients
using pre-11g JDBC thin drivers cannot authenticate to 12.1 database
servers unless theSQLNET.ALLOWED_LOGON_VERSION parameter is set to the
old default of 8.
This will cause a 10.2.0.5 Oracle RAC database creation using DBCA to
fail with the ORA-28040: No matching authentication protocol error in
12.1 Oracle ASM and Oracle Grid Infrastructure environments.
Workaround: Set SQLNET.ALLOWED_LOGON_VERSION=8
in the
oracle/network/admin/sqlnet.ora file.
Resource Link:
- ORA-28040: No matching authentication protocol exception
- https://stackoverflow.com/a/26629916/2293534
If 8 does not work then,
Prior to version 12c the default setting for
SQLNET.ALLOWED_LOGON_VERSION (the equivalent parameter prior to 12c)
was 8 .
In 12c the default is now 11.
Resource Link:
http://www.redstk.com/ora-28040-no-matching-authentication-protocol-after-upgrade-to-12c/