From a59e480b6109ab4f221a44c6fd3d94e10c73dd99 Mon Sep 17 00:00:00 2001 From: bjdgyc Date: Thu, 22 Feb 2024 17:15:43 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=20openconnect=20=E9=87=8D?= =?UTF-8?q?=E8=BF=9E=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server/go.mod | 6 +++--- server/handler/link_tunnel.go | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/server/go.mod b/server/go.mod index f0ec6732..ef1a275f 100644 --- a/server/go.mod +++ b/server/go.mod @@ -43,7 +43,7 @@ require ( ) require ( - github.com/aliyun/alibaba-cloud-sdk-go v1.62.679 // indirect + github.com/aliyun/alibaba-cloud-sdk-go v1.62.680 // indirect github.com/cenkalti/backoff/v4 v4.2.1 // indirect github.com/cloudflare/cloudflare-go v0.88.0 // indirect github.com/felixge/httpsnoop v1.0.4 // indirect @@ -61,8 +61,8 @@ require ( github.com/sagikazarmark/locafero v0.4.0 // indirect github.com/sagikazarmark/slog-shim v0.1.0 // indirect github.com/sourcegraph/conc v0.3.0 // indirect - github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.859 // indirect - github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/dnspod v1.0.859 // indirect + github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/common v1.0.860 // indirect + github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/dnspod v1.0.860 // indirect github.com/toorop/go-dkim v0.0.0-20240103092955-90b7d1423f92 // indirect github.com/yusufpapurcu/wmi v1.2.4 // indirect go.uber.org/multierr v1.11.0 // indirect diff --git a/server/handler/link_tunnel.go b/server/handler/link_tunnel.go index cf96ee0d..3c7eb097 100644 --- a/server/handler/link_tunnel.go +++ b/server/handler/link_tunnel.go @@ -43,13 +43,13 @@ func LinkTunnel(w http.ResponseWriter, r *http.Request) { // 判断session-token的值 cookie, err := r.Cookie("webvpn") if err != nil || cookie.Value == "" { - w.WriteHeader(http.StatusBadRequest) + w.WriteHeader(http.StatusUnauthorized) return } sess := sessdata.SToken2Sess(cookie.Value) if sess == nil { - w.WriteHeader(http.StatusBadRequest) + w.WriteHeader(http.StatusUnauthorized) return } @@ -57,7 +57,7 @@ func LinkTunnel(w http.ResponseWriter, r *http.Request) { cSess := sess.NewConn() if cSess == nil { log.Println(err) - w.WriteHeader(http.StatusBadRequest) + w.WriteHeader(http.StatusUnauthorized) return }