14.04.2026 Update
This commit is contained in:
@@ -8,7 +8,7 @@ import (
|
||||
"net/url"
|
||||
"strings"
|
||||
|
||||
"alpine-router/mihomo"
|
||||
"nano-router/mihomo"
|
||||
)
|
||||
|
||||
func getMihomoAPIBase() string {
|
||||
@@ -150,7 +150,7 @@ func HandleMihomoWSProxy(w http.ResponseWriter, r *http.Request) {
|
||||
upgradeReq += "Host: " + host + ":" + port + "\r\n"
|
||||
upgradeReq += "Upgrade: websocket\r\n"
|
||||
upgradeReq += "Connection: Upgrade\r\n"
|
||||
upgradeReq += "Sec-WebSocket-Key: dGhlIHNhbXBsZSBub25jZQ==\r\n"
|
||||
upgradeReq += "Sec-WebSocket-Key: " + r.Header.Get("Sec-Websocket-Key") + "\r\n"
|
||||
upgradeReq += "Sec-WebSocket-Version: 13\r\n"
|
||||
if secret != "" {
|
||||
upgradeReq += "Authorization: Bearer " + secret + "\r\n"
|
||||
|
||||
Reference in New Issue
Block a user