Support Happy Eyeballs in proxy-agent
This commit is contained in:
parent
eae9e570fc
commit
56ba8fea4d
13 changed files with 419 additions and 289 deletions
12
patches/proxy-agent+6.3.0.patch
Normal file
12
patches/proxy-agent+6.3.0.patch
Normal file
|
@ -0,0 +1,12 @@
|
|||
diff --git a/node_modules/proxy-agent/dist/index.js b/node_modules/proxy-agent/dist/index.js
|
||||
index 885d22a..2930652 100644
|
||||
--- a/node_modules/proxy-agent/dist/index.js
|
||||
+++ b/node_modules/proxy-agent/dist/index.js
|
||||
@@ -29,6 +29,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.ProxyAgent = exports.proxies = void 0;
|
||||
const http = __importStar(require("http"));
|
||||
const https = __importStar(require("https"));
|
||||
+const { URL } = __importStar(require("url"));
|
||||
const lru_cache_1 = __importDefault(require("lru-cache"));
|
||||
const agent_base_1 = require("agent-base");
|
||||
const debug_1 = __importDefault(require("debug"));
|
22
patches/socks-proxy-agent+8.0.1.patch
Normal file
22
patches/socks-proxy-agent+8.0.1.patch
Normal file
|
@ -0,0 +1,22 @@
|
|||
diff --git a/node_modules/socks-proxy-agent/dist/index.js b/node_modules/socks-proxy-agent/dist/index.js
|
||||
index 8189e01..e2dedf8 100644
|
||||
--- a/node_modules/socks-proxy-agent/dist/index.js
|
||||
+++ b/node_modules/socks-proxy-agent/dist/index.js
|
||||
@@ -33,6 +33,7 @@ const debug_1 = __importDefault(require("debug"));
|
||||
const dns = __importStar(require("dns"));
|
||||
const net = __importStar(require("net"));
|
||||
const tls = __importStar(require("tls"));
|
||||
+const { URL } = __importStar(require("url"));
|
||||
const debug = (0, debug_1.default)('socks-proxy-agent');
|
||||
function parseSocksURL(url) {
|
||||
let lookup = false;
|
||||
@@ -127,6 +128,9 @@ class SocksProxyAgent extends agent_base_1.Agent {
|
||||
},
|
||||
command: 'connect',
|
||||
timeout: timeout ?? undefined,
|
||||
+ socket_options: {
|
||||
+ lookup: lookupFn,
|
||||
+ },
|
||||
};
|
||||
const cleanup = (tlsSocket) => {
|
||||
req.destroy();
|
Loading…
Add table
Add a link
Reference in a new issue