tiny proxy hangs with Socks5 authentication

Aperta
#559 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
c
Ambito
networking

Direzione di ricerca

Start by tracing the SOCKS5 upstream connection and authentication handling; the issue provides a reproduction configuration using Upstream socks5 user:pass@host:port and logs showing the connection is established before it hangs. Reproduce with authentication disabled and enabled, then identify where the authenticated handshake stops and add a regression test. Done when authenticated SOCKS5 forwarding completes successfully and the test passes.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Tinyproxy version

tinyproxy 1.11.1

Issue

TP fails in Upstream forwarding when using Socks5 in conjunction with User/Pass Authentication method.
Socks5 server works on its own
tiny proxy server works with socks5 without the authentication but it fails with the authentication enabled in the configuration

##here is the configuration file:

StatFile "/usr/share/tinyproxy/stats.html"
DefaultErrorFile "/usr/share/tinyproxy/default.html"
Timeout 600
User root
Group root
Port 40004
LogFile "/var/log/tinyproxy/tinyproxy.log"
PidFile "/run/tinyproxy/tinyproxy.pid"
Upstream socks5 user:[email protected]:36036

logs

NOTICE Oct 06 13:00:02.773 [2192305]: Initializing tinyproxy ...
NOTICE Oct 06 13:00:02.774 [2192305]: Reloading config file
INFO Oct 06 13:00:02.776 [2192305]: Added upstream socks5 5.78.102.102:36036 for [default]
NOTICE Oct 06 13:00:02.777 [2192305]: Reloading config file finished
INFO Oct 06 13:00:02.778 [2192305]: listen_sock called with addr = '(NULL)'
INFO Oct 06 13:00:02.780 [2192305]: trying to listen on host[0.0.0.0], family[2], socktype[1], proto[6]
INFO Oct 06 13:00:02.781 [2192305]: listening on fd [3]
INFO Oct 06 13:00:02.782 [2192305]: trying to listen on host[::], family[10], socktype[1], proto[6]
INFO Oct 06 13:00:02.784 [2192305]: listening on fd [4]
INFO Oct 06 13:00:02.785 [2192305]: Now running as group "root".
INFO Oct 06 13:00:02.786 [2192305]: Now running as user "root".
INFO Oct 06 13:00:02.788 [2192305]: Setting the various signals.
INFO Oct 06 13:00:02.789 [2192305]: Starting main loop. Accepting connections.
CONNECT Oct 06 13:00:14.885 [2192305]: Connect (file descriptor 6): 192.168.1.2
CONNECT Oct 06 13:00:14.886 [2192305]: Request (file descriptor 6): GET http://ifconfig.me/ HTTP/1.1
INFO Oct 06 13:00:14.887 [2192305]: Found upstream proxy socks5 5.78.102.102:36036 for ifconfig.me
INFO Oct 06 13:00:14.889 [2192305]: opensock: opening connection to 5.78.102.102:36036
INFO Oct 06 13:00:14.891 [2192305]: opensock: getaddrinfo returned for 5.78.102.102:36036
CONNECT Oct 06 13:00:15.147 [2192305]: Established connection to socks5 proxy "5.78.102.102" using file descriptor 7.

Lingua principale
C
Stelle
6.1k
Fork
768
Merge medio
15g 3h
PR unite (30g)
1

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di tinyproxy/tinyproxy

Tutte le issue di tinyproxy/tinyproxy

Issue simili

Altre issue su C

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.