Versions in this module Expand all Collapse all v1 v1.1.2 Apr 17, 2023 v1.1.1 Apr 17, 2023 Changes in this version + var Client *http.Client + var ClientNoRedirect *http.Client + var DialTimout = 5 * time.Second + var GC gcache.Cache + var KeepAlive = 15 * time.Second + func DoRequest(req *http.Request, redirect bool) (*http.Response, int64, error) + func GetRespBody(oResp *http.Response) ([]byte, error) + func InitCache(size int) + func InitHttpClient(ThreadsNum int, DownProxy string, Timeout time.Duration) error + func ParseHttpRequest(oReq *http.Request) (*structs.Request, error) + func ParseHttpResponse(oResp *http.Response, milliseconds int64) (*structs.Response, error) + func ParseTCPUDPRequest(content []byte) (*structs.Request, error) + func ParseTCPUDPResponse(content []byte, socket *net.Conn, transport string) (*structs.Response, error) + func ParseUrl(u *url.URL) *structs.UrlType + func PutAddrType(addrType *structs.AddrType) + func PutConnectInfo(connInfo *structs.ConnInfoType) + func PutRequest(request *structs.Request) + func PutResponse(response *structs.Response) + func PutUrlType(urlType *structs.UrlType) + func XrayGetHttpRequestCache(ruleReq *structs.RuleRequest) (*http.Request, *structs.Request, *structs.Response, bool) + func XrayGetTcpUdpConnectionCache(connectionId string) (*net.Conn, bool) + func XrayGetTcpUdpResponseCache(content string) ([]byte, *structs.Response, bool) + func XraySetHttpRequestCache(ruleReq *structs.RuleRequest, request *http.Request, ...) bool + func XraySetTcpUdpConnectionCache(connectionId string, conn *net.Conn) bool + func XraySetTcpUdpResponseCache(content string, response []byte, protoResponse *structs.Response) bool