Merge pull request #7238 from rogierschouten/node-tls-opts

Add host and port to TlsOptions struct
This commit is contained in:
Horiuchi_H
2015-12-22 19:13:24 +09:00
2 changed files with 9 additions and 0 deletions
+7
View File
@@ -198,6 +198,13 @@ var ctx: tls.SecureContext = tls.createSecureContext({
});
var blah = ctx.context;
var tlsOpts: tls.TlsOptions = {
host: "127.0.0.1",
port: 55
};
var tlsSocket = tls.connect(tlsOpts);
////////////////////////////////////////////////////
// Make sure .listen() and .close() retuern a Server instance
+2
View File
@@ -1535,6 +1535,8 @@ declare module "tls" {
var CLIENT_RENEG_WINDOW: number;
export interface TlsOptions {
host?: string;
port?: number;
pfx?: any; //string or buffer
key?: any; //string or buffer
passphrase?: string;