If it is not provided,Īuthentication will not be used (servers may accept unauthenticated requests). This parameter is ignored if an HTTP server is being used. For SOCKS4 servers, this parameter will be sent as the userid.
#Xpanel version 1.7.1 install password#
Username - For SOCKS5 servers, this allows simple username / password authentication Setting this to True with SOCKS4 servers actually use an extension to the protocol,Ĭalled SOCKS4a, which may not be supported on all servers (SOCKS5 and http serversĪlways support DNS). If it is set to False, DNS resolving will be preformed locally. If it is set to True, DNS resolving will be preformed remotely, on the server. Rdns - This is a boolean flag than modifies the behavior regarding DNS resolving. Defaults to 1080 for socks and 8080 for http. SOCKS4, SOCKS5, and HTTP are all aliases, respectively.Īddr - The IP address or DNS name of the proxy server. This can be one of three possibleĬhoices: PROXY_TYPE_SOCKS4, PROXY_TYPE_SOCKS5 and PROXY_TYPE_HTTP for SOCKS4, Proxy_type - The type of the proxy server. Syntax is: set_proxy(proxy_type, addr]]]) To select the proxy server you would like to use, use the set_proxy method, whose The socksocket class is derived from socket) with a few extra methods. The socksocket object has an interface which is very similiar to socket's (in fact Generally, it is best to initialize the socksocket object with no parameters > s = socks.socksocket() Type being either SOCK_STREAM or SOCK_DGRAM. Object to ensure maximal compatibility, however it should be noted that socksocket will only function with family being AF_INET and The socksocket object has the same initialization parameters as the normal socket The socks module provides a class called socksocket, which is the base to all of the module's functionality. USAGEįirst load the socks module with the command: > import socks Simply copy the file "socks.py" to your Python's lib/site-packages directory,Īnd you're ready to go. This module has been tested with Python 2.3 and should work with greater versions
#Xpanel version 1.7.1 install install#
These will install both the socks and sockshandler modules.Īlternatively, include just socks.py in your project. pip install / setup.py install will automatically install the sockshandler module. HTTP proxy client included but not supported or recommended (you should use urllib2's or requests' own HTTP proxy interface).UDP mostly supported (issues may occur in some edge cases).SOCKS proxy client for Python 2.7 and 3.4+.Seamlessly configure SOCKS proxies for any socket object by calling socket_t_proxy(). It is a modern fork of SocksiPy with bug fixes and extra features.Īcts as a drop-in replacement to the socket module. PySocks lets you send traffic through SOCKS and HTTP proxy servers.