From 13bc2d4a2e020cbf9d8fea9bd8712a3bdbb00752 Mon Sep 17 00:00:00 2001 From: nadoo <287492+nadoo@users.noreply.github.com> Date: Sun, 24 Dec 2017 23:13:53 +0800 Subject: [PATCH] doc: correct a mistake in example config file --- .../9.transparent_proxy_without_dnsmasq/rules.d/home.rule | 2 +- dns.go | 6 +++--- http.go | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/config/examples/9.transparent_proxy_without_dnsmasq/rules.d/home.rule b/config/examples/9.transparent_proxy_without_dnsmasq/rules.d/home.rule index 06759cb..956afbb 100644 --- a/config/examples/9.transparent_proxy_without_dnsmasq/rules.d/home.rule +++ b/config/examples/9.transparent_proxy_without_dnsmasq/rules.d/home.rule @@ -3,7 +3,7 @@ forward=http://forwarder4:8080 # first connect forwarder1 then forwarder2 then internet -forward=http://forwarder5:8080,socks6://forwarder3:1080 +forward=http://forwarder5:8080,socks5://forwarder3:1080 # Round Robin mode: rr diff --git a/dns.go b/dns.go index 5f5ebac..72f7aca 100644 --- a/dns.go +++ b/dns.go @@ -121,14 +121,14 @@ func (s *DNS) ListenAndServe() { var respLen uint16 err = binary.Read(rc, binary.BigEndian, &respLen) if err != nil { - logf("proxy-dns: error in read respLen %s\n", err) + logf("proxy-dns error in read respLen %s\n", err) return } respMsg := make([]byte, respLen) _, err = io.ReadFull(rc, respMsg) if err != nil { - logf("proxy-dns: error in read respMsg %s\n", err) + logf("proxy-dns error in read respMsg %s\n", err) return } @@ -156,7 +156,7 @@ func (s *DNS) ListenAndServe() { _, err = c.WriteTo(respMsg, clientAddr) if err != nil { - logf("error in local write: %s\n", err) + logf("proxy-dns error in local write: %s\n", err) } } diff --git a/http.go b/http.go index e182919..523fd33 100644 --- a/http.go +++ b/http.go @@ -206,9 +206,9 @@ func (s *HTTP) Dial(network, addr string) (net.Conn, error) { if ok && code == "200" { return rc, err } else if code == "407" { - logf("proxy-http: authencation needed by proxy %s", s.addr) + logf("proxy-http authencation needed by proxy %s", s.addr) } else if code == "405" { - logf("proxy-http: 'CONNECT' method not allowed by proxy %s", s.addr) + logf("proxy-http 'CONNECT' method not allowed by proxy %s", s.addr) } return nil, errors.New("cound not connect remote address: " + addr + ". error code: " + code)