-
Notifications
You must be signed in to change notification settings - Fork 45
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
Some bugs in FIDO2 #13
Comments
This is very strange, as FIDO2 is working fine on our production
applications.
Can you give me the env you are using? And the use case and the
authenticator you are using
Thanks
Mohamed
…On Tue, Jun 16, 2020, 21:15 John Spounias ***@***.***> wrote:
1.
Line 72 template FIDO/recheck.html
}).then(function (response) {if (response.ok) return res = response.json()}).then(function (res) {
if (res.status=="OK")
{
'res is undefined'
My fix is to remove the extra 'then' and just not dump it as json,
}).then(function (response) {
if (response.statusText=="OK")
Later in the same template 'res is used again for the redirect,
{% if mode == "auth" %}
window.location.href=res.redirect;
{% elif mode == "recheck" %}
I never actually saw one in the object when I console logged it, and was
able to hard code it for my use case, but this should also be checked.
I am happy to fix the above but it should be reviewed for context/intent
and see if I am missing something.
1.
Line 139 of FIDO2.py is a bool not a callable
138 request.session["mfa"] = mfa
139 if not request.user.is_authenticated():
140 res=login(request)
should be
138 request.session["mfa"] = mfa
139 if not request.user.is_authenticated:
140 res=login(request)
Please review and if these fixes are OK I can do a PR for them. I feel
like I am forgetting one more...
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#13>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ACPOPRGJUUJBZACCTRT7IT3RW6ZD5ANCNFSM4N73TSTA>
.
|
I am using Django 3.0.7 Its a generic FIDO2 usb auth device which functions for other use cases, and works once I made these adjustments. |
Which browser are you testing against? For is_authenticated(), the change is part if Django 2.0, so we need to try both |
I have been testing with the latest versions of both Firefox and Chrome. Most of my debugging is Chrome for FIDO2 so far, but I could try other browsers if required. |
Can you please give me the test case for js issues? So I reproduce it |
The test case was authentication using a FIDO2 USB, the failure will trigger during auth. |
So to have clear,
Do I miss something? |
Correct. |
Trying on linux vs windows I am getting different results... Will do more testing and post back when I have more info. |
Changed to
for some reason between os/browser 'statusText' was empty vs 'OK' on the other platform. |
@d3cline Can you provide a demo app to show the problem on github and send me the link as I tried and I can reproduce the templates issue |
Not sure I can. Let me try to explain a bit. |
Line 72 template FIDO/recheck.html
'res is undefined'
My fix is to remove the extra 'then' and just not dump it as json,
Later in the same template 'res is used again for the redirect,
I never actually saw one in the object when I console logged it, and was able to hard code it for my use case, but this should also be checked.
I am happy to fix the above but it should be reviewed for context/intent and see if I am missing something.
Line 139 of FIDO2.py is a bool not a callable
should be
Please review and if these fixes are OK I can do a PR for them. I feel like I am forgetting one more...
The text was updated successfully, but these errors were encountered: