Skip to content

修复了无法对带参数get请求正确判断权限的bug#54

Merged
astaxie merged 1 commit intobeego:masterfrom
cst05001:master
Nov 25, 2016
Merged

修复了无法对带参数get请求正确判断权限的bug#54
astaxie merged 1 commit intobeego:masterfrom
cst05001:master

Conversation

@cst05001
Copy link
Copy Markdown

beego 的 ctx.Request.RequestURI 参数包含了 get 请求的参数。
而源代码在做权限判断 params[2] 中 并没有过滤掉 get 传参(www.example.com/package/controller/method?param) 的 param 部分。
所以method 权限会以 method?param 进行匹配, 无法匹配权限。

 提交者:   cst05001 <65141838@qq.com>
	修改:      src/rbac.go
@astaxie astaxie merged commit be792d1 into beego:master Nov 25, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants