jcaponigro20/simple-socks5

By jcaponigro20

Updated 6 months ago

A simple and fully-compliant SOCKS Protocol Version 5 server written in Python

Image
Networking
1

10K+

jcaponigro20/simple-socks5 repository overview

Simple Socks Proxy Server

Introduction

This is a simple SOCKS Protocol Version 5 server written in Python. It is based on the SOCKS V5 protocol described in RFC1928 and RFC1929.

Features
  • Concurrent Connections: Supports multiple simultaneous client connections.
  • Performance Optimized: Efficient handling of large data transfers.
  • Protocol Compliance: Fully compliant with RFC1928 and RFC1929 for basic functionalities.
Repository
Requirements
  • Python 3.10 or above
  • Only standard Python libraries are used. No additional dependencies are required.
Usage
python3 app.py [--host HOST | -H HOST] [--port PORT | -P PORT] [--logging-level LEVEL | -L LEVEL]
  • --host HOST or -H HOST: The host address to bind to. Default is localhost. Use 0.0.0.0 to bind to all available interfaces.
  • --port PORT or -P PORT: The port number to bind to. Default is 9999.
  • --logging-level LEVEL or -L LEVEL: The logging level for the application. Default is debug. Choices: ["disabled", "debug", "info", "warning", "error", "critical"]
  • The image automatically runs CMD ["python", "app.py", "--host", "0.0.0.0", "--port", "1080", "-L", "debug"] on startup.
RFC 1928 & RFC 1929 Compliance
Covered Aspects
  • Connections: Supports both TCP and UDP-based client applications.
  • Authentication: Supports username/password authentication method (RFC 1929), including failure handling.
  • Connection Requests: Handles SOCKS5 connection requests including parsing and responding to the VER, CMD, RSV, ATYP, DST.ADDR, and DST.PORT fields.
  • Address Types: Supports IPv4, IPv6 and domain name address types.
  • Reply Handling: Generates replies to the SOCKS5 requests based on different scenarios (success, general SOCKS server failure, connection refused, etc.).
Not Covered Aspects
  • BIND Command: Although the BIND command is recognized, it's not supported in the current implementation.
  • Fragmentation in UDP: The current implementation does not support fragmentation in UDP.
  • GSSAPI Authentication: The GSSAPI authentication method (RFC 1961) is not implemented.
Security Considerations
  • Data Encryption: The current implementation does not include data encryption for the transmission of data through the proxy. Data, including username and password for authentication, is transmitted in cleartext.
  • Recommendation for Secure Environments: Additional security measures are recommended for use in environments where data interception is a risk.

Tag summary

Content type

Image

Digest

sha256:cb8d38d22

Size

42.8 MB

Last updated

6 months ago

docker pull jcaponigro20/simple-socks5