Summary: | WebKit AX APIs expose secure text that is visibly hidden through HTMLInputElement::isAutoFilledAndObscured | ||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Tyler Wilcock <tyler_w> | ||||||||||||||
Component: | Accessibility | Assignee: | Tyler Wilcock <tyler_w> | ||||||||||||||
Status: | RESOLVED FIXED | ||||||||||||||||
Severity: | Normal | CC: | aboxhall, andresg_22, apinheiro, cdumez, cfleizach, changseok, dmazzoni, esprehn+autocc, ews-watchlist, gyuyoung.kim, jcraig, jdiggs, mifenton, samuel_white, webkit-bug-importer | ||||||||||||||
Priority: | P2 | Keywords: | InRadar | ||||||||||||||
Version: | Other | ||||||||||||||||
Hardware: | Unspecified | ||||||||||||||||
OS: | Unspecified | ||||||||||||||||
Attachments: |
|
Description
Tyler Wilcock
2023-03-04 11:53:13 PST
Created attachment 465294 [details]
Patch
Created attachment 465295 [details]
Patch
Created attachment 465296 [details]
Patch
Created attachment 465297 [details]
Patch
(In reply to Tyler Wilcock from comment #6) > Created attachment 465297 [details] > Patch * LayoutTests/accessibility/password-field-value-expected.txt: Removed. * LayoutTests/accessibility/password-field-value.html: Removed. * LayoutTests/accessibility/secure-field-value-expected.txt: Added. * LayoutTests/accessibility/secure-field-value.html: Added. Can this be a `git mv` instead? --- a/Source/WebCore/accessibility/AccessibilityNodeObject.cpp +++ b/Source/WebCore/accessibility/AccessibilityNodeObject.cpp -bool AccessibilityNodeObject::isPasswordField() const +bool AccessibilityNodeObject::isSecureField() const ... - return downcast<HTMLInputElement>(*node).isPasswordField(); + return input->isPasswordField() || input->isAutoFilledAndObscured(); Why not use the method you defined in HTMLInputElement: + bool isSecureField() const { return isPasswordField() || isAutoFilledAndObscured(); } Created attachment 465318 [details]
Patch
Created attachment 465319 [details]
Patch
Committed 261312@main (509d2d337d1c): <https://commits.webkit.org/261312@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 465319 [details]. |