This commit is contained in:
yangduo 2024-09-25 14:12:18 +08:00
parent 6e6be7492e
commit 5f862d5c3f

View File

@ -22,12 +22,14 @@ import (
其他的需要校验
OutApp不需要限制并发数!!!
Callback 也不需要
*/
func CaForward(c *gin.Context) {
accountId := c.DefaultQuery("account_id", "")
sessionId := c.DefaultQuery("session_id", "")
var needlimit bool = !strings.HasPrefix(c.DefaultQuery("c", ""), "OutApp")
cmd:=c.DefaultQuery("c", "")
var needlimit bool = !strings.HasPrefix(cmd, "OutApp") && !strings.HasPrefix(cmd, "Callback")
if needlimit && !jccommon.IsValidSessionId(accountId, sessionId) {
f5.RspErr(c, 500, "invalid session_id")
c.Abort()