MultiSocks
A SOCKS proxy that aggregates multiple remote SOCKS proxies, distributing traffic across them to increase overall bandwidth.
What MultiSocks Can Do
- Connection Distribution: Routes different TCP connections through different proxies using a round-robin or weighted load balancing approach
- Increased Total Bandwidth: Improves overall throughput for applications that make multiple concurrent connections
- Automatic Proxy Management: Handles failed or slow proxies by routing around them
- Dynamic Optimization: Automatically adjusts how many proxies to use based on your bandwidth needs
- Protocol Support: Works with SOCKS4, SOCKS4a, SOCKS5, and SOCKS5h protocols
- Detailed Logging: Provides visibility into proxy performance and connection routing
What MultiSocks Cannot Do
- True Channel Bonding: Cannot split a single TCP connection across multiple proxies (single-connection speeds won't increase)
- UDP Bonding: Does not currently support UDP traffic distribution
- Transport Layer Bonding: Doesn't combine connections at the packet level like MPTCP or VPN bonding solutions
- Custom Protocols: Only works with applications that support SOCKS proxy configuration
Ideal Use Cases
MultiSocks works best with:
- Web browsers (which open many connections to different resources)
- Download managers that support multiple connections
- Applications that establish multiple TCP connections
- Scenarios where anonymity through multiple exit points is desired
Features
- Supports multiple remote SOCKS proxies
- Round-robin or weighted load balancing
- Automatic handling of failed or slow proxies
- Support for SOCKS4, SOCKS4a, SOCKS5, and SOCKS5h protocols
- Detailed logging
- Load proxies from command line or text file
- Auto-optimization to dynamically adjust proxy usage based on bandwidth
Installation
From PyPI
pip install multisocks
From Source
git clone https://github.com/tboy1337/multisocks.git
cd multisocks
pip install -r requirements.txt
Usage
# Show help
multisocks --help
# Show version
multisocks --version
# Start the proxy server with multiple remote proxies specified on the command line
multisocks start --port 1080 --proxies socks5://user:pass@proxy1.example.com:1080/10 socks5h://proxy2.example.com:1080/5
# Start the proxy server with proxies loaded from a text file
multisocks start --port 1080 --proxy-file proxies.txt
# Start with auto-optimization (automatically adjusts how many proxies to use based on your connection speed)
multisocks start --port 1080 --proxy-file proxies.txt --auto-optimize
Proxy Format
Proxies are specified in the format: protocol://[username:password@]hostname:port[/weight]
protocol: Eithersocks4,socks4a,socks5, orsocks5husername:password: Optional authentication for SOCKS5/SOCKS5hhostname: The proxy server hostname or IP addressport: The proxy server portweight: Optional priority weight (default: 1)
Protocol Information
socks4: Basic SOCKS4 protocol with IP addresses onlysocks4a: Extended SOCKS4 with hostname resolution on the proxy serversocks5: SOCKS5 protocol with hostname resolution on the clientsocks5h: SOCKS5 protocol with hostname resolution on the proxy server (useful for avoiding DNS leaks)
Proxy File Format
You can specify proxies in a text file, with one proxy per line:
# This is a comment
socks5://user:pass@proxy1.example.com:1080/10
socks5h://proxy2.example.com:1080/5
socks4://proxy3.example.com:1080
- Empty lines are ignored
- Lines starting with
#are treated as comments and ignored
Auto-Optimization
When enabled with the --auto-optimize flag, MultiSocks will:
- Measure your direct connection speed
- Test the speed of your proxies
- Automatically determine how many proxies to use to saturate your connection
- Periodically adjust the active proxy count based on network conditions
This feature is especially useful when:
- You have a large list of proxies but don't want to manually configure how many to use
- Your internet connection speed varies throughout the day
- You want to maximize your connection bandwidth without manual tuning
Auto-optimization is re-evaluated every 10 minutes to adjust to changing network conditions.
Development
Setup Development Environment
git clone https://github.com/tboy1337/multisocks.git
cd multisocks
pip install -r requirements.txt
Run Tests
python -m unittest discover tests
License
This project is licensed under the CRL License - see the LICENSE.md file for details.
Metadata
Release files for multisocks 1.0.6
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| multisocks-1.0.6.tar.gz | 39.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| multisocks-1.0.6-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 59.9 kB
Release files / multisocks-1.0.6.tar.gz
| Download URL | multisocks-1.0.6.tar.gz |
|---|---|
| Size | 39.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
52a3bb15ca13881f0c1bad07498389a166da0f99221e407a1b2373cbd8fa44c7
|
|
BLAKE2b-256 checksum How to use checksums |
3ca05687b12327efb4c12b562addad0f9fe0e5ff5d162840e9b1401dc472fcce
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.11
|
Release files / multisocks-1.0.6-py3-none-any.whl
| Download URL | multisocks-1.0.6-py3-none-any.whl |
|---|---|
| Size | 20.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
1f1b5d3a9858859c30201b0a55f46571f496ad93299ba41f8e2bb40bf266d1b9
|
|
BLAKE2b-256 checksum How to use checksums |
201c7f9ae87a79fb114004f4eda9fc22d59b5d9a7a48d98c807a0adaeb13a2c1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.11
|