Skip to content

Socks5代理不支持UDP么? #175

@duod4o

Description

@duod4o

按照文档,开启socks代理:

proxy socks -t tcp -p "0.0.0.0:38080"
Proxy Enterprise Version v6.5_20181101132810 by snail , blog : http://www.host900.com/
2018/11/08 20:47:54 tcp socks proxy on [::]:38080

通过查看端口,确实开启了38080的tcp端口

netstat -ano | find "38080"
  TCP    0.0.0.0:38080          0.0.0.0:0              LISTENING       10852
  TCP    [::]:38080             [::]:0                 LISTENING       10852

但是说好支持的UDP呢?运行proxy help socks,并没有找到和udp有关的设置,能否给一个示例呢?还是说,socks5代理仅仅支持tcp协议??

usage: proxy socks [<flags>]

proxy on ssh mode

Flags:
      --help                     Show context-sensitive help (also try
                                 --help-long and --help-man).
      --version                  Show application version.
      --debug                    debug log output
      --daemon                   run proxy in background
      --forever                  run proxy in forever,fail and retry
      --log=""                   log file path
      --nolog                    turn off logging
      --kcp-key="secrect"        pre-shared secret between client and server
      --kcp-method=aes           encrypt/decrypt method, can be: aes, aes-128,
                                 aes-192, salsa20, blowfish, twofish, cast5,
                                 3des, tea, xtea, xor, sm4, none
      --kcp-mode=fast            profiles: fast3, fast2, fast, normal, manual
      --kcp-mtu=450              set maximum transmission unit for UDP packets
      --kcp-sndwnd=1024          set send window size(num of packets)
      --kcp-rcvwnd=1024          set receive window size(num of packets)
      --kcp-ds=10                set reed-solomon erasure coding - datashard
      --kcp-ps=3                 set reed-solomon erasure coding - parityshard
      --kcp-dscp=0               set DSCP(6bit)
      --kcp-nocomp               disable compression
      --kcp-acknodelay           be carefull! flush ack immediately when a
                                 packet is received
      --kcp-nodelay=0            be carefull!
      --kcp-interval=50          be carefull!
      --kcp-resend=0             be carefull!
      --kcp-nc=0                 be carefull! no congestion
      --kcp-sockbuf=4194304      be carefull!
      --kcp-keepalive=10         be carefull!
  -P, --parent= ...              parent ssh address, such as: "23.32.32.19:22"
  -T, --parent-type=tcp          parent protocol type <tls|tcp|kcp|ssh>
  -t, --local-type=tcp           local protocol type <tls|tcp|kcp>
  -p, --local=":33080"           local ip:port to listen
  -C, --cert="proxy.crt"         cert file for tls
      --ca=""                    ca cert file for tls
  -K, --key="proxy.key"          key file for tls
  -u, --ssh-user=""              user for ssh
  -S, --ssh-key=""               private key file for ssh
  -s, --ssh-keysalt=""           salt of ssh private key
  -D, --ssh-password=""          password for ssh
      --always                   always use parent proxy
      --timeout=5000             tcp timeout milliseconds when connect to real
                                 server or parent proxy
      --interval=10              check domain if blocked every interval seconds
  -b, --blocked="blocked"        blocked domain file , one domain each line
  -d, --direct="direct"          direct domain file , one domain each line
  -F, --auth-file=AUTH-FILE      http basic auth file,"username:password" each
                                 line in file
  -a, --auth=AUTH ...            socks auth username and password, mutiple user
                                 repeat -a ,such as: -a user1:pass1 -a
                                 user2:pass2
  -g, --local-bind-ips=LOCAL-BIND-IPS ...
                                 if your host behind a nat,set your public ip
                                 here avoid dead loop
      --auth-url=""              auth username and password will send to this
                                 url,response http code equal to 'auth-code'
                                 means ok,others means fail.
      --auth-timeout=3000        access 'auth-url' timeout milliseconds
      --auth-code=204            access 'auth-url' success http code
      --auth-retry=0             access 'auth-url' fail and retry count
  -A, --parent-auth=PARENT-AUTH  parent socks auth username and password, such
                                 as: -A user1:pass1
  -q, --dns-address=""           if set this, proxy will use this dns for
                                 resolve doamin
  -e, --dns-ttl=300              caching seconds of dns query result
  -z, --local-key=""             the password for auto encrypt/decrypt local
                                 connection data
  -Z, --parent-key=""            the password for auto encrypt/decrypt parent
                                 connection data
  -m, --local-compress           auto compress/decompress data on local
                                 connection
  -M, --parent-compress          auto compress/decompress data on parent
                                 connection
      --lb-method=roundrobin     load balance method when use multiple
                                 parent,can be
                                 <roundrobin|leastconn|leasttime|hash|weight>
      --lb-timeout=500           tcp milliseconds timeout of connecting to
                                 parent
      --lb-retrytime=1000        sleep time milliseconds after checking
      --lb-hashtarget            use target address to choose parent for LB
      --lb-onlyha                use only `high availability mode` to choose
                                 parent for LB
  -l, --rate-limit="0"           rate limit (bytes/second) of each connection,
                                 such as: 100K 1.5M . 0 means no limitation
  -B, --bind-listen              using listener binding IP when connect to
                                 target

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions