Commit a5522d16 authored by gaoshiyao's avatar gaoshiyao

tls

parent ca1a33bd
...@@ -3,6 +3,7 @@ package handler ...@@ -3,6 +3,7 @@ package handler
import ( import (
"bytes" "bytes"
"compress/gzip" "compress/gzip"
"crypto/tls"
"encoding/json" "encoding/json"
"errors" "errors"
"fmt" "fmt"
...@@ -45,7 +46,7 @@ func Proxy(c *gin.Context) { ...@@ -45,7 +46,7 @@ func Proxy(c *gin.Context) {
c.JSON(200, res) c.JSON(200, res)
return return
} }
f, _ := forward.New(forward.PassHostHeader(true), forward.ResponseModifier(func(resp *http.Response) error { f, _ := forward.New(forward.PassHostHeader(true), forward.WebsocketTLSClientConfig(&tls.Config{InsecureSkipVerify: true}), forward.ResponseModifier(func(resp *http.Response) error {
//Resp = resp //Resp = resp
//判断是否超过调用次数是否可以调用 //判断是否超过调用次数是否可以调用
callflag, sensitiveflag, err := service.QueryCallsCount(proxyData) callflag, sensitiveflag, err := service.QueryCallsCount(proxyData)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment