@ecomconsult/consentkit 0.5.0 → 0.5.1
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/npm/internal-stub.mjs +1 -1
- package/package.json +1 -1
- package/src/ck-core.js +50 -2
package/npm/internal-stub.mjs
CHANGED
|
@@ -28,7 +28,7 @@ export function undecidedState() {
|
|
|
28
28
|
*/
|
|
29
29
|
export function createStub() {
|
|
30
30
|
const stub = {
|
|
31
|
-
version: '0.5.
|
|
31
|
+
version: '0.5.1',
|
|
32
32
|
config: {},
|
|
33
33
|
init: function () { return undecidedState(); },
|
|
34
34
|
allowed: function (cat) { return cat === 'necessary'; },
|
package/package.json
CHANGED
package/src/ck-core.js
CHANGED
|
@@ -123,7 +123,27 @@
|
|
|
123
123
|
'jivosite.com': 'functional',
|
|
124
124
|
'jivo.chat': 'functional',
|
|
125
125
|
'tidio.co': 'functional',
|
|
126
|
-
'tidiochat.com': 'functional'
|
|
126
|
+
'tidiochat.com': 'functional',
|
|
127
|
+
// Searchanise — site search for e-commerce. The widget IS the search box,
|
|
128
|
+
// so a shop whose visitor declines functional loses the feature and nothing
|
|
129
|
+
// else; it is not measurement. The numbered API hosts are enumerated
|
|
130
|
+
// because matching here is plain suffix matching (see hostMatches) with no
|
|
131
|
+
// pattern form: searchserverapi1.com is not a subdomain of anything.
|
|
132
|
+
'searchanise.com': 'functional',
|
|
133
|
+
'searchserverapi.com': 'functional',
|
|
134
|
+
'searchserverapi1.com': 'functional',
|
|
135
|
+
'searchserverapi2.com': 'functional',
|
|
136
|
+
'searchserverapi3.com': 'functional',
|
|
137
|
+
// iuteCredit — a Moldovan consumer-credit calculator embedded on shop
|
|
138
|
+
// product pages. A third party the owner chose, offering a feature.
|
|
139
|
+
'iutecredit.md': 'functional',
|
|
140
|
+
|
|
141
|
+
// --- necessary -----------------------------------------------------
|
|
142
|
+
// recaptcha.net is Google's alternate reCAPTCHA domain, served for regions
|
|
143
|
+
// where google.com is unreachable. Unlike the two path-scoped Google hosts
|
|
144
|
+
// in PATH_DB, this domain hosts NOTHING but the captcha, so the whole host
|
|
145
|
+
// is the right scope.
|
|
146
|
+
'recaptcha.net': 'necessary'
|
|
127
147
|
};
|
|
128
148
|
|
|
129
149
|
// Runtime overrides fed in by ConsentKit._extendHostDb(map) — the SaaS
|
|
@@ -149,8 +169,20 @@
|
|
|
149
169
|
// tags never get the chance to see consent at all.
|
|
150
170
|
// gtag.js is the opposite case — a direct GA4/Ads install with no container
|
|
151
171
|
// in front of it — so it stays blocked by path.
|
|
172
|
+
//
|
|
173
|
+
// reCAPTCHA is the other reason this table exists. www.google.com and
|
|
174
|
+
// www.gstatic.com host it, and neither can be given a category as a WHOLE
|
|
175
|
+
// host — that would rule on every Google property at once. Path-scoping names
|
|
176
|
+
// the widget and nothing else. The category is 'necessary': a form gated
|
|
177
|
+
// behind a captcha is unusable without it, and allowed() lets 'necessary'
|
|
178
|
+
// through unconditionally, so this classifies the request for the report
|
|
179
|
+
// without ever blocking it. (Strict mode already passed these through via
|
|
180
|
+
// BASE_ALLOW_PATH; what this adds is a NAME, so the audit stops filing the
|
|
181
|
+
// captcha under «сторонние подключения без категории».)
|
|
152
182
|
var PATH_DB = {
|
|
153
183
|
'/gtag/js': 'analytics', // googletagmanager.com/gtag/js?id=G-XXXX
|
|
184
|
+
'www.google.com/recaptcha/': 'necessary',
|
|
185
|
+
'www.gstatic.com/recaptcha/': 'necessary',
|
|
154
186
|
'/trackers/ga.js': 'analytics',
|
|
155
187
|
'/trackers/pixel.js': 'marketing',
|
|
156
188
|
'/trackers/chat.js': 'functional'
|
|
@@ -284,8 +316,24 @@
|
|
|
284
316
|
'cdnjs.cloudflare.com',
|
|
285
317
|
'code.jquery.com',
|
|
286
318
|
'ajax.googleapis.com',
|
|
319
|
+
'ajax.aspnetcdn.com', // Microsoft Ajax CDN (jQuery, MVC)
|
|
320
|
+
'aspnetcdn.com',
|
|
321
|
+
'kxcdn.com', // KeyCDN tenants, e.g. *-ef84.kxcdn.com
|
|
322
|
+
'cloudfront.net', // AWS CloudFront distributions
|
|
323
|
+
'akamaihd.net', // Akamai
|
|
324
|
+
'fastly.net',
|
|
325
|
+
'b-cdn.net', // bunny.net
|
|
287
326
|
// --- fonts ----------------------------------------------------------
|
|
288
327
|
'fonts.googleapis.com',
|
|
328
|
+
// gstatic.com whole: Google's static-asset domain. Its subdomains serve
|
|
329
|
+
// fonts (fonts.gstatic.com), the reCAPTCHA widget's own code
|
|
330
|
+
// (www.gstatic.com/recaptcha/) and ordinary images — assets a page is
|
|
331
|
+
// broken without, none of which measure a visitor. Nothing on it is a
|
|
332
|
+
// tracker: the Google properties that DO measure live on their own hosts
|
|
333
|
+
// (google-analytics.com, googletagmanager.com, doubleclick.net) and are
|
|
334
|
+
// classified there. fonts.gstatic.com is kept below it, redundant under
|
|
335
|
+
// suffix matching but named because §8 and the fixtures both refer to it.
|
|
336
|
+
'gstatic.com',
|
|
289
337
|
'fonts.gstatic.com',
|
|
290
338
|
// --- captcha ---------------------------------------------------------
|
|
291
339
|
// A page whose form is gated behind a captcha is unusable without it. The
|
|
@@ -1413,7 +1461,7 @@
|
|
|
1413
1461
|
// Public API
|
|
1414
1462
|
// ---------------------------------------------------------------------------
|
|
1415
1463
|
var ConsentKit = {
|
|
1416
|
-
version: '0.5.
|
|
1464
|
+
version: '0.5.1',
|
|
1417
1465
|
config: config,
|
|
1418
1466
|
|
|
1419
1467
|
init: function (userConfig) {
|