File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -63,10 +63,15 @@ export class SQLiteCloudTlsConnection extends SQLiteCloudConnection {
6363 // connect to plain socket, without encryption, only if insecure parameter specified
6464 // this option is mainly for testing purposes and is not available on production nodes
6565 // which would need to connect using tls and proper certificates as per code below
66- const connectionOptions : net . SocketConnectOpts = {
66+ const connectionOptions = {
6767 host : config . host ,
68- port : config . port as number
68+ port : config . port as number ,
69+ // Server name for the SNI (Server Name Indication) TLS extension.
70+ // https://r2.nodejs.org/docs/v6.11.4/api/tls.html#tls_class_tls_tlssocket
71+ servername : config . host ,
72+ rejectUnauthorized : false
6973 }
74+
7075 this . socket = net . connect ( connectionOptions , ( ) => {
7176 console . warn ( `TlsConnection.connectTransport - connected to ${ config . host as string } :${ config . port as number } using insecure protocol` )
7277 // send initialization commands
You can’t perform that action at this time.
0 commit comments