Discussions
Categories
- 385.5K All Categories
- 5.1K Data
- 2.5K Big Data Appliance
- 2.5K Data Science
- 453.4K Databases
- 223.2K General Database Discussions
- 3.8K Java and JavaScript in the Database
- 47 Multilingual Engine
- 606 MySQL Community Space
- 486 NoSQL Database
- 7.9K Oracle Database Express Edition (XE)
- 3.2K ORDS, SODA & JSON in the Database
- 585 SQLcl
- 4K SQL Developer Data Modeler
- 188K SQL & PL/SQL
- 21.5K SQL Developer
- 46 Data Integration
- 46 GoldenGate
- 298.4K Development
- 4 Application Development
- 20 Developer Projects
- 166 Programming Languages
- 295K Development Tools
- 150 DevOps
- 3.1K QA/Testing
- 646.7K Java
- 37 Java Learning Subscription
- 37.1K Database Connectivity
- 201 Java Community Process
- 108 Java 25
- 22.2K Java APIs
- 138.3K Java Development Tools
- 165.4K Java EE (Java Enterprise Edition)
- 22 Java Essentials
- 176 Java 8 Questions
- 86K Java Programming
- 82 Java Puzzle Ball
- 65.1K New To Java
- 1.7K Training / Learning / Certification
- 13.8K Java HotSpot Virtual Machine
- 94.3K Java SE
- 13.8K Java Security
- 208 Java User Groups
- 25 JavaScript - Nashorn
- Programs
- 667 LiveLabs
- 41 Workshops
- 10.3K Software
- 6.7K Berkeley DB Family
- 3.6K JHeadstart
- 6K Other Languages
- 2.3K Chinese
- 207 Deutsche Oracle Community
- 1.1K Español
- 1.9K Japanese
- 474 Portuguese
SQLcl and integrated Windows authentication
Is it possible to configure SQLcl to use integrated Windows authentication?
Ihave some DBs with everything configured properly and I can login with sqlplus with the following
> sqlplus /@<TNS_ENTRY>
with no issues.
SQLcl works fine for standard DB user login to the same server but if I issue
> sql /@<TNS_ENTRY>
I get back the following error string:
USER =
URL = jdbc:oracle:oci8:@<TNS_ENTRY>
Error Message = no ocijdbc18 in java.library.path
USER =
URL = jdbc:oracle:thin:@(DESCRIPTION = (ADDRESS = (PROTOCOL = TCP) (HOST = <HOST>) (PORT = 1521) ) (CONNECT_DATA = (SERVICE_NAME = <SERVICE>) ) )
Error Message = ORA-01017: invalid username/password; logon denied
Any insight, comments or configuration suggestions would be appreciated. Thanks,
Answers
-
-
Thanks, I'll take a look and see if that helps out.
-
hwsbry wrote:Is it possible to configure SQLcl to use integrated Windows authentication? Ihave some DBs with everything configured properly and I can login with sqlplus with the following
Re-reading this, it would be very helpful if you supplied answers to the following:
. What do you actually mean by "integrated Windows authentication"?
. How have you configured the users? Please show your setup of a user.
. What Oracle documentation, specificallly, did you follow to get "everything configured properly"?
. What is your database version, to 4 significant digits ("select * from v$version;")?
. What is the output of:
> sql -verbose /@<TNS_ENTRY>
The error you are getting looks like it is due to sqlcl not being able to find the Oracle OCI libraries required for OS authentication.
Make sure OCI libraries are accessible from sqlcl.
-
Thanks for trying to help out Gaz. I'll just say that it turned out that the issue lay with my command line of choice and not any of my configurations. I'm currently using MobaXterm for pretty much all of my command line interactions and it turned out that my issue lay in the fact that the session I built for SQLcl did not retain the Windows PATH environment. I will try to answer your questions in case something similar occurs for other users though.
- To me, integrated Windows authentication, IWA, means that I can pass my Windows login to the Oracle database and be authenticated.
- User is configured
- create user "[email protected]" identified externally;
- grant create session to "[email protected]";
- Used the Oracle 12.2 DB security guide. Specifically the section for configuring Kerberos authentication.
- 12.2.0.1
- I won't go into the verbose output as everything is working.
Thanks again for your help and I think your final consensus that the OCI libraries is supported by the fact that I do indeed have a traditional client install with the bin in my PATH and once I configured MobaXterm to pay attention to that everything works as expected.
-
What you call Windows authentication is called OS Authentication in Oracle. It does work with sqlplus but in SQLcl it is not possible to use OS Authentication.
Instead you should try to use Wallet authentication with SQLcl. Here is an example: