httpctx

package
v1.2.3-sp3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 4, 2023 License: AGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	REQUEST_CONTEXT_KEY_IsHttps                      = "isHttps"
	REQUEST_CONTEXT_KEY_IsDropped                    = "isRequestDropped"
	RESPONSE_CONTEXT_KEY_IsDropped                   = "isResponseDropped"
	RESPONSE_CONTEXT_NOLOG                           = "isResponseNoLog"
	REQUEST_CONTEXT_KEY_AutoFoward                   = "isRequestAutoForward"
	RESPONSE_CONTEXT_KEY_AutoFoward                  = "isResponseAutoForward"
	REQUEST_CONTEXT_KEY_Url                          = "url"
	REQUEST_CONTEXT_KEY_IsModified                   = "requestIsModified"
	REQUEST_CONTEXT_KEY_ModifiedBy                   = "requestIsModifiedBy"
	REQUEST_CONTEXT_KEY_Modified                     = "requestModified"
	REQUEST_CONTEXT_KEY_RequestIsFiltered            = "requestIsFiltered"
	RESPONSE_CONTEXT_KEY_ResponseIsFiltered          = "responseIsFiltered"
	REQUEST_CONTEXT_KEY_RequestIsHijacked            = "requestIsHijacked"
	REQUEST_CONTEXT_KEY_RequestBytes                 = "requestBytes"
	REQUEST_CONTEXT_KEY_ResponseBytes                = "responseBytes"
	REQUEST_CONTEXT_KEY_RequestIsStrippedGzip        = "requestIsStrippedGzip"
	RESPONSE_CONTEXT_KEY_ShouldBeHijackedFromRequest = "shouldBeHijackedFromRequest"
	REQUEST_CONTEXT_KEY_ConnectedTo                  = "connectedTo"
)
View Source
const REQUEST_CONTEXT_INFOMAP = "InfoMap"

Variables

This section is empty.

Functions

func GetContextBoolInfoFromRequest

func GetContextBoolInfoFromRequest(r *http.Request, key string) bool

func GetContextInfoMap

func GetContextInfoMap(r *http.Request) *sync.Map

func GetContextIntInfoFromRequest

func GetContextIntInfoFromRequest(r *http.Request, key string) int

func GetContextStringInfoFromRequest

func GetContextStringInfoFromRequest(r *http.Request, key string) string

func GetRequestBytes

func GetRequestBytes(r *http.Request) []byte

func GetRequestHTTPS

func GetRequestHTTPS(r *http.Request) bool

func SetContextValueInfoFromRequest

func SetContextValueInfoFromRequest(r *http.Request, key string, value any)

func SetRequestBytes

func SetRequestBytes(r *http.Request, bytes []byte)

func SetRequestHTTPS

func SetRequestHTTPS(r *http.Request, b bool)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL