Auto_Tor_IP_changer icon indicating copy to clipboard operation
Auto_Tor_IP_changer copied to clipboard

socks.GeneralProxyError: Socket error: SOCKS5 proxy server sent invalid data.

Open Marietto2008 opened this issue 1 year ago • 2 comments

I'm running Ubuntu 23.10 and I'm trying to make your script to work...

     /\        | |        |__   __|
    /  \  _   _| |_ ___      | | ___  _ __
   / /\ \| | | | __/ _ \     | |/ _ \| '__|
  / ____ \ |_| | || (_) |    | | (_) | |
 /_/    \_\__,_|\__\___/     |_|\___/|_|
                V 2.1
from mrFD

 http://facebook.com/ninja.hackerz.kurdish/

 change your  SOCKES to 127.0.0.1:9050 

[+] time to change Ip in Sec [type=60] >> 30
[+] how many time do you want to change your ip [type=1000]for infinte ip change type [0] >>0
Traceback (most recent call last):
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/socks.py", line 809, in connect
    negotiate(self, dest_addr, dest_port)
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/socks.py", line 443, in _negotiate_SOCKS5
    self.proxy_peername, self.proxy_sockname = self._SOCKS5_request(
                                               ^^^^^^^^^^^^^^^^^^^^^
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/socks.py", line 475, in _SOCKS5_request
    raise GeneralProxyError(
socks.GeneralProxyError: SOCKS5 proxy server sent invalid data

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/urllib3/contrib/socks.py", line 112, in _new_conn
    conn = socks.create_connection(
           ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/socks.py", line 209, in create_connection
    raise err
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/socks.py", line 199, in create_connection
    sock.connect((remote_host, remote_port))
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/socks.py", line 47, in wrapper
    return function(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/socks.py", line 814, in connect
    raise GeneralProxyError("Socket error", error)
socks.GeneralProxyError: Socket error: SOCKS5 proxy server sent invalid data

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/urllib3/connectionpool.py", line 790, in urlopen
    response = self._make_request(
               ^^^^^^^^^^^^^^^^^^^
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/urllib3/connectionpool.py", line 491, in _make_request
    raise new_e
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/urllib3/connectionpool.py", line 467, in _make_request
    self._validate_conn(conn)
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/urllib3/connectionpool.py", line 1096, in _validate_conn
    conn.connect()
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/urllib3/connection.py", line 611, in connect
    self.sock = sock = self._new_conn()
                       ^^^^^^^^^^^^^^^^
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/urllib3/contrib/socks.py", line 143, in _new_conn
    raise NewConnectionError(
urllib3.exceptions.NewConnectionError: <urllib3.contrib.socks.SOCKSHTTPSConnection object at 0x7f3e323ea350>: Failed to establish a new connection: SOCKS5 proxy server sent invalid data

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/requests/adapters.py", line 486, in send
    resp = conn.urlopen(
           ^^^^^^^^^^^^^
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/urllib3/connectionpool.py", line 844, in urlopen
    retries = retries.increment(
              ^^^^^^^^^^^^^^^^^^
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/urllib3/util/retry.py", line 515, in increment
    raise MaxRetryError(_pool, url, reason) from reason  # type: ignore[arg-type]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
urllib3.exceptions.MaxRetryError: SOCKSHTTPSConnectionPool(host='www.myexternalip.com', port=443): Max retries exceeded with url: /raw (Caused by NewConnectionError('<urllib3.contrib.socks.SOCKSHTTPSConnection object at 0x7f3e323ea350>: Failed to establish a new connection: SOCKS5 proxy server sent invalid data'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/share/aut/autoTOR.py", line 77, in <module>
    change()
  File "/usr/share/aut/autoTOR.py", line 48, in change
    print ('[+] Your IP has been Changed to : '+str(ma_ip()))
                                                    ^^^^^^^
  File "/usr/share/aut/autoTOR.py", line 43, in ma_ip
    get_ip= requests.get(url,proxies=dict(http='socks5://127.0.0.1:9050',https='socks5://127.0.0.1:9050'))
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/requests/api.py", line 73, in get
    return request("get", url, params=params, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/requests/api.py", line 59, in request
    return session.request(method=method, url=url, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/requests/sessions.py", line 589, in request
    resp = self.send(prep, **send_kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/requests/sessions.py", line 703, in send
    r = adapter.send(request, **kwargs)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ziomario/Scaricati/Auto_Tor_IP_changer/.venv/lib/python3.11/site-packages/requests/adapters.py", line 519, in send
    raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: SOCKSHTTPSConnectionPool(host='www.myexternalip.com', port=443): Max retries exceeded with url: /raw (Caused by NewConnectionError('<urllib3.contrib.socks.SOCKSHTTPSConnection object at 0x7f3e323ea350>: Failed to establish a new connection: SOCKS5 proxy server sent invalid data'))


Marietto2008 avatar Jan 22 '24 20:01 Marietto2008

Set Manual proxy configuration

  1. Go to your Browser Setting

Screenshot at 2024-02-13 18-22-35

  1. Click General

Screenshot at 2024-02-13 18-23-46

  1. And its time to set network manually Screenshot at 2024-02-13 18-20-39


                _          _______
     /\        | |        |__   __|
    /  \  _   _| |_ ___      | | ___  _ __
   / /\ \| | | | __/ _ \     | |/ _ \| '__|
  / ____ \ |_| | || (_) |    | | (_) | |
 /_/    \_\__,_|\__\___/     |_|\___/|_|
                V 2.1
from mrFD

 http://facebook.com/ninja.hackerz.kurdish/

 change your  SOCKES to 127.0.0.1:9050 

[+] time to change Ip in Sec [type=60] >> 60
[+] how many time do you want to change your ip [type=1000]for infinte ip change type [0] >>0
Traceback (most recent call last):
  File "/usr/share/aut/autoTOR.py", line 77, in <module>
    change()
  File "/usr/share/aut/autoTOR.py", line 48, in change
    print ('[+] Your IP has been Changed to : '+str(ma_ip()))
                                                    ^^^^^^^
  File "/usr/share/aut/autoTOR.py", line 43, in ma_ip
    get_ip= requests.get(url,proxies=dict(http='socks5://127.0.0.1:9050',https='socks5://127.0.0.1:9050'))
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/requests/api.py", line 73, in get
    return request("get", url, params=params, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/requests/api.py", line 59, in request
    return session.request(method=method, url=url, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/requests/sessions.py", line 589, in request
    resp = self.send(prep, **send_kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/requests/sessions.py", line 703, in send
    r = adapter.send(request, **kwargs)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/requests/adapters.py", line 454, in send
    conn = self.get_connection(request.url, proxies)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/requests/adapters.py", line 350, in get_connection
    proxy_manager = self.proxy_manager_for(proxy)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/requests/adapters.py", line 215, in proxy_manager_for
    manager = self.proxy_manager[proxy] = SOCKSProxyManager(
                                          ^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/requests/adapters.py", line 61, in SOCKSProxyManager
    raise InvalidSchema("Missing dependencies for SOCKS support.")
requests.exceptions.InvalidSchema: Missing dependencies for SOCKS support.

Marietto2008 avatar Feb 13 '24 08:02 Marietto2008