Add LoginStore::list_candidates() and LoginStore::get_many() - #7557
Conversation
for checking login candidates without encryption.
bendk
left a comment
There was a problem hiding this comment.
Fetching all the rows for this and passing them across the FFI doesn't seem ideal, but I think it should be okay. I believe we fetch and decrypt all the logins on Android when a user views the passwords list and this can't be worse than that. Is there a long-term plan to move the logic into Rust?
This looks fine from my POV, the only thing I wasn't sure about is how to name all of this. I remember us coming up with a bunch of different naming schemes when we first introduced the login vs encrypted login split. "LoginCandidate" seems fine to me, how do you feel about it @mhammond ?
|
There is no long term plan yet. The thing which makes this a little complicated is that this PSL is needed Rust side. We could provide it's interface via Foreign Trait - but still this involves handing n logins (or their origins) across FFI borders. This is our PSL on desktop: https://searchfox.org/firefox-main/source/netwerk/dns/effective_tld_names.dat One thing we could at least do to reduce FFI throughput is to minimize this |
for checking login candidates without encryption.
Background: The Rust logins backend can trigger a Primary Password prompt on desktop during password autocomplete before a matching login has been identified. This can affect pages containing password inputs even when no matching login exists. For matching origins, PSL is needed, which we don't ship with Rust. Simplest and minimal invasive solution is to hand over the candidate logins without encrypted fields from Rust, so that desktop can continue using the same matching function in JS.
Pull Request checklist
[ci full]to the PR title.