-
Notifications
You must be signed in to change notification settings - Fork 112
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
WebAuthn does not work #329
Comments
I don't know much about it. |
in the windows version, webauth is up and running.
https://webauthn.io/?regUserVerification=preferred&attestation=none&attachment=platform&algES256=false&algRS256=false&discoverableCredential=preferred&authUserVerification=preferred |
Hi, has there been any work on this? WebAuthn still doesn't work and I have to use another browser to sign into my FIDO2-protected (YubiKey5) accounts on mobile. I use GrapheneOS with Google Play Services. WebAuthn works fine in Vanadium (a chromium-based browser made by the Graphene team - but not as feature-rich as cromite!) and in other apps. |
no, sorry, I haven't looked at it yet. |
Intrigued by how it works, I took a look at the chromium code and found a little something that does not convince me. docs: https://www.w3.org/TR/webauthn-3/ (Working Draft) to check:
I am also able to activate platform authenticator support in android without using gms, but
I'd be out of spec at this point, which explicitly requires encryption of private key in platform authenticators, but after all, android doesn't have support for native encryption protected by the OS, so what can I do? @PF4Public what do you think about it? is it worth doing even if, theoretically, it is not very safe? |
First of all, what makes WebAuthn not function in Cromite? Did you disable it intentionally? And secondly you should define "very safe". You cannot be significantly safer than Chromium unless you improve upon it yourself. On the other hand as far as I understand WebAuthn, most cryptographic operations are supposed to be running outside of a browser, perhaps there's not much you can do in terms of "safety"? |
the standard requires the existence of an authenticator, which may be external via usb or similar, or of the platform, implemented via software.
well, yes, as cromite does not allow the use of non-open code, in android. theoretically I should also deactivate it in Windows for the same reason.
The security lies in the way the private key generated by the plaform authenticator is stored. I do not know how gms saves this information and I do not think I will ever know. |
Does Android support hardware USB tokens for that purpose? |
Sorry, I do not understand the question, but android os does not have that feature, in android it is developed via google's library. |
https://developers.google.com/identity/fido/android/native-apps
Perhaps you could allow using only external (hardware) authenticators, which shouldn't compromise user's security; and forbid software implementation (platform authenticator). Alternatively you could allow enabling the latter upon user discretion. |
yes, it is gms (or part of the package) and is closed-source, is the current implementation used in chromium.
I would not be able to, and even if I succeed, it would take too long to develop as well as being outside the scope of cromite.
OK, but for example, would you use it? |
That would be the question for people who use |
Almost certainly via TPM using a key derived from device auth for the current user, however users may replace the default Google passkey provider with another provider at their discretion - e.g. Bitwarden, which is open source. The API calls will still be proxied through GMS or whatever, but actual passkey handling will be taken care of by Bitwarden.
Define "guarantees data security"? I don't believe application data storage has any relevance here, since storage of these keys is delegated to the external service, they're not stored by the browser itself. See below for notes on guarding against root access.
It cannot be a goal. If you have root, and are concerned about malicious activities performed as root, then you're already lost - as root you can read/write any process memory, and you cannot guarantee that any operation performed by an application is secure if your adversary can exploit root access.
I suspect attempting this would be strictly counter-productive.
As above, an adversary operating as root can already steal all your credentials, so that shouldn't be a blocker here. |
Can you elaborate? |
I can't see a way to remain in-spec when attempting this, although it's not entirely clear to me what you're proposing here. Are you suggesting this as an implementation detail for building an Authenticator directly into Cromite? |
sure, I thought it was clear :) |
Does the proposed implementation support delegating to other FIDO2 software/hardware like Bitwarden, Yubikeys, etc? Tying passkeys to application storage would make them extremely brittle. |
No. What I have done is to use the emulation already active in the developer tools. |
I see. I can't speak for others, but for me any implentation that doesn't allow the user to provide their own FIDO2 target is probably a non-starter. I also certainly wouldn't consider using a passkey implementation that is strictly tied to a specific browser install, and/or can be destroyed by wiping application storage - either of those conditions would disqualify it for me. I can understand the desire not to call non-free APIs, but I suspect that a local implementation is likely to be some combination of: less secure; less conformant; less usable. |
The web APIs allow selection of the minimum security level: consider that support in Windows is provided by the windows api (precisely, ‘platform authenticator’) even without hardware key, so in android, with my solution, it would be the same.
the key would be exportable, it is, after all, a file
That's why I stopped! or at least, put on low priority... |
I understand that "it works", but it does not work in an an interoperable way - if I want to use my hardware token to provide a passkey, so that I can use that passkey from multiple platforms, that is not possible in the proposed model.
But even if it was exportable, it would be entirely unusable except within Cromite. |
So, if the discussed implementation gets released, will there ever be support for hardware tokens, like YubiKeys? What about saving a passkey into a supported password manager? Also, why didn't the MicroG implementation get used? It was discussed at the beginning, but I can't find a reason why you didn't stick with it. Another option - maybe make 2 versions of the app, like other popular open source apps do. One fully 100% FOSS, and the other one, which can include some proprietary blobs where needed (like here, with Google's WebAuthn API). Then the user can choose if want to have those blobs or not. That could maybe allow for some other features, which are also blocked by the 100% FOSS policy. No matter what gets chosen, for the end user (me) it will be better than nothing. Right now, my accounts have to have another, less secure, 2FA method just for Cromite... Or if I can't do that, then I have to switch to a different browser just for that 1 task. So annoying. |
I don't have that hw.
if bitwarden/android#4005 is accepted, I can see how A14 Credential Manager works.
are you capable of it? sometimes you guys are really weird.
it is a choice, I have made mine. |
On CalyxOS at least, Chromium, any Chromium, has just not been working with it even with the flag enabled. So that would need to be addressed upstream first. |
ah, you say the a14 CM blocks use to unauthorised apps by google? seems strange to me, but I haven't read the documentation yet. but then, what is your pull for? |
I'm not sure because I can't look at the code, but it just seems using the credential manager in Chromium is just broken. The flag just doesn't seem to have any effect and passkey use just fails immediately, where on Mull/Fennec, Bitwarden complains about the browser instead, in the middle of the process. The PR I sent to Bitwarden should get one of the issues, which is having Bitwarden trust that browser for passkey use to be solved, but there is still this issue where Chromium doesn't seem to use the credential manager... At least for me. |
if the problem is with the chromium code it can be solved, if it is android it cannot. |
It doesn't seem to work on my mom's phone either, so I suspect it is a Chrome issue |
Bitwarden is still in beta, I suspect there's still more to fix in the passkey support side. (e.g. WhatsApp doesn't work with the new native app AFAICT) It makes sense to wait on this, I do think this will be the best form of passkey use in the end though. |
@lucasmz-dev if you let me know when Bitwarden comes out of beta I'll try to check what |
does anyone know how fido: url works? |
FYI, just realized this now, it seems like I can just download builds from GitHub and install them, they even seem to use the same signing key (?) because I just updated it no issue e.g. https://github.com/bitwarden/android/actions/runs/11462365731/job/31893580733 Mull already seems to work in this example |
Ok, it seems like whatever was happening with Chromium is now solved, as it now works on CalyxOS Chromium and Edge. Using bitwarden passkeys still doesn't work, though, on Cromite. Pretty sure CalyxOS Chromium has the proprietary blobs, might be worth looking into the microG reimplementation |
@uazo Can you take a look again? It's hard to login without passkeys. |
I would also appreciate this feature being revisited, this and extension support are the only reason I'm using brave alongside vanadium instead of cromite. While it wouldn't be directly useful for Yubikeys, GrapheneOS is working on its own implementation of FIDO2 without requiring play services using the on-device key. Perhaps it might be possible to collaborate? |
https://hwsecurity.dev/guide/fido-webview/
interesting, thank you @Doc-4
I don't think it can be possible |
Vanadium implemented preliminary webauthn support (without dependency on play services) as of this version: https://github.com/GrapheneOS/Vanadium/releases/tag/134.0.6998.108.0 It only supports some providers, and there are some open issues of it not working on certain sites, but it's there. I've personally tested Bitwarden and Proton pass and they work (although I don't actually use either, still waiting on support from either KeePass app.) |
Preliminary checklist
Can the bug be reproduced with corresponding Chromium version?
No
Cromite version
117.0.5938.89
Device architecture
arm64-v8a
Platform version
Android 13
Android Device model
Google Pixel 6 (with GrapheneOS and Sandboxed Play Services installed!)
Is the device rooted?
No
Changed flags
no flags changed
Is this bug happening in an incognito tab?
Yes
Is this bug caused by the adblocker?
No
Is this bug a crash?
not a crash
Describe the bug
WebAuthn just does not work. After trying to authenticate or register, I get an error (see screenshots)
Steps to reproduce the bug
Expected behavior
Get a Google Play Services (or similar) popup asking me to authenticate, like this:
Details
Screenshots
Details
The text was updated successfully, but these errors were encountered: