mirror of https://github.com/Dreamacro/clash.git
Fix: trim FQDN on http proxy request
This commit is contained in:
parent
58c077b45e
commit
f1b792bd26
|
@ -4,6 +4,7 @@ import (
|
|||
"net"
|
||||
"net/http"
|
||||
"strconv"
|
||||
"strings"
|
||||
|
||||
"github.com/Dreamacro/clash/component/socks5"
|
||||
C "github.com/Dreamacro/clash/constant"
|
||||
|
@ -38,6 +39,9 @@ func parseHTTPAddr(request *http.Request) *C.Metadata {
|
|||
port = "80"
|
||||
}
|
||||
|
||||
// trim FQDN (#737)
|
||||
host = strings.TrimRight(host, ".")
|
||||
|
||||
metadata := &C.Metadata{
|
||||
NetWork: C.TCP,
|
||||
AddrType: C.AtypDomainName,
|
||||
|
|
Loading…
Reference in New Issue