oracle / node-oracledb

Oracle Database driver for Node.js maintained by Oracle Corp.
http://oracle.github.io/node-oracledb/
Other
2.25k stars 1.07k forks source link

Error NJS-116: password versions not being checked properly. #1603

Closed lucastresc closed 1 year ago

lucastresc commented 1 year ago

I'm getting NJS-116 when connecting to oracle.

The docs says: "If you try to connect to any supported Oracle Database with node-oracledb Thin mode, but the user account is created only with the 10G password verifier, then the connection will fail with the following error: "NJS-116: password verifier type 0x939 is not supported by node-oracledb in Thin mode." - https://github.com/oracle/node-oracledb/blob/0b3485c8d4d885ffa625c1fb1ac3ef3f404f436f/doc/src/user_guide/appendix_a.rst#password-verifier-support

My oracle user has three password versions: 10G 11G 12C

Since it has 11G and 12C passwords already, it should not raise the error NJS-116. It looks like password versions are not being checked properly by this code:

https://github.com/oracle/node-oracledb/blame/0b3485c8d4d885ffa625c1fb1ac3ef3f404f436f/lib/thin/protocol/messages/auth.js#L206

cjbj commented 1 year ago

Check you have the other pre-condition met: the DB initialization parameter sec_case_sensitive_logon should not be FALSE. Also try regenerating your password just in case. We're doing some work on the Troubleshooting doc, but for the moment the similar "verifier type 0x939" error section near the end of https://python-oracledb.readthedocs.io/en/latest/user_guide/installation.html#runtime-error-troubleshooting might be more complete.

Muhammad-Usama-lab commented 1 year ago

any luck @lucastresc ? Same, I'm unable to resolve this issue.

sharadraju commented 1 year ago

@lucastresc @Muhammad-Usama-lab This has been discussed thoroughly in #1584. Please see the discussion https://github.com/oracle/node-oracledb/issues/1584#issuecomment-1702511642.

The 10G Password verifier has to be completely removed as it is not secure.

sharadraju commented 1 year ago

I am going to close this as an issue because it has been discussed extensivey in previous issues and discussions. 10G Password verifier has to be completely removed for thin mode for work.