-
Notifications
You must be signed in to change notification settings - Fork 69
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
这里需要做 urllib.parse.unquote.不然登出会失败。 #950
Labels
Milestone
Comments
"""
将登录票据设置为不合法
"""
bk_token = request.COOKIES.get(settings.BK_COOKIE_NAME, None)
if bk_token:
bk_token = urllib.parse.unquote(bk_token)
BkToken.objects.filter(token=bk_token).update(is_logout=True) |
已确认,该问题确实存在,但是提交的PR方案可能我们还需要讨论一下 |
已确认,这里的cookie._unquote与urllib.parse.unquote并非相同作用,所以PR https://github.com/TencentBlueKing/bk-user/pull/951/files 是�OK的 |
@nannan00 这里是要讨论下,因为从Cookies里面拿数据是经常的行为,每个地方都unquote是不太方便。建议先这样处理,其他地方如果有问题了,再统一搞一个合适的方案。 |
yuri0528
pushed a commit
to yuri0528/bk-user
that referenced
this issue
May 8, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
bk-user/src/login/bklogin/bkauth/utils.py
Lines 140 to 145 in be15183
The text was updated successfully, but these errors were encountered: