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

Is it possible to use it with msnodesqlv8 and Windows Authentication? (Trusted Connection) #56

Open
ITSNOTSTUPIDIFITWORKS opened this issue May 23, 2022 · 4 comments
Labels
enhancement New feature or request

Comments

@ITSNOTSTUPIDIFITWORKS
Copy link

How can i use Windows Authentication. (Trusted Connection)?

@ITSNOTSTUPIDIFITWORKS ITSNOTSTUPIDIFITWORKS added the enhancement New feature or request label May 23, 2022
@JLuboff
Copy link
Owner

JLuboff commented May 26, 2022

There is currently no plans in place to implement the use of the msnodesqlv8 driver.
Looking at the mssql docs on msnodesqlv8 driver, it looks like it would require a decent rewrite or a separate class to implement as all imports will need to be changed.

We are open to contributions if you'd like to work this out. I am no longer working with MS SQL so any new features may not be implemented or at least not in a timely fashion from myself. I will still be doing my best to keep packages up to date which do not introduce breaking changes.

@bommulurianji2
Copy link

Expected behavior:

The Node.js application should connect to the MS SQL server on a internal environment with the development account using the Kerberos authentication scheme.

Actual behavior:

The Node.js application is not connecting to the MS SQL server on internal environment with the development account using the Kerberos authentication scheme.

I don't find a way to mention the scheme and the relevant drivers..

for example : authPlugins: {
authentication_kerberos_client: plugins.authentication_kerberos_client()

Configuration:

currently using something like this which is working in terms of connection, But when we add the development id not working..

----working sample ------
const sql = require("msnodesqlv8");

const connectionString = "server=.;Database=Master;Trusted_Connection=Yes;Driver={SQL Server Native Client 11.0}";
const query = "SELECT name FROM sys.databases";

sql.query(connectionString, query, (err, rows) => {
console.log(rows);
});
----Not working sample ------

const sql = require("msnodesqlv8");

const connectionString = "server=.;Database=Master;User=developmentID;Trusted_Connection=Yes;Driver={SQL Server Native Client 11.0}";
const query = "SELECT name FROM sys.databases";

sql.query(connectionString, query, (err, rows) => {
console.log(rows);
})

Software versions

NodeJS: Node 18.15.0

node-mssql:msnodesqlv8

SQL Server:SQL Server 2019

@bommulurianji2
Copy link

Any idea we have Kerberos as authentication scheme that can be used?

@JLuboff
Copy link
Owner

JLuboff commented Jun 5, 2023

@bommulurianji2
Are you having this issue in this package, connect-mssql-v2 or are you trying to use mssql package? The references above seems to be to mssql and not to this package connect-mssql-v2. The connect-mssql-v2 package is specifically for managing sessions via express-session

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants