diff options
author | Ted Unangst <tedu@tedunangst.com> | 2022-03-01 01:59:36 -0500 |
---|---|---|
committer | Ted Unangst <tedu@tedunangst.com> | 2022-03-01 01:59:36 -0500 |
commit | 2b911d883a2afddd3a208ad85b1187d64363c202 (patch) | |
tree | 2b48a46f165aa32a2e18b2b5bd511fa335213df4 | |
parent | ca68ff1fd759be5b875da9908aedd585442cb8d8 (diff) |
get it going
-rw-r--r-- | interpreter.go | 3 | ||||
-rw-r--r-- | miniwebproxy.go | 1 |
2 files changed, 3 insertions, 1 deletions
diff --git a/interpreter.go b/interpreter.go index bb4cb92..8b45e02 100644 --- a/interpreter.go +++ b/interpreter.go @@ -16,7 +16,7 @@ func (interp *interpreter) NewConnection(r *http.Request) { } func (interp *interpreter) ShouldIntercept(hostname string) bool { - return false + return true } func (interp *interpreter) Prefilter(req *http.Request) { @@ -27,6 +27,7 @@ func (interp *interpreter) FilterResponse(w io.Writer, req *http.Request, servre } func (interp *interpreter) FilterHTML(w io.Writer, req *http.Request, root *html.Node) { + html.Render(w, root) } func getinterpreter() *interpreter { diff --git a/miniwebproxy.go b/miniwebproxy.go index 61c95de..d4ee7a5 100644 --- a/miniwebproxy.go +++ b/miniwebproxy.go @@ -203,6 +203,7 @@ func getTLSConfig(host string) *tls.Config { tls.Certificate{Certificate: [][]byte{derBytes, cacert.Certificate[0]}, PrivateKey: priv, }}, + ServerName: host, }, expiry: notAfter, } |