-
-
Notifications
You must be signed in to change notification settings - Fork 21
/
Copy pathpatterns.yaml
59 lines (59 loc) · 1.38 KB
/
patterns.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
- id: test_regex
message: This is a rule to test regex
input_case: exact
pattern: \.close\(\)
severity: info
type: Regex
- id: test_regex_and
message: This is a rule to test regex_and
input_case: exact
pattern:
- \.loadUrl\(.*getExternalStorageDirectory\(
- webkit\.WebView
severity: error
type: RegexAnd
- id: test_regex_or
message: This is a rule to test regex_or
input_case: exact
pattern:
- MODE_WORLD_READABLE|Context\.MODE_WORLD_READABLE
- openFileOutput\(\s*".+"\s*,\s*1\s*\)
severity: error
type: RegexOr
- id: test_regex_and_not
message: This is a rule to test regex_and_not
input_case: exact
pattern:
- WKWebView
- \.javaScriptEnabled=false
severity: warning
type: RegexAndNot
- id: test_regex_and_or
message: This is a rule to test regex_and_or
input_case: exact
pattern:
- telephony.SmsManager
- - sendMultipartTextMessage
- sendTextMessage
- vnd.android-dir/mms-sms
severity: warning
type: RegexAndOr
- id: test_regex_multiline_and_metadata
message: This is a rule to test regex
input_case: exact
pattern: ((?:public.+)+)
severity: info
type: Regex
metadata:
owasp-mobile: m1
owasp-mobile-2024: m1
owasp-web: a10
cwe: cwe-1051
masvs: storage-3
foo: bar
- id: test_regex_case
message: This is a rule to test regex case
input_case: lower
pattern: match\d{1}
severity: error
type: Regex