Skip to content

Commit 83a6138

Browse files
authored
Merge pull request #1872 from johndevedu/master
feat: maxVersion ssl option to tls.createSecureContext
2 parents 7efd5ce + 0c40ef9 commit 83a6138

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

lib/connection.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,8 @@ class Connection extends EventEmitter {
347347
ciphers: this.config.ssl.ciphers,
348348
key: this.config.ssl.key,
349349
passphrase: this.config.ssl.passphrase,
350-
minVersion: this.config.ssl.minVersion
350+
minVersion: this.config.ssl.minVersion,
351+
maxVersion: this.config.ssl.maxVersion
351352
});
352353
const rejectUnauthorized = this.config.ssl.rejectUnauthorized;
353354
const verifyIdentity = this.config.ssl.verifyIdentity;

typings/mysql/lib/Connection.d.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -228,6 +228,11 @@ declare namespace Connection {
228228
*/
229229
minVersion?: string;
230230

231+
/**
232+
* Configure the maximum supported version of SSL, the default is TLSv1.3.
233+
*/
234+
maxVersion?: string;
235+
231236
/**
232237
* You can verify the server name identity presented on the server certificate when connecting to a MySQL server.
233238
* You should enable this but it is disabled by default right now for backwards compatibility.

0 commit comments

Comments
 (0)