File tree Expand file tree Collapse file tree 4 files changed +67
-0
lines changed Expand file tree Collapse file tree 4 files changed +67
-0
lines changed Original file line number Diff line number Diff line change 1+ {
2+ "_meta" : {
3+ "description" : " Request blocking rules necessary to fix website breakage. Note: Tracker request blocking is handled elsewhere." ,
4+ "sampleExcludeRecords" : {
5+ "domain" : " example.com" ,
6+ "reason" : " site breakage"
7+ }
8+ },
9+ "state" : " enabled" ,
10+ "settings" : {
11+ "blockedRequests" : {
12+ "privacy-test-pages.site" : {
13+ "rules" : [
14+ {
15+ "rule" : " privacy-test-pages.site/privacy-protections/request-blocklist/*?block=true" ,
16+ "domains" : [
17+ " privacy-test-pages.site"
18+ ],
19+ "reason" : " Testing rule for the privacy test page, see https://privacy-test-pages.site/privacy-protections/request-blocklist/"
20+ }
21+ ]
22+ },
23+ "third-party.site" : {
24+ "rules" : [
25+ {
26+ "rule" : " third-party.site/privacy-protections/request-blocklist/*?block=true" ,
27+ "domains" : [
28+ " privacy-test-pages.site"
29+ ],
30+ "reason" : " Testing rule for the privacy test page, see https://privacy-test-pages.site/privacy-protections/request-blocklist/"
31+ }
32+ ]
33+ }
34+ }
35+ },
36+ "exceptions" : []
37+ }
Original file line number Diff line number Diff line change 99 "state" : " enabled" ,
1010 "settings" : {
1111 "allowlistedTrackers" : {
12+ "third-party.site" : {
13+ "rules" : [
14+ {
15+ "rule" : " allowlisted.third-party.site" ,
16+ "domains" : [
17+ " privacy-test-pages.site"
18+ ],
19+ "reason" : " Testing rule for the privacy test pages"
20+ }
21+ ]
22+ },
1223 "2mdn.net" : {
1324 "rules" : [
1425 {
Original file line number Diff line number Diff line change @@ -22,6 +22,7 @@ import { BurnFeature } from './features/burn';
2222import { Taskbar } from './features/taskbar' ;
2323import { AppHealth } from './features/appHealth' ;
2424import { ElementHidingFeature } from './features/element-hiding' ;
25+ import { RequestBlocklistFeature } from './features/request-blocklist' ;
2526
2627export { WebCompatSettings } from './features/webcompat' ;
2728export { DuckPlayerSettings } from './features/duckplayer' ;
@@ -68,6 +69,7 @@ export type ConfigV5<VersionType> = {
6869 windowsWebviewFailures_DDGWV ?: WindowsWebViewFailures < VersionType > ;
6970 customUserAgent ?: CustomUserAgentFeature < VersionType > ;
7071 elementHiding ?: ElementHidingFeature < VersionType > ;
72+ requestBlocklist ?: RequestBlocklistFeature < VersionType > ;
7173 } ;
7274 unprotectedTemporary : SiteException [ ] ;
7375} ;
Original file line number Diff line number Diff line change 1+ import { Feature } from '../feature' ;
2+
3+ type RuleType = {
4+ rule : string ;
5+ domains : string [ ] ;
6+ reason : string [ ] | string ;
7+ } ;
8+
9+ type SettingsType = {
10+ blockedRequests : {
11+ [ domain : string ] : {
12+ rules : RuleType [ ] ;
13+ } ;
14+ } ;
15+ } ;
16+
17+ export type RequestBlocklistFeature < VersionType > = Feature < SettingsType , VersionType > ;
You can’t perform that action at this time.
0 commit comments