feat(Microsoft SQL Node): Add support for self signed certificates (#5160)

This commit is contained in:
Jon 2023-03-09 10:05:03 +00:00 committed by GitHub
parent 5b9c521d04
commit 971d5ae8f5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 0 deletions

View file

@ -53,6 +53,13 @@ export class MicrosoftSql implements ICredentialType {
type: 'boolean',
default: true,
},
{
displayName: 'Ignore SSL Issues',
name: 'allowUnauthorizedCerts',
type: 'boolean',
default: false,
description: 'Whether to connect even if SSL certificate validation is not possible',
},
{
displayName: 'Connect Timeout',
name: 'connectTimeout',

View file

@ -235,6 +235,8 @@ export class MicrosoftSql implements INodeType {
options: {
encrypt: credentials.tls as boolean,
enableArithAbort: false,
tdsVersion: credentials.tdsVersion as string,
trustServerCertificate: credentials.allowUnauthorizedCerts as boolean,
},
};
const pool = new mssql.ConnectionPool(config);
@ -269,6 +271,7 @@ export class MicrosoftSql implements INodeType {
encrypt: credentials.tls as boolean,
enableArithAbort: false,
tdsVersion: credentials.tdsVersion as string,
trustServerCertificate: credentials.allowUnauthorizedCerts as boolean,
},
};