From 33e4934e8309184fed6443e3726463d1612bf4a0 Mon Sep 17 00:00:00 2001 From: Marcos Caceres Date: Fri, 17 Oct 2025 14:05:21 +0800 Subject: [PATCH 1/4] Fix Issue #243: Add continuous monitoring for pre-lock conditions - Added monitoring step in 'apply orientation lock' algorithm - Ensures pre-lock conditions (fullscreen, installed app status) are continuously checked - Automatically runs 'fully unlock' steps when conditions no longer hold - Provides general catch-all beyond existing Fullscreen API integration - Improves user experience and security by preventing stale orientation locks Fixes #243 --- index.html | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/index.html b/index.html index 5b5f19c..5760d0d 100644 --- a/index.html +++ b/index.html @@ -668,6 +668,10 @@

`null`, [=reject and nullify the current lock promise=] of |document| with an {{"AbortError"}}. +
  • If any [=pre-lock conditions=] are no longer met while [=in + parallel=], run the [=fully unlock the screen orientation steps=] + with |document|. +
  • Let |topDocument| be |document|'s [=top-level browsing context=]'s [=navigable/active document=].
  • From 8657a498ae8910ba75812d65d879fa41a2d067d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marcos=20C=C3=A1ceres?= Date: Tue, 21 Oct 2025 12:24:50 +0800 Subject: [PATCH 2/4] Update index.html Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- index.html | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/index.html b/index.html index aeb289b..156965f 100644 --- a/index.html +++ b/index.html @@ -669,9 +669,7 @@

    `null`, [=reject and nullify the current lock promise=] of |document| with an {{"AbortError"}}. -
  • If any [=pre-lock conditions=] are no longer met while [=in - parallel=], run the [=fully unlock the screen orientation steps=] - with |document|. +
  • [=In parallel=], if any [=pre-lock conditions=] are no longer met, run the [=fully unlock the screen orientation steps=] with |document|.
  • Let |topDocument| be |document|'s [=top-level browsing context=]'s [=navigable/active document=]. From 7b01cabc445939a5d9b9cff222a605fbf519a3af Mon Sep 17 00:00:00 2001 From: Marcos Caceres Date: Tue, 21 Oct 2025 12:26:08 +0800 Subject: [PATCH 3/4] tidy --- index.html | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/index.html b/index.html index 156965f..e648542 100644 --- a/index.html +++ b/index.html @@ -669,7 +669,8 @@

    `null`, [=reject and nullify the current lock promise=] of |document| with an {{"AbortError"}}.

  • -
  • [=In parallel=], if any [=pre-lock conditions=] are no longer met, run the [=fully unlock the screen orientation steps=] with |document|. +
  • [=In parallel=], if any [=pre-lock conditions=] are no longer met, + run the [=fully unlock the screen orientation steps=] with |document|.
  • Let |topDocument| be |document|'s [=top-level browsing context=]'s [=navigable/active document=]. @@ -945,14 +946,14 @@

    The requirement for [=documents=] to be [=Document/fully active - descendant of a top-level traversable with user attention=] ensures that - orientation events are only delivered to - documents in windows that are both visible at the system level and have - the user's attention (either through focus or the ability to receive - keyboard input). The additional visibility state check provides defense - in depth. These restrictions prevent background tabs, hidden windows, - and minimized applications from collecting orientation data for - fingerprinting purposes. + descendant of a top-level traversable with user attention=] ensures + that orientation events are only delivered to documents in windows that + are both visible at the system level and have the user's attention + (either through focus or the ability to receive keyboard input). The + additional visibility state check provides defense in depth. These + restrictions prevent background tabs, hidden windows, and minimized + applications from collecting orientation data for fingerprinting + purposes.

    Anti-fingerprinting Mitigations From 8c197446b33f240275642d00758cfb9b1de1321c Mon Sep 17 00:00:00 2001 From: Marcos Caceres Date: Mon, 16 Feb 2026 13:14:29 +1100 Subject: [PATCH 4/4] Match fullscreen spec changes --- index.html | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/index.html b/index.html index de4a75b..5245573 100644 --- a/index.html +++ b/index.html @@ -882,10 +882,15 @@

    A user agent MUST restrict the use of {{ScreenOrientation/lock()}} to - simple fullscreen documents as a [=pre-lock condition=]. This + [=simple fullscreen documents=] as a [=pre-lock condition=]. This requirement prevents fingerprinting through differences in user agent behavior regarding orientation locking permissions. [[fullscreen]]

    +

    + If a [=document=] [=Document/has pending fullscreen request=], the user + agent MUST await the [=Document/pending fullscreen request promise=] + before evaluating the [=pre-lock conditions=]. [[fullscreen]] +

    When a [=document=] exits fullscreen, it also runs the [=fully unlock the screen orientation steps=]. [[fullscreen]]