Closed Bug 1987929 Opened 1 year ago Closed 10 months ago

PointerEvent.persistentDeviceId maybe leaks pen inputs with RFP

Categories

(Core :: DOM: UI Events & Focus Handling, defect)

defect

Tracking

()

RESOLVED FIXED
146 Branch
Tracking Status
firefox-esr115 --- unaffected
firefox-esr128 --- unaffected
firefox-esr140 --- unaffected
firefox142 --- wontfix
firefox143 --- wontfix
firefox144 --- wontfix
firefox145 --- wontfix
firefox146 --- fixed

People

(Reporter: pierov, Assigned: pierov)

References

(Regression)

Details

(Keywords: regression)

Attachments

(1 file)

According to the code, persistentDeviceId will be 1 for mouse events, 0 otherwise.
I wonder if this could leak pen events, for example. However, I won't access to my drawing table for a while to check if it's actually the case.
FWIW, other methods have a check on ShouldResistFingerprinting first.

Notice that if pointerType isn't spoofed, this is just equivalency.
So, if the idea is that we don't want to spoof the type, this can be closed.

Set release status flags based on info from the regressing bug 1968400

:smaug, since you are the author of the regressor, bug 1968400, could you take a look? Also, could you set the severity field?

For more information, please visit BugBot documentation.

Currently, it returns only 0 or 1. We haven't implemented it under widget/ to make web apps possible to distinguish physical pens.

Flags: needinfo?(smaug)

I've managed to have this tested.
Under RFP, we report both the actual pointer type and persistentDeviceId consistently.
However, everything about pens (angles, pressure, etc...) is spoofed.
So, I think it'd make sense to disguise pens as mouse on desktop.
I would say it'd make sense to disguise both pens and mice as touch on Android, but this would be detectable, as touch will also trigger touchstart, touchend and touchmove events, whereas mice currently don't do it (I tested MDN's example with a bluetooth mouse on my phone).
I didn't think of testing that example also on desktop, maybe I'll be able to do it later.

Severity: -- → S3

The pen features (pressure, angles, etc...) are already spoofed.
However, we still tell that the input comes from a pen.
At this point, we can pretend it came from a mouse.

Assignee: nobody → pierov
Status: NEW → ASSIGNED

Landing for pierov.

Backed out for causing perma failures @test_pointer_event.html.

Flags: needinfo?(pierov)

Sent new revisions, but tjr is currently out, so I think this will have to wait a little bit.
FWIW, from the try build everything seems fine now to me: https://treeherder.mozilla.org/jobs?repo=try&revision=9d511d1287b9cfe5ae45252e425ecebdc7246ce2

Flags: needinfo?(pierov)
Status: ASSIGNED → RESOLVED
Closed: 10 months ago
Resolution: --- → FIXED
Target Milestone: --- → 146 Branch

Since nightly and release are affected, beta will likely be affected too.
For more information, please visit BugBot documentation.

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

For more information, please visit BugBot documentation.

Flags: needinfo?(pierov)
Flags: needinfo?(pierov)
QA Whiteboard: [qa-triage-done-c147/b146]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: