mirror of
https://github.com/nodejs/node.git
synced 2026-11-27 17:52:27 -05:00
tls: forward new SecureContext options
We have a few places where we individually forward each parameter to tls.createSecureContext(). In #28973 and others, we added new SecureContext options but forgot to keep these places up to date. As per https.Agent#getName, I understand that at least `privateKeyIdentifier` and `privateKeyEngine` should be added too, since they're a substitute for `key`. I've also added sigalgs. Fixes: https://github.com/nodejs/node/issues/36322 Refs: https://github.com/nodejs/node/pull/28973 PR-URL: https://github.com/nodejs/node/pull/36416 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com>
This commit is contained in:
1 parent
3701e5d14f
commit
08ed2337ea
3 files changed
+31
-4
No files matched your search
@@ -12,7 +12,7 @@ const agent = new https.Agent();
|
||||
// empty options
|
||||
assert.strictEqual(
|
||||
agent.getName({}),
|
||||
'localhost:::::::::::::::::::'
|
||||
'localhost::::::::::::::::::::::'
|
||||
);
|
||||
|
||||
// Pass all options arguments
|
||||
@@ -34,11 +34,15 @@ const options = {
|
||||
secureOptions: 0,
|
||||
secureProtocol: 'secureProtocol',
|
||||
servername: 'localhost',
|
||||
sessionIdContext: 'sessionIdContext'
|
||||
sessionIdContext: 'sessionIdContext',
|
||||
sigalgs: 'sigalgs',
|
||||
privateKeyIdentifier: 'privateKeyIdentifier',
|
||||
privateKeyEngine: 'privateKeyEngine',
|
||||
};
|
||||
|
||||
assert.strictEqual(
|
||||
agent.getName(options),
|
||||
'0.0.0.0:443:192.168.1.1:ca:cert:dynamic:ciphers:key:pfx:false:localhost:' +
|
||||
'::secureProtocol:c,r,l:false:ecdhCurve:dhparam:0:sessionIdContext'
|
||||
'::secureProtocol:c,r,l:false:ecdhCurve:dhparam:0:sessionIdContext:' +
|
||||
'"sigalgs":privateKeyIdentifier:privateKeyEngine'
|
||||
);
|
||||
Reference in new issue
Block a user