Closed Bug 1871214 (CVE-2024-4766) Opened 9 months ago Closed 5 months ago

Android- Webshare dialog hides fullscreen notification lead to spoof

Categories

(Fenix :: General, defect, P1)

defect

Tracking

(firefox125 wontfix, firefox126+ fixed, firefox127+ fixed, firefox132 verified)

VERIFIED FIXED
127 Branch
Tracking Status
firefox125 --- wontfix
firefox126 + fixed
firefox127 + fixed
firefox132 --- verified

People

(Reporter: sas.kunz, Assigned: pollymce)

References

Details

(Keywords: csectype-spoof, reporter-external, sec-moderate, Whiteboard: [reporter-external] [client-bounty-form] [verif?] [group4][qa-triaged] [adv-main126+])

Attachments

(6 files, 1 obsolete file)

I found a vulnerability in firefox android where a webshare dialog can cover fullscreen notifications which can lead to spoofs.

steps to produce

  1. open http://103.186.0.20/webshare.html or webshare.html
  2. double tap on button

OS: Android 12 (Samsung M31)

Flags: sec-bounty?
Attached file webshare.html

steps to produce

  1. open https://103.186.0.20/webshare.html or webshare.html
  2. double tap on button
Group: firefox-core-security → mobile-core-security
Component: Security → General
Product: Firefox → Fenix
See Also: → 1871217

I'll mark this sec-high for now, but it kind of feels like the same basic issue as bug 1871217, because we've got a system prompt that is doing the overlapping.

Priority: -- → P2
Severity: -- → S2
Duplicate of this bug: 1878043

Titouan's fix for bug 1874795 is expected to also fix this bug. Assigning this bug to Titouan as a reminder to test this bug's STR.

Assignee: nobody → tthibaud
Whiteboard: [reporter-external] [client-bounty-form] [verif?] → [reporter-external] [client-bounty-form] [verif?] [group4]
Duplicate of this bug: 1883468
Duplicate of this bug: 1885793

Comment on attachment 9398329 [details]
Bug 1871214 - improve share interaction with fullscreen

Security Approval Request

  • How easily could an exploit be constructed based on the patch?: It would be quite difficult. It's a one line change to exit fullscreen before the share dialog is shown and there is no indication in the code as to why we are doing that.
    Even if a malicious actor figured out how to exploit this, it would be a lot of work to take advantage of it. They would need to build a website that perfectly mimicked the firefox android chrome. It would be difficult to get something web based that looked exactly like the android native ui components across a range of android OS versions and manufacturers, where there are a lot of visual differences.
  • Do comments in the patch, the check-in comment, or tests included in the patch paint a bulls-eye on the security problem?: No
  • Which branches (beta, release, and/or ESR) are affected by this flaw, and do the release status flags reflect this affected/unaffected state correctly?: all of these, and yes
  • If not all supported branches, which bug introduced the flaw?: n/a
  • Do you have backports for the affected branches?: No
  • If not, how different, hard to create, and risky will they be?:
  • How likely is this patch to cause regressions; how much testing does it need?: It's a very small change and we don't think it's very risky, but would be great to test a bit around sharing.
  • Is the patch ready to land after security approval is given?: Yes
  • Is Android affected?: Yes
Attachment #9398329 - Flags: sec-approval?
Assignee: tthibaud → polly

Priority P1 because this bug has been assigned to a squad/group.

Priority: P2 → P1

Why do we have the fullscreen toast buried at the bottom of the screen? If it were at the top it wouldn't be behind many of the OS permission prompts (though that could change on different Android versions). And on modern tall-and-skinny Android phones it's very easy to miss things happening at the other end of the phone from where your attention is. We don't want what is supposed to be an attention-grabbing notification playing wallflower near the edge of the screen—it could move more toward the center. And consider making the placement depend on where the user is interacting with the content and show the toast at the top or bottom according to which is closer to that interaction.

There's no OS where people double-click on buttons. The need for two clicks means you need to construct an engaging spoof and that limits the impact to those who will engage with the content; sec-high bugs require "normal web interaction". I'm lowering the severity here to sec-moderate.

Keywords: sec-highsec-moderate

Comment on attachment 9398329 [details]
Bug 1871214 - improve share interaction with fullscreen

sec-approval+ = dveditz

Attachment #9398329 - Flags: sec-approval? → sec-approval+

Thanks Daniel for the update!
We could move the full screen notification message, we provide this ui in the Fenix code. However, on Android it is more common to get important system notification messages delivered to the bottom of the screen, as this is usually where a user's eyes and thumbs are focused - see material design docs here. So I am inclined to leave it where it is.
It's an interesting idea to place it based on where the user is interacting most with the content, but i'm not sure how we would best determine the location of maximal interaction, and i wonder if it would have as much impact if the notification moved between top or bottom of the screen.
I am hoping this is ok as you have already given sec approval but happy to discuss further if you would like!

Pushed by pmceldowney@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/04a668ef9c90 improve share interaction with fullscreen r=android-reviewers,twhite
Group: mobile-core-security → core-security-release
Status: NEW → RESOLVED
Closed: 5 months ago
Resolution: --- → FIXED
Target Milestone: --- → 127 Branch

The patch landed in nightly and beta is affected.
:pollymce, is this bug important enough to require an uplift?

  • If yes, please nominate the patch for beta approval.
  • If no, please set status-firefox126 to wontfix.

For more information, please visit BugBot documentation.

Flags: needinfo?(polly)

I think based on Daniel's comment above: https://bugzilla.mozilla.org/show_bug.cgi?id=1871214#c11
this probably doesn't require an uplift as it's been marked sec-moderate. But please chip in if you disagree!

Flags: needinfo?(polly) → needinfo?(dveditz)

(In reply to Polly McEldowney [:pollymce] from comment #17)

I think based on Daniel's comment above: https://bugzilla.mozilla.org/show_bug.cgi?id=1871214#c11
this probably doesn't require an uplift as it's been marked sec-moderate. But please chip in if you disagree!

For security bugs, we aim to uplift them to beta so the delta of exposure is lowered. (difference in time landing in central to being released)

ah ok - thanks for the clarification Donal! i'll sort that out now :)

Flags: needinfo?(dveditz)
Attachment #9399369 - Flags: approval-mozilla-beta?

beta Uplift Approval Request

  • User impact if declined: sec bug would still exist
  • Code covered by automated testing: no
  • Fix verified in Nightly: yes
  • Needs manual QE test: yes
  • Steps to reproduce for manual QE testing: described in bug
  • Risk associated with taking this patch: low
  • Explanation of risk level: it's a small one line change
  • String changes made/needed: no
  • Is Android affected?: yes
Flags: qe-verify+
Attachment #9399368 - Attachment is obsolete: true
Attachment #9399369 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Whiteboard: [reporter-external] [client-bounty-form] [verif?] [group4] → [reporter-external] [client-bounty-form] [verif?] [group4][qa-triaged]
Flags: sec-bounty? → sec-bounty+
Whiteboard: [reporter-external] [client-bounty-form] [verif?] [group4][qa-triaged] → [reporter-external] [client-bounty-form] [verif?] [group4][qa-triaged] [adv-main126+]
Alias: CVE-2024-4766
Group: core-security-release

Verified as fixed on the Fenix Nightly 132.0a1 from 9/23 with Google Pixel 6 (Andorid 15).

Status: RESOLVED → VERIFIED
Flags: qe-verify+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: