From: Sergey Matveev Date: Fri, 15 Jul 2022 06:37:16 +0000 (+0300) Subject: Some realms contain quotes X-Git-Tag: v0.1.0~22 X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;h=fc74c74d083e3a743c5f2ca83a3d2f1e088c5e06;p=tofuproxy.git Some realms contain quotes --- diff --git a/httpauth.go b/httpauth.go index d62d0fc..ca708b0 100644 --- a/httpauth.go +++ b/httpauth.go @@ -59,7 +59,7 @@ bind . {switch -exact %%K { q {exit 0} ; # reject once l login }} -`, realm, userInit, passInit)) +`, strings.ReplaceAll(realm, "\"", ""), userInit, passInit)) cmd := exec.Command(ttls.CmdWish) cmd.Stdin = &b out, err := cmd.Output()