From 88fe6dbe8d3e2de1294e93da0d8dc510c5f1d2ec Mon Sep 17 00:00:00 2001 From: lqqyt2423 <974923609@qq.com> Date: Fri, 14 Jan 2022 14:00:35 +0800 Subject: [PATCH] upgrade version --- README.md | 4 ++++ README_CN.md | 4 ++++ cmd/go-mitmproxy/main.go | 6 +++--- go.mod | 5 ++++- go.sum | 4 ++-- proxy/proxy.go | 2 +- 6 files changed, 18 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 6455307..32bca22 100644 --- a/README.md +++ b/README.md @@ -46,6 +46,10 @@ Usage of go-mitmproxy: dump filename -dump_level int dump level: 0 - header, 1 - header + body + -mapper_dir string + mapper files dirpath + -ssl_insecure + not verify upstream server SSL/TLS certificates. -version show version -web_addr string diff --git a/README_CN.md b/README_CN.md index 3dcb752..c6fa7ea 100644 --- a/README_CN.md +++ b/README_CN.md @@ -46,6 +46,10 @@ Usage of go-mitmproxy: dump filename -dump_level int dump level: 0 - header, 1 - header + body + -mapper_dir string + mapper files dirpath + -ssl_insecure + not verify upstream server SSL/TLS certificates. -version show version -web_addr string diff --git a/cmd/go-mitmproxy/main.go b/cmd/go-mitmproxy/main.go index b501bc1..8741ee7 100644 --- a/cmd/go-mitmproxy/main.go +++ b/cmd/go-mitmproxy/main.go @@ -12,13 +12,13 @@ import ( log "github.com/sirupsen/logrus" ) -const version = "0.1.1" +const version = "0.1.3" type Config struct { version bool - addr string - webAddr string + addr string + webAddr string ssl_insecure bool dump string // dump filename diff --git a/go.mod b/go.mod index 582a9e6..981eee4 100644 --- a/go.mod +++ b/go.mod @@ -8,6 +8,9 @@ require ( github.com/gorilla/websocket v1.4.2 github.com/satori/go.uuid v1.2.0 github.com/sirupsen/logrus v1.8.1 - golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e // indirect +) + +require ( + golang.org/x/sys v0.0.0-20220111092808-5a964db01320 // indirect gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect ) diff --git a/go.sum b/go.sum index 142ac8c..e5ee18a 100644 --- a/go.sum +++ b/go.sum @@ -20,7 +20,7 @@ github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic github.com/stretchr/testify v1.2.2 h1:bSDNvY7ZPG5RlJ8otE/7V6gMiyenm9RtJ7IUVIAoJ1w= github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e h1:fLOSk5Q00efkSvAm+4xcoXD+RRmLmmulPn5I3Y9F2EM= -golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220111092808-5a964db01320 h1:0jf+tOCoZ3LyutmCOWpVni1chK4VfFLhRsDK7MhqGRY= +golang.org/x/sys v0.0.0-20220111092808-5a964db01320/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= diff --git a/proxy/proxy.go b/proxy/proxy.go index 44b10eb..e575d42 100644 --- a/proxy/proxy.go +++ b/proxy/proxy.go @@ -53,7 +53,7 @@ func NewProxy(opts *Options) (*Proxy, error) { DisableCompression: true, // To get the original response from the server, set Transport.DisableCompression to true. TLSClientConfig: &tls.Config{ InsecureSkipVerify: opts.SslInsecure, - KeyLogWriter: GetTlsKeyLogWriter(), + KeyLogWriter: GetTlsKeyLogWriter(), }, }, CheckRedirect: func(req *http.Request, via []*http.Request) error {