From c266715fc55276d767a1832db3558bd37a80cfba Mon Sep 17 00:00:00 2001 From: Helen Date: Thu, 10 Aug 2023 13:17:21 +0300 Subject: [PATCH 1/5] update create-own-filters.md removed examples with `sync-xhr`, `oversized-images` and other directives not listed in the Permissions-Policy --- docs/general/ad-filtering/create-own-filters.md | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/docs/general/ad-filtering/create-own-filters.md b/docs/general/ad-filtering/create-own-filters.md index cf6603fe611..afb598ad792 100644 --- a/docs/general/ad-filtering/create-own-filters.md +++ b/docs/general/ad-filtering/create-own-filters.md @@ -1527,11 +1527,8 @@ The list of the available directives is available [here](https://developer.mozil **Examples** -* `||example.org^$permissions=sync-xhr=()` disallows synchronous `XMLHttpRequest` requests across `example.org`. -* `@@||example.org/page/*$permissions=sync-xhr=()` disables all rules with the `$permissions` modifier exactly matching `sync-xhr=()` on all the pages matching the rule pattern. For instance, the rule above. * `@@||example.org/page/*$permissions` disables all the `$permissions` rules on all the pages matching the rule pattern. -* `$domain=example.org|example.com,permissions=oversized-images=()\, sync-script=()\, unsized-media=()` disallows oversized images, synchronous scripts and unsized media features across `example.org` and `example.com`. -* `@@||example.org^$document` or `@@||example.org^$urlblock` disables all the `$permission` rules on all the pages matching the rule pattern. +* `@@||example.org^$document` or `@@||example.org^$urlblock` disables all the `$permissions` rules on all the pages matching the rule pattern. :::caution Limitations From 9f99a472066c7c5a8b96d6fe58fce3e8ba3717a0 Mon Sep 17 00:00:00 2001 From: Helen Date: Thu, 10 Aug 2023 13:25:54 +0300 Subject: [PATCH 2/5] Revert "update create-own-filters.md" This reverts commit c266715fc55276d767a1832db3558bd37a80cfba. --- docs/general/ad-filtering/create-own-filters.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/docs/general/ad-filtering/create-own-filters.md b/docs/general/ad-filtering/create-own-filters.md index afb598ad792..cf6603fe611 100644 --- a/docs/general/ad-filtering/create-own-filters.md +++ b/docs/general/ad-filtering/create-own-filters.md @@ -1527,8 +1527,11 @@ The list of the available directives is available [here](https://developer.mozil **Examples** +* `||example.org^$permissions=sync-xhr=()` disallows synchronous `XMLHttpRequest` requests across `example.org`. +* `@@||example.org/page/*$permissions=sync-xhr=()` disables all rules with the `$permissions` modifier exactly matching `sync-xhr=()` on all the pages matching the rule pattern. For instance, the rule above. * `@@||example.org/page/*$permissions` disables all the `$permissions` rules on all the pages matching the rule pattern. -* `@@||example.org^$document` or `@@||example.org^$urlblock` disables all the `$permissions` rules on all the pages matching the rule pattern. +* `$domain=example.org|example.com,permissions=oversized-images=()\, sync-script=()\, unsized-media=()` disallows oversized images, synchronous scripts and unsized media features across `example.org` and `example.com`. +* `@@||example.org^$document` or `@@||example.org^$urlblock` disables all the `$permission` rules on all the pages matching the rule pattern. :::caution Limitations From 95f24bffeeba4159bc27ee889f2dc4a30f713314 Mon Sep 17 00:00:00 2001 From: Helen Date: Thu, 10 Aug 2023 14:43:22 +0300 Subject: [PATCH 3/5] update examples of directives --- docs/general/ad-filtering/create-own-filters.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/general/ad-filtering/create-own-filters.md b/docs/general/ad-filtering/create-own-filters.md index cf6603fe611..35119e6e0e3 100644 --- a/docs/general/ad-filtering/create-own-filters.md +++ b/docs/general/ad-filtering/create-own-filters.md @@ -1527,10 +1527,10 @@ The list of the available directives is available [here](https://developer.mozil **Examples** -* `||example.org^$permissions=sync-xhr=()` disallows synchronous `XMLHttpRequest` requests across `example.org`. -* `@@||example.org/page/*$permissions=sync-xhr=()` disables all rules with the `$permissions` modifier exactly matching `sync-xhr=()` on all the pages matching the rule pattern. For instance, the rule above. +* `||example.org^$permissions=autoplay=()` disallows autoplay media requested through the `HTMLMediaElement` interface across `example.org`. +* `@@||example.org/page/*$permissions=autoplay=()` disables all rules with the `$permissions` modifier exactly matching `autoplay=()` on all the pages matching the rule pattern. For instance, the rule above. * `@@||example.org/page/*$permissions` disables all the `$permissions` rules on all the pages matching the rule pattern. -* `$domain=example.org|example.com,permissions=oversized-images=()\, sync-script=()\, unsized-media=()` disallows oversized images, synchronous scripts and unsized media features across `example.org` and `example.com`. +* `$domain=example.org|example.com,permissions=storage-access=()\, сamera=()\, display-capture=()` disallows using the Storage Access API to request access to unpartitioned cookies, using video input devices, and using the getDisplayMedia() method to capture screen contents across `example.org` and `example.com`. * `@@||example.org^$document` or `@@||example.org^$urlblock` disables all the `$permission` rules on all the pages matching the rule pattern. :::caution Limitations From 1c385f23b54d5b2125af1b6c95fa8940d97ab518 Mon Sep 17 00:00:00 2001 From: Helen Date: Thu, 10 Aug 2023 14:45:34 +0300 Subject: [PATCH 4/5] shorten one of examples --- docs/general/ad-filtering/create-own-filters.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/general/ad-filtering/create-own-filters.md b/docs/general/ad-filtering/create-own-filters.md index 35119e6e0e3..78052a2cfee 100644 --- a/docs/general/ad-filtering/create-own-filters.md +++ b/docs/general/ad-filtering/create-own-filters.md @@ -1530,7 +1530,7 @@ The list of the available directives is available [here](https://developer.mozil * `||example.org^$permissions=autoplay=()` disallows autoplay media requested through the `HTMLMediaElement` interface across `example.org`. * `@@||example.org/page/*$permissions=autoplay=()` disables all rules with the `$permissions` modifier exactly matching `autoplay=()` on all the pages matching the rule pattern. For instance, the rule above. * `@@||example.org/page/*$permissions` disables all the `$permissions` rules on all the pages matching the rule pattern. -* `$domain=example.org|example.com,permissions=storage-access=()\, сamera=()\, display-capture=()` disallows using the Storage Access API to request access to unpartitioned cookies, using video input devices, and using the getDisplayMedia() method to capture screen contents across `example.org` and `example.com`. +* `$domain=example.org|example.com,permissions=storage-access=()\, сamera=()` disallows using the Storage Access API to request access to unpartitioned cookies and using video input devices across `example.org` and `example.com`. * `@@||example.org^$document` or `@@||example.org^$urlblock` disables all the `$permission` rules on all the pages matching the rule pattern. :::caution Limitations From 93b95a7cb1438e2b71fc0b54fd13426459d52e47 Mon Sep 17 00:00:00 2001 From: Helen Date: Thu, 10 Aug 2023 15:01:54 +0300 Subject: [PATCH 5/5] removed extra space --- docs/general/ad-filtering/create-own-filters.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/general/ad-filtering/create-own-filters.md b/docs/general/ad-filtering/create-own-filters.md index 78052a2cfee..7c502cb6be6 100644 --- a/docs/general/ad-filtering/create-own-filters.md +++ b/docs/general/ad-filtering/create-own-filters.md @@ -1527,7 +1527,7 @@ The list of the available directives is available [here](https://developer.mozil **Examples** -* `||example.org^$permissions=autoplay=()` disallows autoplay media requested through the `HTMLMediaElement` interface across `example.org`. +* `||example.org^$permissions=autoplay=()` disallows autoplay media requested through the `HTMLMediaElement` interface across `example.org`. * `@@||example.org/page/*$permissions=autoplay=()` disables all rules with the `$permissions` modifier exactly matching `autoplay=()` on all the pages matching the rule pattern. For instance, the rule above. * `@@||example.org/page/*$permissions` disables all the `$permissions` rules on all the pages matching the rule pattern. * `$domain=example.org|example.com,permissions=storage-access=()\, сamera=()` disallows using the Storage Access API to request access to unpartitioned cookies and using video input devices across `example.org` and `example.com`.