Repository navigation
Update matching for autotype desktop apps - #24844
Draft
coltonhurst wants to merge 1 commit into
Draft
coltonhurst wants to merge 1 commit into
coltonhurst wants to merge 1 commit into
Conversation
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🎟️ Tracking
📔 Objective
Autotype desktop app pairings are saved as login URIs (
desktopapp://autotype?…) with the Never match strategy. That keeps them from matching websites and from blocking HTTP authentication.However, a pairing can still be stored without the never matching strategy, which could break the http auth setting feature. One way this is possible is if a user manually types
desktopapp://{some text here}and then hits save. This login URI would then be treated as a desktop app pairing (though it would be an invalid one). (Even if we block this in the UI, it could come in through other means, such as the CLI, etc.)Therefore, we need a way to ensure desktop pairings without the "Never" authentication matching strategy don't break the app. This PR therefore adds the following changes:
LoginUriView.matchesUrinever matches a URI that starts withdesktopapp://, whatever its match strategy. The check ignores case and surrounding whitespace. Every pairing has the hostautotype, so with a Host default, a pairing stored without Never would otherwise matchhttp(s)://autotype/. All URI matching goes through this method: autofill, the inline menu, the notification bar, HTTP authentication, passkeys and list views.desktopapp://value typed into a website row keeps the strategy the user picked until it's saved. It's still saved with Never, as before.Not changed: HTTP authentication still requires every URI to have an explicit match strategy. A login with a desktop app that has no strategy can't use HTTP authentication until it's saved with the GA flag on. If the flag is read after the form opens, the setting becomes available again, but if it was turned off, it stays off.
With the Autotype GA flag off, the edit form works as before. The matching change applies everywhere, but only to
desktopapp://URIs. The one other behavior change:bw list items --url "desktopapp://…"no longer returns items with that pairing. Nothing in the clients matches against adesktopapp://URL.📸 Screenshots