govuk_publishing_components 23.7.6 → 23.7.7
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4bcf906c61bd12c5c7a7eaa0f3a948c0e17cf23b3590e4640ea3b91fd8b20494
|
4
|
+
data.tar.gz: 367dd5afad155e02d182cb8b4b48dc6740a24b7888111b947c4cc486d963bfad
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1b5fe1817e673d9d5a2bffcecccf1434d34f1b13643df275fccca45a2f478b4a56f9e27b486713faa6fa5bb48c21a4999b293d5b6aabec468a899a28345bcfef
|
7
|
+
data.tar.gz: 8086257659e01ac460d9fdf0cde17fc20378bc24bfcb35bfa00cea04247c2ebacc3237d72f4fe1a2e027c1433fb93c2f65be07fc0fbefcfd7d09c9bd499c9b8e
|
@@ -8,6 +8,11 @@
|
|
8
8
|
var POSTCODE_PATTERN = /[A-PR-UWYZ][A-HJ-Z]?[0-9][0-9A-HJKMNPR-Y]?(?:[\s+]|%20)*[0-9][ABD-HJLNPQ-Z]{2}/gi
|
9
9
|
var DATE_PATTERN = /\d{4}(-?)\d{2}(-?)\d{2}/g
|
10
10
|
|
11
|
+
// specific URL parameters to be redacted from accounts URLs
|
12
|
+
var RESET_PASSWORD_TOKEN_PATTERN = /reset_password_token=[a-zA-Z0-9-]+/g
|
13
|
+
var UNLOCK_TOKEN_PATTERN = /unlock_token=[a-zA-Z0-9-]+/g
|
14
|
+
var STATE_PATTERN = /state=.[^&]+/g
|
15
|
+
|
11
16
|
function shouldStripDates () {
|
12
17
|
return ($('meta[name="govuk:static-analytics:strip-dates"]').length > 0)
|
13
18
|
}
|
@@ -35,6 +40,10 @@
|
|
35
40
|
|
36
41
|
pii.prototype.stripPIIFromString = function (string) {
|
37
42
|
var stripped = string.replace(EMAIL_PATTERN, '[email]')
|
43
|
+
stripped = stripped.replace(RESET_PASSWORD_TOKEN_PATTERN, 'reset_password_token=[reset_password_token]')
|
44
|
+
stripped = stripped.replace(UNLOCK_TOKEN_PATTERN, 'unlock_token=[unlock_token]')
|
45
|
+
stripped = stripped.replace(STATE_PATTERN, 'state=[state]')
|
46
|
+
|
38
47
|
if (this.stripDatePII === true) {
|
39
48
|
stripped = stripped.replace(DATE_PATTERN, '[date]')
|
40
49
|
}
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: govuk_publishing_components
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 23.7.
|
4
|
+
version: 23.7.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- GOV.UK Dev
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-12-
|
11
|
+
date: 2020-12-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: govuk_app_config
|