mirror of
https://github.com/http-party/node-http-proxy.git
synced 2025-12-08 20:59:18 +00:00
websocket needs to respect options.secure too
This commit is contained in:
parent
60bd697051
commit
d1eabccf93
@ -39,7 +39,7 @@ common.setupOutgoing = function(outgoing, options, req, forward) {
|
||||
extend(outgoing.headers, options.headers);
|
||||
}
|
||||
|
||||
if (options[forward || 'target'].protocol == 'https:') {
|
||||
if (~['https:', 'wss:'].indexOf(options[forward || 'target'].protocol)) {
|
||||
outgoing.rejectUnauthorized = (typeof options.secure === "undefined") ? true : options.secure;
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user