Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SQL Server NTLM Authentication does not work since DBeaver 23.2.0 (The login is from an untrusted domain) #33196

Open
cppelf opened this issue May 17, 2024 · 1 comment

Comments

@cppelf
Copy link

cppelf commented May 17, 2024

Description

After an upgrade of DBeaver I got the following error message when trying to connect to SQL Server via NTLM Authentication:
"Connection to 'xxxx' cannot be established. Reason: Login failed. The login is from an untrusted domain and cannot be used with Integrated authentication. ClientConnectionId:xxx"

  • With DBeaver 23.1.5 the connection works.
  • With DBeaver 23.2.0 the connection does not work anymore. I tried a few newer versions, including also EA 24.0.5. Same error message.

It is not related to the SQL Driver. Same behaviour with different drivers: 9.2 or 11.2.3 or 12.4 I get the same error message or success depending on the version of DBeaver.
If I downgrade to 23.1.5 or an earlier version, then it works.
I tried several versions after 23.2.0 and they all gave the error message.

Client:

  • Windows 10 Pro (different PCs).

Server:

  • Windows Server 2019
  • SQL Server 2017

Error:
DBeaverError

Success:
DBeaver 23 1 5
DBeaver 23 0 0

Driver:

DBeaver Properties
SQLDrivers

Attached full Logs (Asterisks on sensitive data).

When doing a Diff on the Logs I noticed that in the error logs there is the following additional line:
Framework arguments: -eclipse.keyring C:\Users*******\AppData\Roaming\DBeaverData\secure\secure_storage

And this line is missing in the debug error log:
Start Equinox Java Authentication and Authorization Service (JAAS) [org.eclipse.equinox.security 1.3.1000.v20220801-1135]

Diff Log
Diff Debug Error
error__.log
success__.log
error__dbeaver-debug.log
success__dbeaver-debug.log

DBeaver Version

24.0.5 (issue since 23.2.0, ok with 23.1.5)

Operating System

Client: Windows 10, Server: Windows Server 2019 + SQL Server 2017

Database and driver

Driver:

  • mssql-jdbc-9.2.0.jre8.jar OR mssql-jdbc-12.4.1.jre11.jar

Connection Properties:
Host: IP Address
Port: 1433
Authentication: NTLM
Username: ***
Password: ***

Override following Driver Properties:

  • trustServerCertificate: true

Added following Driver Properties / User Properties:

  • Domain: **** (our Domain)
  • Password: **** (my Password)
  • User: ${user}

Steps to reproduce

I try to connect to the database. Error: "Connection to 'xxx' cannot be established. Reason: Login failed. The login is from an untrusted domain and cannot be used with Integrated authentication. ClientConnectionId:xxx"

Additional context

No response

@cppelf cppelf changed the title SQL Server NTLM Authentication does not work since DBeaver 23.0.2.0 (The login is from an untrusted domain) SQL Server NTLM Authentication does not work since DBeaver 23.2.0 (The login is from an untrusted domain) May 17, 2024
@E1izabeth
Copy link
Member

E1izabeth commented May 17, 2024

Thank you for report.
Seems integratedSecurity=true driver property cause this for you https://stackoverflow.com/questions/18603696/trouble-connecting-to-sql-server-login-failed-the-login-is-from-an-untrusted-d
We set it to true before connect here

@E1izabeth E1izabeth added this to the 24.1.2 milestone May 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants