Giter Site home page Giter Site logo

zu1k / http-proxy-ipv6-pool Goto Github PK

View Code? Open in Web Editor NEW
458.0 8.0 77.0 22 KB

Make every request from a separate IPv6 address.

Home Page: https://zu1k.com/posts/tutorials/http-proxy-ipv6-pool/

License: MIT License

Rust 100.00%
proxypool http-proxy ipv6

http-proxy-ipv6-pool's Introduction

Http Proxy IPv6 Pool

Make every request from a separate IPv6 address.

https://zu1k.com/posts/tutorials/http-proxy-ipv6-pool/

Tutorial

Assuming you already have an entire IPv6 subnet routed to your server, for me I purchased Vultr's server to get one.

Get your IPv6 subnet prefix and interface name, for me is 2001:19f0:6001:48e4::/64 and enp1s0.

$ ip a
......
2: enp1s0: <BROADCAST,MULTICAST,ALLMULTI,UP,LOWER_UP> mtu 1500 qdisc fq state UP group default qlen 1000
    ......
    inet6 2001:19f0:6001:48e4:5400:3ff:fefa:a71d/64 scope global dynamic mngtmpaddr 
       valid_lft 2591171sec preferred_lft 603971sec
    ......

Add route via default internet interface

ip route add local 2001:19f0:6001:48e4::/64 dev enp1s0

Open ip_nonlocal_bind for binding any IP address:

sysctl net.ipv6.ip_nonlocal_bind=1

For IPv6 NDP, install ndppd:

apt install ndppd

then edit /etc/ndppd.conf:

route-ttl 30000

proxy <INTERFACE-NAME> {
    router no
    timeout 500
    ttl 30000

    rule <IP6_SUBNET> {
        static
    }
}

(edit the file to match your configuration)

Restart the service:

service ndppd restart

Now you can test by using curl:

$ curl --interface 2001:19f0:6001:48e4::1 ipv6.ip.sb
2001:19f0:6001:48e4::1

$ curl --interface 2001:19f0:6001:48e4::2 ipv6.ip.sb
2001:19f0:6001:48e4::2

Great!

Finally, use the http proxy provided by this project:

$ while true; do curl -x http://127.0.0.1:51080 ipv6.ip.sb; done
2001:19f0:6001:48e4:971e:f12c:e2e7:d92a
2001:19f0:6001:48e4:6d1c:90fe:ee79:1123
2001:19f0:6001:48e4:f7b9:b506:99d7:1be9
2001:19f0:6001:48e4:a06a:393b:e82f:bffc
2001:19f0:6001:48e4:245f:8272:2dfb:72ce
2001:19f0:6001:48e4:df9e:422c:f804:94f7
2001:19f0:6001:48e4:dd48:6ba2:ff76:f1af
2001:19f0:6001:48e4:1306:4a84:570c:f829
2001:19f0:6001:48e4:6f3:4eb:c958:ddfa
2001:19f0:6001:48e4:aa26:3bf9:6598:9e82
2001:19f0:6001:48e4:be6b:6a62:f8f7:a14d
2001:19f0:6001:48e4:b598:409d:b946:17c

Author

Http Proxy IPv6 Pool © zu1k, Released under the MIT License.

http-proxy-ipv6-pool's People

Contributors

hackermondev avatar interfect avatar zu1k avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

http-proxy-ipv6-pool's Issues

RTNETLINK answers: File exists

With vultr server ,when enter the following command:
ip route add local 2001:19f0:6001:48e4::/64 dev enp1s0
i get "RTNETLINK answers: File exists" and why??

[Feature request] Auth

Hey, first of all I'd like to thank you for making this - it's great.
I wanted to ask if it's possible to add authentication to this proxy? Like username & password.

`eth0` in /etc/ndppd.conf is a mistake.

eth0 in /etc/ndppd.conf is a mistake.

route-ttl 30000

proxy eth0 {
    router no
    timeout 500
    ttl 30000

    rule 2001:19f0:6001:48e4::/64 {
        static
    }
}

change eth0 to enp1s0!

Unable to do apt update or apt install

After i did the ip route and stuff. i can no longer do apt update or apt install

Do you want to continue? [Y/n] y
Ign:1 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 linux-libc-dev amd64 5.4.0-122.138
Err:1 http://security.ubuntu.com/ubuntu focal-updates/main amd64 linux-libc-dev amd64 5.4.0-122.138
404 Not Found [IP: 2001:67c:1562::15 80]
Unable to correct missing packages.
E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/l/linux/linux-libc-dev_5.4.0-122.138_amd64.deb 404 Not Found [IP: 2001:67c:1562::15 80]
E: Aborting install.

anyway to fix this?

Question

Is there a way to not have the origin servers ip address be shown to the website (target host) if they do not support ipv4, instead throw an error?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.