Documentation
¶
Index ¶
- Constants
- func CheckSign(sign, appid, path, ts string) (ok bool)
- func File(c *gin.Context, filePath, fileName string)
- func JSON(c *gin.Context, data interface{}, err error)
- func Redirect(c *gin.Context, location string)
- func VerifySign(c *gin.Context)
- type CommonRsp
- type Config
- type GinEngine
- type Pager
- type RecoverInfo
Constants ¶
View Source
const ( TypeOctetStream = "application/octet-stream" TypeForm = "application/x-www-form-urlencoded" TypeJson = "application/json" TypeXml = "application/xml" TypeJpg = "image/jpeg" TypePng = "image/png" )
Variables ¶
This section is empty.
Functions ¶
func VerifySign ¶
VerifySign 验证Sign,签名规则,base64(md5(appid+path+ts)) todo: 当前支持60s验证,后续改成单次验证后即失效
Types ¶
type GinEngine ¶
type GinEngine struct { Gin *gin.Engine Tracer *trace.Tracer // contains filtered or unexported fields }
func (*GinEngine) Recovery ¶
func (g *GinEngine) Recovery() gin.HandlerFunc
Recovery gin middleware recovery
Click to show internal directories.
Click to hide internal directories.