TooTallNate / proxy-agents

Node.js HTTP Proxy Agents Monorepo
https://proxy-agents.n8.io
872 stars 229 forks source link

localAddress settings doesn't work #263

Open Atheryl opened 7 months ago

Atheryl commented 7 months ago

Hi,

Tried the CLI

 npx proxy@1 -l 192.168.0.40
 HTTP(s) proxy server listening on port 3128

Still going through the primary interface set in the OS.

I also tried through to understand how to proceed through the code, but the documentation is minimalistic to say the least https://github.com/TooTallNate/proxy-agents/tree/main/packages/proxy

Has anyone succeeded in getting either way to re-route the traffic through a specific network interface?

erickythierry commented 2 months ago

I did a test here using IPv6 and it worked.

I was looking for a project like this for a few days and only this one worked as I wanted. I added 2 different IPv6s to a VPS and wanted to use them both as an outgoing interface.

I ran the command npx proxy@1 --port 8080 -l *ipv6Addr* and curl requests were being proxied by the defined ip.

I only tested it with IPv6, as it is free to add to the VPS