Python proxy
- Python 100%
| Filename | Latest commit message | Latest commit date |
|---|---|---|
- Implement no-authentication SOCKS5 CONNECT handling for IPv4, IPv6, and domains - Parse and validate handler configuration, connector references, and listen uniqueness - Run configured listeners by default while preserving optional stdio TCP connect mode - Move Shadowsocks client streaming into the connector and accept parsed endpoints - Make callers own stream cleanup so relays close resources at the correct lifecycle boundary - Document SOCKS listener setup and add coverage for handlers, CLI, config, and streams |
||
| pyrox | ||
| tests | ||
| .gitignore | ||
| LICENSE | ||
| pyproject.toml | ||
| README.md | ||
Pyrox
Python proxy.
Config
[[connectors]]
name = "proxy"
type = "shadowsocks"
server = "127.0.0.1:8388"
method = "2022-blake3-aes-128-gcm"
password = "AAAAAAAAAAAAAAAAAAAAAA"
The 2022 methods expect password to be unpadded Base64-encoded key material of the method's exact key size.
SOCKS handler
Add a SOCKS5 listener that sends TCP CONNECT requests through a named connector:
[[handlers]]
listen = "127.0.0.1:1080"
type = "socks"
connector = "proxy"
Run the configured handlers with python -m pyrox --config proxy.toml. The SOCKS handler supports no-authentication TCP CONNECT requests for IPv4, IPv6, and domain targets.
TCP connect
The process connects stdin/stdout to a target through the named connector when --tcp-connect-target is specified:
python -m pyrox \
--config proxy.toml \
--tcp-connect-target example.com:443 \
--tcp-connect-with proxy
Development
Install the package and dependencies with python -m pip install ..
License
Apache 2.0. See the LICENSE file.