@duckduckgo/autoconsent 16.62.0 → 17.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +84 -0
- package/dist/addon-firefox/background.bundle.js +1 -0
- package/dist/addon-firefox/compact-rules.json +1 -1
- package/dist/addon-firefox/content.bundle.js +176 -36
- package/dist/addon-firefox/manifest.json +1 -1
- package/dist/addon-firefox/popup.bundle.js +1 -0
- package/dist/addon-firefox/rule-index.json +1 -1
- package/dist/addon-firefox/rules.json +1 -1
- package/dist/addon-mv3/background.bundle.js +1 -0
- package/dist/addon-mv3/compact-rules.json +1 -1
- package/dist/addon-mv3/content.bundle.js +176 -36
- package/dist/addon-mv3/manifest.json +1 -1
- package/dist/addon-mv3/popup.bundle.js +1 -0
- package/dist/addon-mv3/rule-index.json +1 -1
- package/dist/addon-mv3/rules.json +1 -1
- package/dist/autoconsent.cjs.js +176 -36
- package/dist/autoconsent.esm.js +176 -36
- package/dist/autoconsent.playwright.js +179 -36
- package/dist/autoconsent.standalone.js +177 -37
- package/dist/heuristics.cjs.js +14 -1
- package/dist/heuristics.mjs +14 -1
- package/dist/types/heuristics.d.ts +12 -3
- package/dist/types/types.d.ts +12 -1
- package/lib/cmps/base.ts +5 -1
- package/lib/heuristic-patterns.ts +17 -1
- package/lib/heuristics.ts +240 -45
- package/lib/types.ts +16 -1
- package/lib/utils.ts +1 -0
- package/package.json +2 -2
- package/readme.md +1 -1
- package/rules/autoconsent/appconsent-legacy.json +22 -1
- package/rules/autoconsent/asrock.json +44 -0
- package/rules/autoconsent/beetle-tracking.json +22 -0
- package/rules/autoconsent/casier-judiciaire-justice-gouv-fr.json +40 -0
- package/rules/autoconsent/civilservicejobs-service-gov-uk.json +38 -0
- package/rules/autoconsent/ckies.json +1 -1
- package/rules/autoconsent/consentmo.json +5 -2
- package/rules/autoconsent/cookie-script.json +34 -15
- package/rules/autoconsent/cookiesinfo-closecookies.json +9 -0
- package/rules/autoconsent/dack365.json +35 -0
- package/rules/autoconsent/epaas.json +18 -1
- package/rules/autoconsent/eu-cookie-law-popup.json +33 -0
- package/rules/autoconsent/fascicolosanitario-lombardia.json +14 -0
- package/rules/autoconsent/fnsp-cookieconsent.json +30 -0
- package/rules/autoconsent/fod-fujitv.json +13 -0
- package/rules/autoconsent/fundingchoices.json +12 -2
- package/rules/autoconsent/hkdir.json +33 -0
- package/rules/autoconsent/hyrabostad.json +21 -0
- package/rules/autoconsent/insided.json +15 -0
- package/rules/autoconsent/jokul-cookie-consent.json +28 -0
- package/rules/autoconsent/kartverket.json +46 -0
- package/rules/autoconsent/lego.json +27 -5
- package/rules/autoconsent/luxmed.json +33 -0
- package/rules/autoconsent/mars-cookies-prompt.json +20 -0
- package/rules/autoconsent/meta-cookie-dialog.json +37 -0
- package/rules/autoconsent/mittanbud.json +33 -0
- package/rules/autoconsent/niedziela-pl.json +35 -0
- package/rules/autoconsent/nikkeibp.json +10 -0
- package/rules/autoconsent/onecom-cookie-banner.json +25 -0
- package/rules/autoconsent/oslosportslager.no.json +34 -0
- package/rules/autoconsent/plex.tv.json +52 -0
- package/rules/autoconsent/poki.json +37 -0
- package/rules/autoconsent/polisen-se.json +26 -0
- package/rules/autoconsent/radio-canada.json +28 -0
- package/rules/autoconsent/regjeringen.no.json +13 -0
- package/rules/autoconsent/roll20.json +50 -0
- package/rules/autoconsent/romeo.json +47 -0
- package/rules/autoconsent/sirdata.json +8 -3
- package/rules/autoconsent/site-notifications-cookie-usage.json +25 -0
- package/rules/autoconsent/sparebank1-optin.json +10 -0
- package/rules/autoconsent/stockholm-stad.json +42 -0
- package/rules/autoconsent/stright.json +19 -1
- package/rules/autoconsent/stripchat.com.json +26 -5
- package/rules/autoconsent/tri-table.json +6 -2
- package/rules/autoconsent/tvp.json +27 -0
- package/rules/autoconsent/urvaerket.json +33 -0
- package/rules/autoconsent/vinnova-se.json +50 -0
- package/rules/autoconsent/volvocars-com.json +23 -2
- package/rules/autoconsent/vortex-consent.json +33 -0
- package/rules/autoconsent/vue-cookie-accept-decline.json +42 -0
- package/rules/compact-rules.json +1 -1
- package/rules/rule-index.json +1 -1
- package/rules/rules.json +1 -1
- package/tests/appconsent-legacy.spec.ts +1 -1
- package/tests/asrock.spec.ts +3 -0
- package/tests/beetle-tracking.spec.ts +3 -0
- package/tests/casier-judiciaire-justice-gouv-fr.spec.ts +3 -0
- package/tests/civilservicejobs-service-gov-uk.spec.ts +3 -0
- package/tests/consentmo.spec.ts +2 -0
- package/tests/cookie-script.spec.ts +5 -0
- package/tests/cookiesinfo-closecookies.spec.ts +8 -0
- package/tests/dack365.spec.ts +3 -0
- package/tests/epaas.spec.ts +3 -0
- package/tests/eu-cookie-law-popup.spec.ts +8 -0
- package/tests/fascicolosanitario-lombardia.spec.ts +3 -0
- package/tests/fnsp-cookieconsent.spec.ts +9 -0
- package/tests/fod-fujitv.spec.ts +3 -0
- package/tests/fundingchoices.spec.ts +7 -1
- package/tests/hkdir.spec.ts +10 -0
- package/tests/hyrabostad.spec.ts +3 -0
- package/tests/insided.spec.ts +9 -0
- package/tests/jokul-cookie-consent.spec.ts +3 -0
- package/tests/kartverket.spec.ts +3 -0
- package/tests/luxmed.spec.ts +3 -0
- package/tests/mars-cookies-prompt.spec.ts +3 -0
- package/tests/meta-cookie-dialog.spec.ts +14 -0
- package/tests/mittanbud.spec.ts +3 -0
- package/tests/niedziela-pl.spec.ts +3 -0
- package/tests/nikkeibp.spec.ts +8 -0
- package/tests/onecom-cookie-banner.spec.ts +5 -0
- package/tests/oslosportslager.no.spec.ts +3 -0
- package/tests/plex.tv.spec.ts +5 -0
- package/tests/poki.spec.ts +6 -0
- package/tests/polisen-se.spec.ts +3 -0
- package/tests/radio-canada.spec.ts +15 -0
- package/tests/regjeringen.no.spec.ts +3 -0
- package/tests/roll20.spec.ts +3 -0
- package/tests/romeo.spec.ts +3 -0
- package/tests/sirdata.spec.ts +13 -1
- package/tests/site-notifications-cookie-usage.spec.ts +3 -0
- package/tests/sparebank1-optin.spec.ts +8 -0
- package/tests/stockholm-stad.spec.ts +7 -0
- package/tests/stright.spec.ts +11 -0
- package/tests/stripchat.com.spec.ts +4 -1
- package/tests/tri-table.spec.ts +1 -1
- package/tests/tvp.spec.ts +3 -0
- package/tests/urvaerket.spec.ts +13 -0
- package/tests/vinnova-se.spec.ts +6 -0
- package/tests/volvocars-com.spec.ts +1 -1
- package/tests/vortex-consent.spec.ts +18 -0
- package/tests/vue-cookie-accept-decline.spec.ts +8 -0
- package/tests-wtr/heuristics/get-actionable-popups.ts +41 -7
- package/tests-wtr/heuristics/get-potential-popups.test.ts +235 -4
- package/tests-wtr/heuristics/heuristic-cmp.ts +16 -1
- package/tests-wtr/heuristics/heuristics-utils.test.ts +49 -0
- package/rules/generated/auto_CA_plex.tv_ee4.json +0 -40
- package/rules/generated/auto_CA_support.plex.tv_gn3.json +0 -40
- package/tests/generated/auto_CA_plex.tv_ee4.spec.ts +0 -2
- package/tests/generated/auto_CA_support.plex.tv_gn3.spec.ts +0 -6
|
@@ -2,25 +2,46 @@
|
|
|
2
2
|
"name": "stripchat.com",
|
|
3
3
|
"vendorUrl": "https://unknown",
|
|
4
4
|
"cosmetic": false,
|
|
5
|
-
"prehideSelectors": ["
|
|
5
|
+
"prehideSelectors": ["[data-testid=\"CookiesReminder\"]"],
|
|
6
6
|
"detectCmp": [
|
|
7
7
|
{
|
|
8
|
-
"
|
|
8
|
+
"visible": "[data-testid=\"CookiesReminder\"] [data-testid=\"CookiesManage\"]"
|
|
9
9
|
}
|
|
10
10
|
],
|
|
11
11
|
"detectPopup": [
|
|
12
12
|
{
|
|
13
|
-
"visible": "
|
|
13
|
+
"visible": "[data-testid=\"CookiesReminder\"]"
|
|
14
14
|
}
|
|
15
15
|
],
|
|
16
16
|
"optIn": [
|
|
17
17
|
{
|
|
18
|
-
"waitForThenClick": "
|
|
18
|
+
"waitForThenClick": "[data-testid=\"CookiesReminder\"] [data-testid=\"CookiesAcceptAll\"]"
|
|
19
19
|
}
|
|
20
20
|
],
|
|
21
21
|
"optOut": [
|
|
22
22
|
{
|
|
23
|
-
"
|
|
23
|
+
"waitFor": "body:not(.disable-transition)",
|
|
24
|
+
"timeout": 5000,
|
|
25
|
+
"optional": true
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
"waitForThenClick": "[data-testid=\"CookiesReminder\"] [data-testid=\"CookiesManage\"]"
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
"waitForVisible": "dialog[open] .cookies-select-modal",
|
|
32
|
+
"timeout": 1500,
|
|
33
|
+
"optional": true
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
"if": {
|
|
37
|
+
"visible": "dialog[open] .cookies-select-modal",
|
|
38
|
+
"check": "none"
|
|
39
|
+
},
|
|
40
|
+
"then": [
|
|
41
|
+
{
|
|
42
|
+
"click": "[data-testid=\"CookiesReminder\"] [data-testid=\"CookiesManage\"]"
|
|
43
|
+
}
|
|
44
|
+
]
|
|
24
45
|
},
|
|
25
46
|
{
|
|
26
47
|
"waitForThenClick": "dialog[open] .cookies-select-modal .cookies-select-modal__buttons .ds-btn-apply-2-ds"
|
|
@@ -7,8 +7,12 @@
|
|
|
7
7
|
"optIn": [{ "waitForThenClick": "[class^=\"app_gdpr--\"] div > button:last-of-type:nth-of-type(2)" }],
|
|
8
8
|
"optOut": [
|
|
9
9
|
{ "waitForThenClick": "[class^=\"app_gdpr--\"] div > button:first-of-type:nth-last-of-type(2)", "retry": 2, "retryInterval": 500 },
|
|
10
|
-
{
|
|
10
|
+
{
|
|
11
|
+
"if": { "exists": "[class^=\"app_gdpr--\"] div > button:nth-of-type(2):nth-last-of-type(2)" },
|
|
12
|
+
"then": [{ "click": "[class^=\"app_gdpr--\"] div > button:nth-of-type(2):nth-last-of-type(2)" }],
|
|
13
|
+
"else": [{ "click": "[class^=\"app_gdpr--\"] div > button:first-of-type:nth-last-of-type(2)", "optional": true }]
|
|
14
|
+
},
|
|
11
15
|
{ "waitForVisible": "[class^=\"app_gdpr--\"] button", "check": "none" }
|
|
12
16
|
],
|
|
13
|
-
"test": [{ "cookieContains": "tt_cons_addtl=" }]
|
|
17
|
+
"test": [{ "any": [{ "cookieContains": "tt_cons_addtl=" }, { "cookieContains": "pubConsent=" }] }]
|
|
14
18
|
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "tvp",
|
|
3
|
+
"_metadata": {
|
|
4
|
+
"vendorUrl": "https://polityka-prywatnosci.tvp.pl/"
|
|
5
|
+
},
|
|
6
|
+
"cosmetic": false,
|
|
7
|
+
"runContext": {
|
|
8
|
+
"main": true,
|
|
9
|
+
"frame": false,
|
|
10
|
+
"urlPattern": "^https?://(\\w+\\.)?tvp\\.pl/"
|
|
11
|
+
},
|
|
12
|
+
"prehideSelectors": [".tvp-cookie-overlay"],
|
|
13
|
+
"detectCmp": [{ "exists": ".tvp-cookie-overlay .tvp-covl" }],
|
|
14
|
+
"detectPopup": [{ "visible": ".tvp-cookie-overlay .tvp-covl" }],
|
|
15
|
+
"optIn": [{ "waitForThenClick": ".tvp-covl .tvp-covl__ab" }],
|
|
16
|
+
"optOut": [
|
|
17
|
+
{ "waitForThenClick": ".tvp-covl .tvp-covl__sb" },
|
|
18
|
+
{ "waitFor": ".tvp-covl .tvp-covl__save" },
|
|
19
|
+
{
|
|
20
|
+
"if": { "exists": ".tvp-covl input.iabd:not(:checked)" },
|
|
21
|
+
"then": [{ "click": ".tvp-covl input.iabd" }]
|
|
22
|
+
},
|
|
23
|
+
{ "click": ".tvp-covl .tvp-covl__save" },
|
|
24
|
+
{ "waitForVisible": ".tvp-cookie-overlay .tvp-covl", "check": "none", "timeout": 2000, "optional": true }
|
|
25
|
+
],
|
|
26
|
+
"test": [{ "cookieContains": "TVPtcs22=" }]
|
|
27
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "urvaerket",
|
|
3
|
+
"vendorUrl": "https://www.urvaerket.dk/",
|
|
4
|
+
"runContext": {
|
|
5
|
+
"urlPattern": "^https?://(www\\.)?(urvaerket\\.dk|uret\\.se|urverket\\.no|laatukellot\\.fi|thewatchagency\\.com)/"
|
|
6
|
+
},
|
|
7
|
+
"prehideSelectors": ["app-cookie-consent > .cookie-banner"],
|
|
8
|
+
"detectCmp": [
|
|
9
|
+
{
|
|
10
|
+
"exists": "app-cookie-consent .cookie-banner"
|
|
11
|
+
}
|
|
12
|
+
],
|
|
13
|
+
"detectPopup": [
|
|
14
|
+
{
|
|
15
|
+
"visible": "app-cookie-consent .cookie-banner"
|
|
16
|
+
}
|
|
17
|
+
],
|
|
18
|
+
"optIn": [
|
|
19
|
+
{
|
|
20
|
+
"waitForThenClick": "app-cookie-consent .cookie-banner > div > button:nth-of-type(1)"
|
|
21
|
+
}
|
|
22
|
+
],
|
|
23
|
+
"optOut": [
|
|
24
|
+
{
|
|
25
|
+
"waitForThenClick": "app-cookie-consent .cookie-banner > div > button:nth-of-type(2)"
|
|
26
|
+
}
|
|
27
|
+
],
|
|
28
|
+
"test": [
|
|
29
|
+
{
|
|
30
|
+
"cookieContains": "%22analytics%22%3Afalse%2C%22marketing%22%3Afalse"
|
|
31
|
+
}
|
|
32
|
+
]
|
|
33
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "vinnova-se",
|
|
3
|
+
"vendorUrl": "https://www.vinnova.se/",
|
|
4
|
+
"runContext": {
|
|
5
|
+
"urlPattern": "^https?://(www\\.)?vinnova\\.se/"
|
|
6
|
+
},
|
|
7
|
+
"prehideSelectors": [".component-lightbox-gdpr"],
|
|
8
|
+
"detectCmp": [
|
|
9
|
+
{
|
|
10
|
+
"exists": ".component-lightbox-gdpr .gdpr_cookie_settings_accept_cookies"
|
|
11
|
+
}
|
|
12
|
+
],
|
|
13
|
+
"detectPopup": [
|
|
14
|
+
{
|
|
15
|
+
"visible": ".component-lightbox-gdpr .gdpr_cookie_settings_accept_cookies"
|
|
16
|
+
}
|
|
17
|
+
],
|
|
18
|
+
"optIn": [
|
|
19
|
+
{
|
|
20
|
+
"waitForThenClick": ".gdpr_cookie_settings_accept_cookies__button-container__button.button--solid--primary"
|
|
21
|
+
}
|
|
22
|
+
],
|
|
23
|
+
"optOut": [
|
|
24
|
+
{
|
|
25
|
+
"waitForThenClick": ".gdpr_cookie_settings_accept_cookies__button-container__button.button--solid--secondary"
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
"waitForVisible": ".gdpr_cookie_settings_cookie_settings"
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
"comment": "levels are cumulative: switching off the lowest level switches off all higher ones",
|
|
32
|
+
"if": {
|
|
33
|
+
"exists": ".gdpr_cookie_settings_cookie_settings .component-toggle-button[toggle_selected=True]"
|
|
34
|
+
},
|
|
35
|
+
"then": [
|
|
36
|
+
{
|
|
37
|
+
"click": ".gdpr_cookie_settings_cookie_settings .component-toggle-button[toggle_selected=True]"
|
|
38
|
+
}
|
|
39
|
+
]
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
"waitForThenClick": ".gdpr_cookie_settings_cookie_settings__main-section__button-container__button"
|
|
43
|
+
}
|
|
44
|
+
],
|
|
45
|
+
"test": [
|
|
46
|
+
{
|
|
47
|
+
"cookieContains": "_vinnova_gdpr=0"
|
|
48
|
+
}
|
|
49
|
+
]
|
|
50
|
+
}
|
|
@@ -28,7 +28,22 @@
|
|
|
28
28
|
"optOut": [
|
|
29
29
|
{ "wait": 500 },
|
|
30
30
|
{
|
|
31
|
-
"
|
|
31
|
+
"if": {
|
|
32
|
+
"exists": ["cookie-banner#cookie-banner-host", "#onetrust-reject-all-handler"]
|
|
33
|
+
},
|
|
34
|
+
"then": [
|
|
35
|
+
{
|
|
36
|
+
"waitForThenClick": ["cookie-banner#cookie-banner-host", "#onetrust-reject-all-handler"]
|
|
37
|
+
}
|
|
38
|
+
],
|
|
39
|
+
"else": [
|
|
40
|
+
{
|
|
41
|
+
"waitForThenClick": ["cookie-banner#cookie-banner-host", "#onetrust-pc-btn-handler"]
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
"waitForThenClick": "#onetrust-pc-sdk .ot-pc-refuse-all-handler"
|
|
45
|
+
}
|
|
46
|
+
]
|
|
32
47
|
},
|
|
33
48
|
{
|
|
34
49
|
"waitForVisible": ["cookie-banner#cookie-banner-host", "#dialog_cookie_consent"],
|
|
@@ -38,7 +53,13 @@
|
|
|
38
53
|
],
|
|
39
54
|
"test": [
|
|
40
55
|
{
|
|
41
|
-
"cookieContains": "
|
|
56
|
+
"cookieContains": "OptanonAlertBoxClosed"
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"cookieContains": "C3%3A0"
|
|
60
|
+
},
|
|
61
|
+
{
|
|
62
|
+
"cookieContains": "C4%3A0"
|
|
42
63
|
}
|
|
43
64
|
]
|
|
44
65
|
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "vortex-consent",
|
|
3
|
+
"prehideSelectors": [".consent-overlay", "div.consent[role=dialog]"],
|
|
4
|
+
"detectCmp": [
|
|
5
|
+
{
|
|
6
|
+
"exists": "div.consent[role=dialog] .consent-main-buttons .consent-decline-all"
|
|
7
|
+
}
|
|
8
|
+
],
|
|
9
|
+
"detectPopup": [
|
|
10
|
+
{
|
|
11
|
+
"visible": "div.consent[role=dialog] .consent-main-buttons .consent-decline-all"
|
|
12
|
+
}
|
|
13
|
+
],
|
|
14
|
+
"optIn": [
|
|
15
|
+
{
|
|
16
|
+
"waitForThenClick": "div.consent[role=dialog] .consent-main-buttons .consent-accept-all"
|
|
17
|
+
}
|
|
18
|
+
],
|
|
19
|
+
"optOut": [
|
|
20
|
+
{
|
|
21
|
+
"waitForThenClick": "div.consent[role=dialog] .consent-main-buttons .consent-decline-all"
|
|
22
|
+
}
|
|
23
|
+
],
|
|
24
|
+
"test": [
|
|
25
|
+
{
|
|
26
|
+
"cookieContains": "PrivacyPolicyOptOut"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"cookieContains": "UsageAnalysisConsent=yes",
|
|
30
|
+
"negated": true
|
|
31
|
+
}
|
|
32
|
+
]
|
|
33
|
+
}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "vue-cookie-accept-decline",
|
|
3
|
+
"vendorUrl": "https://github.com/johndatserakis/vue-cookie-accept-decline",
|
|
4
|
+
"cosmetic": false,
|
|
5
|
+
"runContext": {
|
|
6
|
+
"main": true,
|
|
7
|
+
"frame": false
|
|
8
|
+
},
|
|
9
|
+
"prehideSelectors": [".cookie.cookie__floating", ".cookie.cookie__bar"],
|
|
10
|
+
"detectCmp": [
|
|
11
|
+
{
|
|
12
|
+
"exists": ".cookie__floating__buttons__button--accept, .cookie__bar__buttons__button--accept"
|
|
13
|
+
}
|
|
14
|
+
],
|
|
15
|
+
"detectPopup": [
|
|
16
|
+
{
|
|
17
|
+
"visible": ".cookie.cookie__floating, .cookie.cookie__bar"
|
|
18
|
+
}
|
|
19
|
+
],
|
|
20
|
+
"optIn": [
|
|
21
|
+
{
|
|
22
|
+
"waitForThenClick": ".cookie__floating__buttons__button--accept, .cookie__bar__buttons__button--accept"
|
|
23
|
+
}
|
|
24
|
+
],
|
|
25
|
+
"optOut": [
|
|
26
|
+
{
|
|
27
|
+
"if": {
|
|
28
|
+
"exists": ".cookie__floating__buttons__button--decline, .cookie__bar__buttons__button--decline"
|
|
29
|
+
},
|
|
30
|
+
"then": [
|
|
31
|
+
{
|
|
32
|
+
"waitForThenClick": ".cookie__floating__buttons__button--decline, .cookie__bar__buttons__button--decline"
|
|
33
|
+
}
|
|
34
|
+
],
|
|
35
|
+
"else": [
|
|
36
|
+
{
|
|
37
|
+
"hide": ".cookie.cookie__floating, .cookie.cookie__bar"
|
|
38
|
+
}
|
|
39
|
+
]
|
|
40
|
+
}
|
|
41
|
+
]
|
|
42
|
+
}
|