Documentation
¶
Index ¶
- Constants
- func ApiCheckAesDecryptData(gc *gin.Context, v interface{}) (err error)
- func ApiCheckAesEncryptData(gc *gin.Context, data interface{}) (enData string, err error)
- func ApiCheckAesGetEnData(gc *gin.Context) string
- func ApiCheckAesGetEncryptor(gc *gin.Context) (encryptor *utilEnc.AesEncryptor, err error)
- func ApiCheckAesHandler(getSecret GetSecretFunc, debug ...bool) gin.HandlerFunc
- func CorsHandler(config *CorsConfig) gin.HandlerFunc
- func SessionHandler(before func(s sessions.Session, c *gin.Context), ...) gin.HandlerFunc
- type CorsConfig
- type GetSecretFunc
Constants ¶
View Source
const ApiCheckAesApiDataKey = "_api_check_aes_api_data"
View Source
const ApiCheckAesEncryptorKey = "_api_check_aes_encryptor"
Variables ¶
This section is empty.
Functions ¶
func ApiCheckAesDecryptData ¶
func ApiCheckAesEncryptData ¶
func ApiCheckAesGetEnData ¶
func ApiCheckAesGetEncryptor ¶
func ApiCheckAesGetEncryptor(gc *gin.Context) (encryptor *utilEnc.AesEncryptor, err error)
func ApiCheckAesHandler ¶
func ApiCheckAesHandler(getSecret GetSecretFunc, debug ...bool) gin.HandlerFunc
func CorsHandler ¶
func CorsHandler(config *CorsConfig) gin.HandlerFunc
Types ¶
type CorsConfig ¶
type CorsConfig struct { AllowAllOrigins bool `json:"allow_all_origins"` AllowOrigins []string `json:"allow_origins,omitempty"` AllowHeaders []string `json:"allow_headers,omitempty"` AllowMethods []string `json:"allow_methods,omitempty"` AllowCredentials bool `json:"allow_credentials,omitempty"` MaxAgeHours int `json:"max_age_hours,omitempty"` AllowWebSockets bool `json:"allow_web_sockets,omitempty"` }
Click to show internal directories.
Click to hide internal directories.