@@ -3,43 +3,58 @@ provider:
3
3
name : Zapier Webhook Url
4
4
category : Workflow Automation
5
5
message : Make sure this Zapier Webhook Url gets revoked, changed, and removed from the code.
6
+ detection :
7
+ pre :
8
+ include :
9
+ content :
10
+ - " zapier.com/hooks/catch"
11
+ post :
12
+ # Avoid matching values found on SourceGraph that look like dummy passwords or insertions like:
13
+ # - https://hooks.zapier.com/hooks/catch/123456/XXXXXXXX
14
+ # - https://hooks.zapier.com/hooks/catch/123456/abcde/
15
+ # - https://zapier.com/hooks/catch/000000/xxxxxxx/
16
+ patternNot :
17
+ - " (\\ w)\\ 1{6,}"
18
+ - " 123456"
19
+ - " (?i)abcde"
6
20
7
21
rules :
8
22
- rspecKey : S6720
9
23
id : zapier-webhook-urls
10
24
metadata :
11
25
name : Zapier Webhook Urls
26
+ detection :
27
+ matching :
28
+ pattern : " (?:https://)?(?:hooks\\ .)?zapier\\ .com/hooks/catch/([0-9]{3,}/[0-9a-zA-Z,]{3,})"
12
29
examples :
30
+ - text : |
31
+ # Noncompliant code example
32
+ props.set("zapier_webhook_url", "https://hooks.zapier.com/hooks/catch/3017724/t0q8ed/")
33
+ containsSecret: true
34
+ match: 3017724/t0q8ed
35
+ - text : |
36
+ # Compliant solution
37
+ props.set("zapier_webhook_url", System.getenv("ZAPIER_WEBHOOK_URL"))
38
+ containsSecret: false
13
39
- text : |
14
40
var webhookURL = "https://hooks.zapier.com/hooks/catch/192840272/anwidh83";
15
41
var data = {
16
42
"First Name" : userName.value,
17
43
"Email" : userEmail.value,
18
44
};
19
45
containsSecret: true
20
- match: https://hooks.zapier.com/hooks/catch/ 192840272/anwidh83
46
+ match: 192840272/anwidh83
21
47
- text : |
22
48
var webhookURL = "https://hooks.zapier.com/hooks/catch/192840272/anwid,asne8,wod28";
23
49
var data = {
24
50
"First Name" : userName.value,
25
51
"Email" : userEmail.value,
26
52
};
27
53
containsSecret: true
28
- match: https://hooks.zapier.com/hooks/catch/ 192840272/anwid,asne8,wod28
54
+ match: 192840272/anwid,asne8,wod28
29
55
- text : |
30
56
const NETWORKS = {
31
57
'1': 'https://hooks.zapier.com/hooks/catch/xxxx/xxxxx',
32
58
}
33
59
containsSecret: false
34
- detection :
35
- matching :
36
- pattern : " ((https://)?(hooks\\ .)?zapier\\ .com/hooks/catch/[0-9]{3,}/[0-9a-zA-Z,]{3,})"
37
- post :
38
- # Avoid matching values found on SourceGraph that look like dummy passwords or insertions like:
39
- # - https://hooks.zapier.com/hooks/catch/123456/XXXXXXXX
40
- # - https://hooks.zapier.com/hooks/catch/123456/abcde/
41
- # - https://zapier.com/hooks/catch/000000/xxxxxxx/
42
- patternNot :
43
- - " (\\ w)\\ 1{6,}"
44
- - " 123456"
45
- - " (?i)abcde"
60
+
0 commit comments