deepscan-cli 1.0.0 → 1.2.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/NOTICE +5 -0
- package/README.md +174 -59
- package/dist/bin/deepscan.js +189 -71
- package/dist/bin/deepscan.js.map +1 -1
- package/dist/{chunk-OSYJXVNF.js → chunk-KITQQYNW.js} +5071 -596
- package/dist/chunk-KITQQYNW.js.map +1 -0
- package/dist/index.d.ts +61 -5
- package/dist/index.js +13 -3
- package/package.json +23 -5
- package/rules/built-in/default-config.yml +28 -3
- package/rules/built-in/operations.yml +287 -0
- package/rules/built-in/security.yml +12 -6
- package/dist/chunk-OSYJXVNF.js.map +0 -1
- package/rules/built-in/converted-semgrep.yml +0 -37
- package/rules/built-in/semgrep-apex.yml +0 -336
- package/rules/built-in/semgrep-bash.yml +0 -362
- package/rules/built-in/semgrep-c.yml +0 -429
- package/rules/built-in/semgrep-clojure.yml +0 -166
- package/rules/built-in/semgrep-csharp.yml +0 -1260
- package/rules/built-in/semgrep-dart.yml +0 -21
- package/rules/built-in/semgrep-dockerfile.yml +0 -874
- package/rules/built-in/semgrep-elixir.yml +0 -146
- package/rules/built-in/semgrep-generic.yml +0 -2945
- package/rules/built-in/semgrep-go.yml +0 -2898
- package/rules/built-in/semgrep-hcl.yml +0 -8181
- package/rules/built-in/semgrep-html.yml +0 -94
- package/rules/built-in/semgrep-java.yml +0 -4219
- package/rules/built-in/semgrep-javascript.yml +0 -6243
- package/rules/built-in/semgrep-json.yml +0 -360
- package/rules/built-in/semgrep-kotlin.yml +0 -540
- package/rules/built-in/semgrep-lua.yml +0 -46
- package/rules/built-in/semgrep-ocaml.yml +0 -773
- package/rules/built-in/semgrep-php.yml +0 -1638
- package/rules/built-in/semgrep-python.yml +0 -11240
- package/rules/built-in/semgrep-regex.yml +0 -6444
- package/rules/built-in/semgrep-ruby.yml +0 -2687
- package/rules/built-in/semgrep-rust.yml +0 -278
- package/rules/built-in/semgrep-scala.yml +0 -807
- package/rules/built-in/semgrep-sh.yml +0 -46
- package/rules/built-in/semgrep-solidity.yml +0 -1046
- package/rules/built-in/semgrep-swift.yml +0 -200
- package/rules/built-in/semgrep-terraform.yml +0 -147
- package/rules/built-in/semgrep-typescript.yml +0 -6212
- package/rules/built-in/semgrep-xml.yml +0 -31
- package/rules/built-in/semgrep-yaml.yml +0 -2785
- package/rules/examples/custom-api-security.yml +0 -66
|
@@ -1,1638 +0,0 @@
|
|
|
1
|
-
rules:
|
|
2
|
-
- id: contains-bidirectional-characters
|
|
3
|
-
name: contains-bidirectional-characters
|
|
4
|
-
description: >-
|
|
5
|
-
This code contains bidirectional (bidi) characters. While this is useful for support of right-to-left languages
|
|
6
|
-
such as Arabic or Hebrew, it can also be used to trick language parsers into executing code in a manner that is
|
|
7
|
-
different from how it is displayed in code editing and review tools. If this is not what you were expecting,
|
|
8
|
-
please review this code in an editor that can reveal hidden Unicode characters.
|
|
9
|
-
category: security
|
|
10
|
-
severity: medium
|
|
11
|
-
confidence: medium
|
|
12
|
-
languages:
|
|
13
|
-
- bash
|
|
14
|
-
- c
|
|
15
|
-
- csharp
|
|
16
|
-
- go
|
|
17
|
-
- java
|
|
18
|
-
- javascript
|
|
19
|
-
- json
|
|
20
|
-
- kotlin
|
|
21
|
-
- lua
|
|
22
|
-
- ocaml
|
|
23
|
-
- php
|
|
24
|
-
- python
|
|
25
|
-
- ruby
|
|
26
|
-
- rust
|
|
27
|
-
- scala
|
|
28
|
-
- sh
|
|
29
|
-
- typescript
|
|
30
|
-
- yaml
|
|
31
|
-
patterns:
|
|
32
|
-
- regex: .*
|
|
33
|
-
message: >-
|
|
34
|
-
This code contains bidirectional (bidi) characters. While this is useful for support of right-to-left
|
|
35
|
-
languages such as Arabic or Hebrew, it can also be used to trick language parsers into executing code in a
|
|
36
|
-
manner that is different from how it is displayed in code editing and review tools. If this is not what you
|
|
37
|
-
were expecting, please review this code in an editor that can reveal hidden Unicode characters.
|
|
38
|
-
cwe:
|
|
39
|
-
- CWE-94
|
|
40
|
-
owasp:
|
|
41
|
-
- A03:2021
|
|
42
|
-
- A05:2025
|
|
43
|
-
references:
|
|
44
|
-
- https://trojansource.codes/
|
|
45
|
-
tags:
|
|
46
|
-
- unicode
|
|
47
|
-
- id: doctrine-dbal-dangerous-query
|
|
48
|
-
name: doctrine-dbal-dangerous-query
|
|
49
|
-
description: >-
|
|
50
|
-
Detected string concatenation with a non-literal variable in a Doctrine DBAL query method. This could lead to SQL
|
|
51
|
-
injection if the variable is user-controlled and not properly sanitized. In order to prevent SQL injection, use
|
|
52
|
-
parameterized queries or prepared statements instead.
|
|
53
|
-
category: security
|
|
54
|
-
severity: medium
|
|
55
|
-
confidence: medium
|
|
56
|
-
languages:
|
|
57
|
-
- php
|
|
58
|
-
patterns:
|
|
59
|
-
- regex: .*
|
|
60
|
-
message: >-
|
|
61
|
-
Detected string concatenation with a non-literal variable in a Doctrine DBAL query method. This could lead to
|
|
62
|
-
SQL injection if the variable is user-controlled and not properly sanitized. In order to prevent SQL
|
|
63
|
-
injection, use parameterized queries or prepared statements instead.
|
|
64
|
-
cwe:
|
|
65
|
-
- CWE-89
|
|
66
|
-
owasp:
|
|
67
|
-
- A01:2017
|
|
68
|
-
- A03:2021
|
|
69
|
-
- A05:2025
|
|
70
|
-
references:
|
|
71
|
-
- https://www.doctrine-project.org/projects/doctrine-dbal/en/current/reference/security.html
|
|
72
|
-
- https://cheatsheetseries.owasp.org/cheatsheets/SQL_Injection_Prevention_Cheat_Sheet.html
|
|
73
|
-
tags:
|
|
74
|
-
- doctrine
|
|
75
|
-
- id: doctrine-orm-dangerous-query
|
|
76
|
-
name: doctrine-orm-dangerous-query
|
|
77
|
-
description: >-
|
|
78
|
-
`$QUERY` Detected string concatenation with a non-literal variable in a Doctrine QueryBuilder method. This could
|
|
79
|
-
lead to SQL injection if the variable is user-controlled and not properly sanitized. In order to prevent SQL
|
|
80
|
-
injection, use parameterized queries or prepared statements instead.
|
|
81
|
-
category: security
|
|
82
|
-
severity: medium
|
|
83
|
-
confidence: medium
|
|
84
|
-
languages:
|
|
85
|
-
- php
|
|
86
|
-
patterns:
|
|
87
|
-
- regex: .*
|
|
88
|
-
message: >-
|
|
89
|
-
`$QUERY` Detected string concatenation with a non-literal variable in a Doctrine QueryBuilder method. This
|
|
90
|
-
could lead to SQL injection if the variable is user-controlled and not properly sanitized. In order to prevent
|
|
91
|
-
SQL injection, use parameterized queries or prepared statements instead.
|
|
92
|
-
cwe:
|
|
93
|
-
- CWE-89
|
|
94
|
-
owasp:
|
|
95
|
-
- A01:2017
|
|
96
|
-
- A03:2021
|
|
97
|
-
- A05:2025
|
|
98
|
-
references:
|
|
99
|
-
- >-
|
|
100
|
-
https://www.doctrine-project.org/projects/doctrine-dbal/en/current/reference/query-builder.html#security-safely-preventing-sql-injection
|
|
101
|
-
- https://cheatsheetseries.owasp.org/cheatsheets/SQL_Injection_Prevention_Cheat_Sheet.html
|
|
102
|
-
tags:
|
|
103
|
-
- doctrine
|
|
104
|
-
- id: empty-with-boolean-expression
|
|
105
|
-
name: empty-with-boolean-expression
|
|
106
|
-
description: Calling `empty` on a boolean expression may be an indication that a parenthesis is misplaced.
|
|
107
|
-
category: security
|
|
108
|
-
severity: medium
|
|
109
|
-
confidence: medium
|
|
110
|
-
languages:
|
|
111
|
-
- php
|
|
112
|
-
patterns:
|
|
113
|
-
- pattern: |
|
|
114
|
-
empty($A && $B)
|
|
115
|
-
message: Calling `empty` on a boolean expression may be an indication that a parenthesis is misplaced.
|
|
116
|
-
- pattern: |
|
|
117
|
-
empty($A || $B)
|
|
118
|
-
message: Calling `empty` on a boolean expression may be an indication that a parenthesis is misplaced.
|
|
119
|
-
cwe: []
|
|
120
|
-
owasp: []
|
|
121
|
-
references: []
|
|
122
|
-
tags:
|
|
123
|
-
- php
|
|
124
|
-
- id: assert-use
|
|
125
|
-
name: assert-use
|
|
126
|
-
description: Calling assert with user input is equivalent to eval'ing.
|
|
127
|
-
category: security
|
|
128
|
-
severity: high
|
|
129
|
-
confidence: medium
|
|
130
|
-
languages:
|
|
131
|
-
- php
|
|
132
|
-
patterns:
|
|
133
|
-
- regex: .*
|
|
134
|
-
message: Calling assert with user input is equivalent to eval'ing.
|
|
135
|
-
cwe:
|
|
136
|
-
- CWE-95
|
|
137
|
-
owasp:
|
|
138
|
-
- A03:2021
|
|
139
|
-
- A05:2025
|
|
140
|
-
references:
|
|
141
|
-
- https://www.php.net/manual/en/function.assert
|
|
142
|
-
- >-
|
|
143
|
-
https://github.com/FloeDesignTechnologies/phpcs-security-audit/blob/master/Security/Sniffs/BadFunctions/AssertsSniff.php
|
|
144
|
-
tags:
|
|
145
|
-
- php
|
|
146
|
-
- id: assert-use-audit
|
|
147
|
-
name: assert-use-audit
|
|
148
|
-
description: Calling assert with user input is equivalent to eval'ing.
|
|
149
|
-
category: security
|
|
150
|
-
severity: high
|
|
151
|
-
confidence: medium
|
|
152
|
-
languages:
|
|
153
|
-
- php
|
|
154
|
-
patterns:
|
|
155
|
-
- pattern: assert($ASSERT, ...);
|
|
156
|
-
message: Calling assert with user input is equivalent to eval'ing.
|
|
157
|
-
cwe:
|
|
158
|
-
- CWE-95
|
|
159
|
-
owasp:
|
|
160
|
-
- A03:2021
|
|
161
|
-
- A05:2025
|
|
162
|
-
references:
|
|
163
|
-
- https://www.php.net/manual/en/function.assert
|
|
164
|
-
- >-
|
|
165
|
-
https://github.com/FloeDesignTechnologies/phpcs-security-audit/blob/master/Security/Sniffs/BadFunctions/AssertsSniff.php
|
|
166
|
-
tags:
|
|
167
|
-
- php
|
|
168
|
-
- id: openssl-decrypt-validate
|
|
169
|
-
name: openssl-decrypt-validate
|
|
170
|
-
description: >-
|
|
171
|
-
The function `openssl_decrypt` returns either a string of the decrypted data on success or `false` on failure. If
|
|
172
|
-
the failure case is not handled, this could lead to undefined behavior in your application. Please handle the case
|
|
173
|
-
where `openssl_decrypt` returns `false`.
|
|
174
|
-
category: security
|
|
175
|
-
severity: medium
|
|
176
|
-
confidence: medium
|
|
177
|
-
languages:
|
|
178
|
-
- php
|
|
179
|
-
patterns:
|
|
180
|
-
- pattern: openssl_decrypt(...);
|
|
181
|
-
message: >-
|
|
182
|
-
The function `openssl_decrypt` returns either a string of the decrypted data on success or `false` on failure.
|
|
183
|
-
If the failure case is not handled, this could lead to undefined behavior in your application. Please handle
|
|
184
|
-
the case where `openssl_decrypt` returns `false`.
|
|
185
|
-
cwe:
|
|
186
|
-
- CWE-252
|
|
187
|
-
owasp:
|
|
188
|
-
- A02:2021
|
|
189
|
-
- A04:2025
|
|
190
|
-
references:
|
|
191
|
-
- https://www.php.net/manual/en/function.openssl-decrypt.php
|
|
192
|
-
tags:
|
|
193
|
-
- php
|
|
194
|
-
- openssl
|
|
195
|
-
- id: sha224-hash
|
|
196
|
-
name: sha224-hash
|
|
197
|
-
description: >-
|
|
198
|
-
This code uses a 224-bit hash function, which is deprecated or disallowed in some security policies. Consider
|
|
199
|
-
updating to a stronger hash function such as SHA-384 or higher to ensure compliance and security.
|
|
200
|
-
category: crypto
|
|
201
|
-
severity: medium
|
|
202
|
-
confidence: medium
|
|
203
|
-
languages:
|
|
204
|
-
- php
|
|
205
|
-
patterns:
|
|
206
|
-
- pattern: hash('sha224', ...);
|
|
207
|
-
message: >-
|
|
208
|
-
This code uses a 224-bit hash function, which is deprecated or disallowed in some security policies. Consider
|
|
209
|
-
updating to a stronger hash function such as SHA-384 or higher to ensure compliance and security.
|
|
210
|
-
- pattern: hash('sha512/224', ...);
|
|
211
|
-
message: >-
|
|
212
|
-
This code uses a 224-bit hash function, which is deprecated or disallowed in some security policies. Consider
|
|
213
|
-
updating to a stronger hash function such as SHA-384 or higher to ensure compliance and security.
|
|
214
|
-
- pattern: hash('sha3-224', ...);
|
|
215
|
-
message: >-
|
|
216
|
-
This code uses a 224-bit hash function, which is deprecated or disallowed in some security policies. Consider
|
|
217
|
-
updating to a stronger hash function such as SHA-384 or higher to ensure compliance and security.
|
|
218
|
-
- pattern: hash_hmac('sha224', ...);
|
|
219
|
-
message: >-
|
|
220
|
-
This code uses a 224-bit hash function, which is deprecated or disallowed in some security policies. Consider
|
|
221
|
-
updating to a stronger hash function such as SHA-384 or higher to ensure compliance and security.
|
|
222
|
-
- pattern: hash_hmac('sha512/224', ...);
|
|
223
|
-
message: >-
|
|
224
|
-
This code uses a 224-bit hash function, which is deprecated or disallowed in some security policies. Consider
|
|
225
|
-
updating to a stronger hash function such as SHA-384 or higher to ensure compliance and security.
|
|
226
|
-
- pattern: hash_hmac('sha3-224', ...);
|
|
227
|
-
message: >-
|
|
228
|
-
This code uses a 224-bit hash function, which is deprecated or disallowed in some security policies. Consider
|
|
229
|
-
updating to a stronger hash function such as SHA-384 or higher to ensure compliance and security.
|
|
230
|
-
cwe:
|
|
231
|
-
- CWE-328
|
|
232
|
-
owasp:
|
|
233
|
-
- A03:2017
|
|
234
|
-
- A02:2021
|
|
235
|
-
- A04:2025
|
|
236
|
-
references:
|
|
237
|
-
- https://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-131Ar3.ipd.pdf
|
|
238
|
-
- >-
|
|
239
|
-
https://www.cyber.gov.au/resources-business-and-government/essential-cyber-security/ism/cyber-security-guidelines/guidelines-cryptography
|
|
240
|
-
tags:
|
|
241
|
-
- php
|
|
242
|
-
- id: backticks-use
|
|
243
|
-
name: backticks-use
|
|
244
|
-
description: Backticks use may lead to command injection vulnerabilities.
|
|
245
|
-
category: security
|
|
246
|
-
severity: high
|
|
247
|
-
confidence: medium
|
|
248
|
-
languages:
|
|
249
|
-
- php
|
|
250
|
-
patterns:
|
|
251
|
-
- pattern: '`...`;'
|
|
252
|
-
message: Backticks use may lead to command injection vulnerabilities.
|
|
253
|
-
cwe:
|
|
254
|
-
- CWE-94
|
|
255
|
-
owasp:
|
|
256
|
-
- A03:2021
|
|
257
|
-
- A05:2025
|
|
258
|
-
references:
|
|
259
|
-
- https://www.php.net/manual/en/language.operators.execution.php
|
|
260
|
-
- >-
|
|
261
|
-
https://github.com/FloeDesignTechnologies/phpcs-security-audit/blob/master/Security/Sniffs/BadFunctions/BackticksSniff.php
|
|
262
|
-
tags:
|
|
263
|
-
- php
|
|
264
|
-
- id: base-convert-loses-precision
|
|
265
|
-
name: base-convert-loses-precision
|
|
266
|
-
description: >-
|
|
267
|
-
The function base_convert uses 64-bit numbers internally, and does not correctly convert large numbers. It is not
|
|
268
|
-
suitable for random tokens such as those used for session tokens or CSRF tokens.
|
|
269
|
-
category: security
|
|
270
|
-
severity: medium
|
|
271
|
-
confidence: medium
|
|
272
|
-
languages:
|
|
273
|
-
- php
|
|
274
|
-
patterns:
|
|
275
|
-
- regex: .*
|
|
276
|
-
message: >-
|
|
277
|
-
The function base_convert uses 64-bit numbers internally, and does not correctly convert large numbers. It is
|
|
278
|
-
not suitable for random tokens such as those used for session tokens or CSRF tokens.
|
|
279
|
-
cwe:
|
|
280
|
-
- CWE-190
|
|
281
|
-
owasp: []
|
|
282
|
-
references:
|
|
283
|
-
- https://www.php.net/base_convert
|
|
284
|
-
- https://www.sjoerdlangkemper.nl/2017/03/15/dont-use-base-convert-on-random-tokens/
|
|
285
|
-
tags:
|
|
286
|
-
- php
|
|
287
|
-
- id: curl-ssl-verifypeer-off
|
|
288
|
-
name: curl-ssl-verifypeer-off
|
|
289
|
-
description: SSL verification is disabled but should not be (currently CURLOPT_SSL_VERIFYPEER= $IS_VERIFIED)
|
|
290
|
-
category: security
|
|
291
|
-
severity: high
|
|
292
|
-
confidence: medium
|
|
293
|
-
languages:
|
|
294
|
-
- php
|
|
295
|
-
patterns:
|
|
296
|
-
- regex: .*
|
|
297
|
-
message: SSL verification is disabled but should not be (currently CURLOPT_SSL_VERIFYPEER= $IS_VERIFIED)
|
|
298
|
-
cwe:
|
|
299
|
-
- CWE-319
|
|
300
|
-
owasp:
|
|
301
|
-
- A03:2017
|
|
302
|
-
- A02:2021
|
|
303
|
-
- A04:2025
|
|
304
|
-
references:
|
|
305
|
-
- https://www.saotn.org/dont-turn-off-curlopt_ssl_verifypeer-fix-php-configuration/
|
|
306
|
-
tags:
|
|
307
|
-
- php
|
|
308
|
-
- id: extract-user-data
|
|
309
|
-
name: extract-user-data
|
|
310
|
-
description: >-
|
|
311
|
-
Do not call 'extract()' on user-controllable data. If you must, then you must also provide the EXTR_SKIP flag to
|
|
312
|
-
prevent overwriting existing variables.
|
|
313
|
-
category: security
|
|
314
|
-
severity: high
|
|
315
|
-
confidence: medium
|
|
316
|
-
languages:
|
|
317
|
-
- php
|
|
318
|
-
patterns:
|
|
319
|
-
- regex: .*
|
|
320
|
-
message: >-
|
|
321
|
-
Do not call 'extract()' on user-controllable data. If you must, then you must also provide the EXTR_SKIP flag
|
|
322
|
-
to prevent overwriting existing variables.
|
|
323
|
-
cwe:
|
|
324
|
-
- CWE-502
|
|
325
|
-
owasp:
|
|
326
|
-
- A08:2017
|
|
327
|
-
- A08:2021
|
|
328
|
-
- A08:2025
|
|
329
|
-
references:
|
|
330
|
-
- https://www.php.net/manual/en/function.extract.php#refsect1-function.extract-notes
|
|
331
|
-
tags:
|
|
332
|
-
- php
|
|
333
|
-
- id: eval-use
|
|
334
|
-
name: eval-use
|
|
335
|
-
description: Evaluating non-constant commands. This can lead to command injection.
|
|
336
|
-
category: injection
|
|
337
|
-
severity: high
|
|
338
|
-
confidence: medium
|
|
339
|
-
languages:
|
|
340
|
-
- php
|
|
341
|
-
patterns:
|
|
342
|
-
- pattern: eval(...);
|
|
343
|
-
message: Evaluating non-constant commands. This can lead to command injection.
|
|
344
|
-
cwe:
|
|
345
|
-
- CWE-78
|
|
346
|
-
owasp:
|
|
347
|
-
- A01:2017
|
|
348
|
-
- A03:2021
|
|
349
|
-
- A05:2025
|
|
350
|
-
references:
|
|
351
|
-
- https://www.php.net/manual/en/function.eval
|
|
352
|
-
- >-
|
|
353
|
-
https://github.com/FloeDesignTechnologies/phpcs-security-audit/blob/master/Security/Sniffs/BadFunctions/NoEvalsSniff.php
|
|
354
|
-
tags:
|
|
355
|
-
- php
|
|
356
|
-
- id: exec-use
|
|
357
|
-
name: exec-use
|
|
358
|
-
description: Executing non-constant commands. This can lead to command injection.
|
|
359
|
-
category: security
|
|
360
|
-
severity: high
|
|
361
|
-
confidence: medium
|
|
362
|
-
languages:
|
|
363
|
-
- php
|
|
364
|
-
patterns:
|
|
365
|
-
- pattern: $FUNC(...);
|
|
366
|
-
message: Executing non-constant commands. This can lead to command injection.
|
|
367
|
-
cwe:
|
|
368
|
-
- CWE-94
|
|
369
|
-
owasp:
|
|
370
|
-
- A03:2021
|
|
371
|
-
- A05:2025
|
|
372
|
-
references:
|
|
373
|
-
- >-
|
|
374
|
-
https://github.com/FloeDesignTechnologies/phpcs-security-audit/blob/master/Security/Sniffs/BadFunctions/SystemExecFunctionsSniff.php
|
|
375
|
-
tags:
|
|
376
|
-
- php
|
|
377
|
-
- id: file-inclusion
|
|
378
|
-
name: file-inclusion
|
|
379
|
-
description: >-
|
|
380
|
-
Detected non-constant file inclusion. This can lead to local file inclusion (LFI) or remote file inclusion (RFI)
|
|
381
|
-
if user input reaches this statement. LFI and RFI could lead to sensitive files being obtained by attackers.
|
|
382
|
-
Instead, explicitly specify what to include. If that is not a viable solution, validate user input thoroughly.
|
|
383
|
-
category: file-ops
|
|
384
|
-
severity: high
|
|
385
|
-
confidence: medium
|
|
386
|
-
languages:
|
|
387
|
-
- php
|
|
388
|
-
patterns:
|
|
389
|
-
- regex: .*
|
|
390
|
-
message: >-
|
|
391
|
-
Detected non-constant file inclusion. This can lead to local file inclusion (LFI) or remote file inclusion
|
|
392
|
-
(RFI) if user input reaches this statement. LFI and RFI could lead to sensitive files being obtained by
|
|
393
|
-
attackers. Instead, explicitly specify what to include. If that is not a viable solution, validate user input
|
|
394
|
-
thoroughly.
|
|
395
|
-
cwe:
|
|
396
|
-
- CWE-98
|
|
397
|
-
owasp:
|
|
398
|
-
- A03:2021
|
|
399
|
-
- A05:2025
|
|
400
|
-
references:
|
|
401
|
-
- https://www.php.net/manual/en/function.include.php
|
|
402
|
-
- >-
|
|
403
|
-
https://github.com/FloeDesignTechnologies/phpcs-security-audit/blob/master/Security/Sniffs/BadFunctions/EasyRFISniff.php
|
|
404
|
-
- https://en.wikipedia.org/wiki/File_inclusion_vulnerability#Types_of_Inclusion
|
|
405
|
-
tags:
|
|
406
|
-
- php
|
|
407
|
-
- id: ftp-use
|
|
408
|
-
name: ftp-use
|
|
409
|
-
description: FTP allows for unencrypted file transfers. Consider using an encrypted alternative.
|
|
410
|
-
category: security
|
|
411
|
-
severity: high
|
|
412
|
-
confidence: medium
|
|
413
|
-
languages:
|
|
414
|
-
- php
|
|
415
|
-
patterns:
|
|
416
|
-
- pattern: $FUNC(...);
|
|
417
|
-
message: FTP allows for unencrypted file transfers. Consider using an encrypted alternative.
|
|
418
|
-
cwe:
|
|
419
|
-
- CWE-319
|
|
420
|
-
owasp:
|
|
421
|
-
- A03:2017
|
|
422
|
-
- A02:2021
|
|
423
|
-
- A04:2025
|
|
424
|
-
references:
|
|
425
|
-
- https://www.php.net/manual/en/intro.ftp.php
|
|
426
|
-
- >-
|
|
427
|
-
https://github.com/FloeDesignTechnologies/phpcs-security-audit/blob/master/Security/Sniffs/BadFunctions/FringeFunctionsSniff.php
|
|
428
|
-
tags:
|
|
429
|
-
- php
|
|
430
|
-
- id: echoed-request
|
|
431
|
-
name: echoed-request
|
|
432
|
-
description: >-
|
|
433
|
-
`Echo`ing user input risks cross-site scripting vulnerability. You should use `htmlentities()` when showing data
|
|
434
|
-
to users.
|
|
435
|
-
category: security
|
|
436
|
-
severity: high
|
|
437
|
-
confidence: medium
|
|
438
|
-
languages:
|
|
439
|
-
- php
|
|
440
|
-
patterns:
|
|
441
|
-
- regex: .*
|
|
442
|
-
message: >-
|
|
443
|
-
`Echo`ing user input risks cross-site scripting vulnerability. You should use `htmlentities()` when showing
|
|
444
|
-
data to users.
|
|
445
|
-
cwe:
|
|
446
|
-
- CWE-79
|
|
447
|
-
owasp:
|
|
448
|
-
- A07:2017
|
|
449
|
-
- A03:2021
|
|
450
|
-
- A05:2025
|
|
451
|
-
references:
|
|
452
|
-
- https://www.php.net/manual/en/function.htmlentities.php
|
|
453
|
-
- https://www.php.net/manual/en/reserved.variables.request.php
|
|
454
|
-
- https://www.php.net/manual/en/reserved.variables.post.php
|
|
455
|
-
- https://www.php.net/manual/en/reserved.variables.get.php
|
|
456
|
-
- https://cheatsheetseries.owasp.org/cheatsheets/Cross_Site_Scripting_Prevention_Cheat_Sheet.html
|
|
457
|
-
tags:
|
|
458
|
-
- php
|
|
459
|
-
- id: printed-request
|
|
460
|
-
name: printed-request
|
|
461
|
-
description: >-
|
|
462
|
-
`Printing user input risks cross-site scripting vulnerability. You should use `htmlentities()` when showing data
|
|
463
|
-
to users.
|
|
464
|
-
category: security
|
|
465
|
-
severity: high
|
|
466
|
-
confidence: medium
|
|
467
|
-
languages:
|
|
468
|
-
- php
|
|
469
|
-
patterns:
|
|
470
|
-
- regex: .*
|
|
471
|
-
message: >-
|
|
472
|
-
`Printing user input risks cross-site scripting vulnerability. You should use `htmlentities()` when showing
|
|
473
|
-
data to users.
|
|
474
|
-
cwe:
|
|
475
|
-
- CWE-79
|
|
476
|
-
owasp:
|
|
477
|
-
- A07:2017
|
|
478
|
-
- A03:2021
|
|
479
|
-
- A05:2025
|
|
480
|
-
references:
|
|
481
|
-
- https://www.php.net/manual/en/function.htmlentities.php
|
|
482
|
-
- https://www.php.net/manual/en/reserved.variables.request.php
|
|
483
|
-
- https://www.php.net/manual/en/reserved.variables.post.php
|
|
484
|
-
- https://www.php.net/manual/en/reserved.variables.get.php
|
|
485
|
-
- https://cheatsheetseries.owasp.org/cheatsheets/Cross_Site_Scripting_Prevention_Cheat_Sheet.html
|
|
486
|
-
tags:
|
|
487
|
-
- php
|
|
488
|
-
- id: tainted-callable
|
|
489
|
-
name: tainted-callable
|
|
490
|
-
description: Callable based on user input risks remote code execution.
|
|
491
|
-
category: security
|
|
492
|
-
severity: medium
|
|
493
|
-
confidence: medium
|
|
494
|
-
languages:
|
|
495
|
-
- php
|
|
496
|
-
patterns:
|
|
497
|
-
- regex: .*
|
|
498
|
-
message: Callable based on user input risks remote code execution.
|
|
499
|
-
cwe:
|
|
500
|
-
- CWE-94
|
|
501
|
-
owasp:
|
|
502
|
-
- A03:2021
|
|
503
|
-
- A05:2025
|
|
504
|
-
references:
|
|
505
|
-
- https://www.php.net/manual/en/language.types.callable.php
|
|
506
|
-
tags:
|
|
507
|
-
- php
|
|
508
|
-
- id: tainted-exec
|
|
509
|
-
name: tainted-exec
|
|
510
|
-
description: User input is passed to a function that executes a shell command. This can lead to remote code execution.
|
|
511
|
-
category: security
|
|
512
|
-
severity: medium
|
|
513
|
-
confidence: medium
|
|
514
|
-
languages:
|
|
515
|
-
- php
|
|
516
|
-
patterns:
|
|
517
|
-
- regex: .*
|
|
518
|
-
message: User input is passed to a function that executes a shell command. This can lead to remote code execution.
|
|
519
|
-
cwe:
|
|
520
|
-
- CWE-78
|
|
521
|
-
owasp:
|
|
522
|
-
- A03:2021
|
|
523
|
-
- A05:2025
|
|
524
|
-
references:
|
|
525
|
-
- https://owasp.org/Top10/A03_2021-Injection
|
|
526
|
-
tags:
|
|
527
|
-
- php
|
|
528
|
-
- id: tainted-filename
|
|
529
|
-
name: tainted-filename
|
|
530
|
-
description: File name based on user input risks server-side request forgery.
|
|
531
|
-
category: file-ops
|
|
532
|
-
severity: medium
|
|
533
|
-
confidence: medium
|
|
534
|
-
languages:
|
|
535
|
-
- php
|
|
536
|
-
patterns:
|
|
537
|
-
- regex: .*
|
|
538
|
-
message: File name based on user input risks server-side request forgery.
|
|
539
|
-
cwe:
|
|
540
|
-
- CWE-918
|
|
541
|
-
owasp:
|
|
542
|
-
- A10:2021
|
|
543
|
-
- A01:2025
|
|
544
|
-
references:
|
|
545
|
-
- https://owasp.org/Top10/A10_2021-Server-Side_Request_Forgery_%28SSRF%29
|
|
546
|
-
tags:
|
|
547
|
-
- php
|
|
548
|
-
- id: tainted-object-instantiation
|
|
549
|
-
name: tainted-object-instantiation
|
|
550
|
-
description: >-
|
|
551
|
-
<- A new object is created where the class name is based on user input. This could lead to remote code execution,
|
|
552
|
-
as it allows to instantiate any class in the application.
|
|
553
|
-
category: security
|
|
554
|
-
severity: medium
|
|
555
|
-
confidence: medium
|
|
556
|
-
languages:
|
|
557
|
-
- php
|
|
558
|
-
patterns:
|
|
559
|
-
- regex: .*
|
|
560
|
-
message: >-
|
|
561
|
-
<- A new object is created where the class name is based on user input. This could lead to remote code
|
|
562
|
-
execution, as it allows to instantiate any class in the application.
|
|
563
|
-
cwe:
|
|
564
|
-
- CWE-470
|
|
565
|
-
owasp:
|
|
566
|
-
- A03:2021
|
|
567
|
-
- A05:2025
|
|
568
|
-
references:
|
|
569
|
-
- https://owasp.org/Top10/A03_2021-Injection
|
|
570
|
-
tags:
|
|
571
|
-
- php
|
|
572
|
-
- id: tainted-session
|
|
573
|
-
name: tainted-session
|
|
574
|
-
description: >-
|
|
575
|
-
Session key based on user input risks session poisoning. The user can determine the key used for the session, and
|
|
576
|
-
thus write any session variable. Session variables are typically trusted to be set only by the application, and
|
|
577
|
-
manipulating the session can result in access control issues.
|
|
578
|
-
category: auth
|
|
579
|
-
severity: medium
|
|
580
|
-
confidence: medium
|
|
581
|
-
languages:
|
|
582
|
-
- php
|
|
583
|
-
patterns:
|
|
584
|
-
- regex: .*
|
|
585
|
-
message: >-
|
|
586
|
-
Session key based on user input risks session poisoning. The user can determine the key used for the session,
|
|
587
|
-
and thus write any session variable. Session variables are typically trusted to be set only by the
|
|
588
|
-
application, and manipulating the session can result in access control issues.
|
|
589
|
-
cwe:
|
|
590
|
-
- CWE-284
|
|
591
|
-
owasp:
|
|
592
|
-
- A01:2021
|
|
593
|
-
- A01:2025
|
|
594
|
-
references:
|
|
595
|
-
- https://en.wikipedia.org/wiki/Session_poisoning
|
|
596
|
-
tags:
|
|
597
|
-
- php
|
|
598
|
-
- id: tainted-sql-string
|
|
599
|
-
name: tainted-sql-string
|
|
600
|
-
description: >-
|
|
601
|
-
User data flows into this manually-constructed SQL string. User data can be safely inserted into SQL strings using
|
|
602
|
-
prepared statements or an object-relational mapper (ORM). Manually-constructed SQL strings is a possible indicator
|
|
603
|
-
of SQL injection, which could let an attacker steal or manipulate data from the database. Instead, use prepared
|
|
604
|
-
statements (`$mysqli->prepare("INSERT INTO test(id, label) VALUES (?, ?)");`) or a safe library.
|
|
605
|
-
category: injection
|
|
606
|
-
severity: high
|
|
607
|
-
confidence: medium
|
|
608
|
-
languages:
|
|
609
|
-
- php
|
|
610
|
-
patterns:
|
|
611
|
-
- regex: .*
|
|
612
|
-
message: >-
|
|
613
|
-
User data flows into this manually-constructed SQL string. User data can be safely inserted into SQL strings
|
|
614
|
-
using prepared statements or an object-relational mapper (ORM). Manually-constructed SQL strings is a possible
|
|
615
|
-
indicator of SQL injection, which could let an attacker steal or manipulate data from the database. Instead,
|
|
616
|
-
use prepared statements (`$mysqli->prepare("INSERT INTO test(id, label) VALUES (?, ?)");`) or a safe library.
|
|
617
|
-
cwe:
|
|
618
|
-
- CWE-89
|
|
619
|
-
owasp:
|
|
620
|
-
- A01:2017
|
|
621
|
-
- A03:2021
|
|
622
|
-
- A05:2025
|
|
623
|
-
references:
|
|
624
|
-
- https://owasp.org/www-community/attacks/SQL_Injection
|
|
625
|
-
tags:
|
|
626
|
-
- php
|
|
627
|
-
- id: tainted-url-host
|
|
628
|
-
name: tainted-url-host
|
|
629
|
-
description: >-
|
|
630
|
-
User data flows into the host portion of this manually-constructed URL. This could allow an attacker to send data
|
|
631
|
-
to their own server, potentially exposing sensitive data such as cookies or authorization information sent with
|
|
632
|
-
this request. They could also probe internal servers or other resources that the server running this code can
|
|
633
|
-
access. (This is called server-side request forgery, or SSRF.) Do not allow arbitrary hosts. Instead, create an
|
|
634
|
-
allowlist for approved hosts, or hardcode the correct host.
|
|
635
|
-
category: security
|
|
636
|
-
severity: medium
|
|
637
|
-
confidence: medium
|
|
638
|
-
languages:
|
|
639
|
-
- php
|
|
640
|
-
patterns:
|
|
641
|
-
- regex: .*
|
|
642
|
-
message: >-
|
|
643
|
-
User data flows into the host portion of this manually-constructed URL. This could allow an attacker to send
|
|
644
|
-
data to their own server, potentially exposing sensitive data such as cookies or authorization information
|
|
645
|
-
sent with this request. They could also probe internal servers or other resources that the server running this
|
|
646
|
-
code can access. (This is called server-side request forgery, or SSRF.) Do not allow arbitrary hosts. Instead,
|
|
647
|
-
create an allowlist for approved hosts, or hardcode the correct host.
|
|
648
|
-
cwe:
|
|
649
|
-
- CWE-918
|
|
650
|
-
owasp:
|
|
651
|
-
- A10:2021
|
|
652
|
-
- A01:2025
|
|
653
|
-
references:
|
|
654
|
-
- https://cheatsheetseries.owasp.org/cheatsheets/Server_Side_Request_Forgery_Prevention_Cheat_Sheet.html
|
|
655
|
-
tags:
|
|
656
|
-
- php
|
|
657
|
-
- id: trigger-error
|
|
658
|
-
name: trigger-error
|
|
659
|
-
description: >-
|
|
660
|
-
The `$message` parameter to `trigger_error` is not HTML-encoded. If the error is displayed in a browser, this
|
|
661
|
-
risks a cross-site scripting vulnerability. Escape the message with `htmlentities()` or disable `display_errors`.
|
|
662
|
-
category: security
|
|
663
|
-
severity: medium
|
|
664
|
-
confidence: medium
|
|
665
|
-
languages:
|
|
666
|
-
- php
|
|
667
|
-
patterns:
|
|
668
|
-
- regex: .*
|
|
669
|
-
message: >-
|
|
670
|
-
The `$message` parameter to `trigger_error` is not HTML-encoded. If the error is displayed in a browser, this
|
|
671
|
-
risks a cross-site scripting vulnerability. Escape the message with `htmlentities()` or disable
|
|
672
|
-
`display_errors`.
|
|
673
|
-
cwe:
|
|
674
|
-
- CWE-79
|
|
675
|
-
owasp:
|
|
676
|
-
- A07:2017
|
|
677
|
-
- A03:2021
|
|
678
|
-
references:
|
|
679
|
-
- https://www.php.net/trigger_error
|
|
680
|
-
- https://bugs.php.net/bug.php?id=77074
|
|
681
|
-
- https://www.php.net/manual/en/function.htmlentities.php
|
|
682
|
-
- https://www.php.net/manual/en/reserved.variables.request.php
|
|
683
|
-
- https://www.php.net/manual/en/reserved.variables.post.php
|
|
684
|
-
- https://www.php.net/manual/en/reserved.variables.get.php
|
|
685
|
-
- https://cheatsheetseries.owasp.org/cheatsheets/Cross_Site_Scripting_Prevention_Cheat_Sheet.html
|
|
686
|
-
tags:
|
|
687
|
-
- php
|
|
688
|
-
- id: ldap-bind-without-password
|
|
689
|
-
name: ldap-bind-without-password
|
|
690
|
-
description: >-
|
|
691
|
-
Detected anonymous LDAP bind. This permits anonymous users to execute LDAP statements. Consider enforcing
|
|
692
|
-
authentication for LDAP.
|
|
693
|
-
category: secrets
|
|
694
|
-
severity: medium
|
|
695
|
-
confidence: medium
|
|
696
|
-
languages:
|
|
697
|
-
- php
|
|
698
|
-
patterns:
|
|
699
|
-
- regex: .*
|
|
700
|
-
message: >-
|
|
701
|
-
Detected anonymous LDAP bind. This permits anonymous users to execute LDAP statements. Consider enforcing
|
|
702
|
-
authentication for LDAP.
|
|
703
|
-
cwe:
|
|
704
|
-
- CWE-287
|
|
705
|
-
owasp:
|
|
706
|
-
- A02:2017
|
|
707
|
-
- A07:2021
|
|
708
|
-
- A07:2025
|
|
709
|
-
references:
|
|
710
|
-
- https://www.php.net/manual/en/function.ldap-bind.php
|
|
711
|
-
tags:
|
|
712
|
-
- php
|
|
713
|
-
- id: mb-ereg-replace-eval
|
|
714
|
-
name: mb-ereg-replace-eval
|
|
715
|
-
description: >-
|
|
716
|
-
Calling mb_ereg_replace with user input in the options can lead to arbitrary code execution. The eval modifier
|
|
717
|
-
(`e`) evaluates the replacement argument as code.
|
|
718
|
-
category: injection
|
|
719
|
-
severity: high
|
|
720
|
-
confidence: medium
|
|
721
|
-
languages:
|
|
722
|
-
- php
|
|
723
|
-
patterns:
|
|
724
|
-
- pattern: mb_ereg_replace($PATTERN, $REPL, $STR, $OPTIONS);
|
|
725
|
-
message: >-
|
|
726
|
-
Calling mb_ereg_replace with user input in the options can lead to arbitrary code execution. The eval modifier
|
|
727
|
-
(`e`) evaluates the replacement argument as code.
|
|
728
|
-
cwe:
|
|
729
|
-
- CWE-94
|
|
730
|
-
owasp:
|
|
731
|
-
- A03:2021
|
|
732
|
-
- A05:2025
|
|
733
|
-
references:
|
|
734
|
-
- https://www.php.net/manual/en/function.mb-ereg-replace.php
|
|
735
|
-
- https://www.php.net/manual/en/function.mb-regex-set-options.php
|
|
736
|
-
tags:
|
|
737
|
-
- php
|
|
738
|
-
- id: mcrypt-use
|
|
739
|
-
name: mcrypt-use
|
|
740
|
-
description: Mcrypt functionality has been deprecated and/or removed in recent PHP versions. Consider using Sodium or OpenSSL.
|
|
741
|
-
category: security
|
|
742
|
-
severity: high
|
|
743
|
-
confidence: medium
|
|
744
|
-
languages:
|
|
745
|
-
- php
|
|
746
|
-
patterns:
|
|
747
|
-
- pattern: $FUNC(...);
|
|
748
|
-
message: >-
|
|
749
|
-
Mcrypt functionality has been deprecated and/or removed in recent PHP versions. Consider using Sodium or
|
|
750
|
-
OpenSSL.
|
|
751
|
-
cwe:
|
|
752
|
-
- CWE-676
|
|
753
|
-
owasp: []
|
|
754
|
-
references:
|
|
755
|
-
- https://www.php.net/manual/en/intro.mcrypt.php
|
|
756
|
-
- >-
|
|
757
|
-
https://github.com/FloeDesignTechnologies/phpcs-security-audit/blob/master/Security/Sniffs/BadFunctions/CryptoFunctionsSniff.php
|
|
758
|
-
tags:
|
|
759
|
-
- php
|
|
760
|
-
- id: md5-loose-equality
|
|
761
|
-
name: md5-loose-equality
|
|
762
|
-
description: Make sure comparisons involving md5 values are strict (use `===` not `==`) to avoid type juggling issues
|
|
763
|
-
category: crypto
|
|
764
|
-
severity: high
|
|
765
|
-
confidence: medium
|
|
766
|
-
languages:
|
|
767
|
-
- php
|
|
768
|
-
patterns:
|
|
769
|
-
- regex: .*
|
|
770
|
-
message: Make sure comparisons involving md5 values are strict (use `===` not `==`) to avoid type juggling issues
|
|
771
|
-
cwe:
|
|
772
|
-
- CWE-697
|
|
773
|
-
owasp: []
|
|
774
|
-
references:
|
|
775
|
-
- https://www.php.net/manual/en/types.comparisons.php
|
|
776
|
-
- https://web.archive.org/web/20210430183236/https://www.whitehatsec.com/blog/magic-hashes/
|
|
777
|
-
tags:
|
|
778
|
-
- php
|
|
779
|
-
- id: md5-used-as-password
|
|
780
|
-
name: md5-used-as-password
|
|
781
|
-
description: >-
|
|
782
|
-
It looks like MD5 is used as a password hash. MD5 is not considered a secure password hash because it can be
|
|
783
|
-
cracked by an attacker in a short amount of time. Use a suitable password hashing function such as bcrypt. You can
|
|
784
|
-
use `password_hash($PASSWORD, PASSWORD_BCRYPT, $OPTIONS);`.
|
|
785
|
-
category: secrets
|
|
786
|
-
severity: medium
|
|
787
|
-
confidence: medium
|
|
788
|
-
languages:
|
|
789
|
-
- php
|
|
790
|
-
patterns:
|
|
791
|
-
- regex: .*
|
|
792
|
-
message: >-
|
|
793
|
-
It looks like MD5 is used as a password hash. MD5 is not considered a secure password hash because it can be
|
|
794
|
-
cracked by an attacker in a short amount of time. Use a suitable password hashing function such as bcrypt. You
|
|
795
|
-
can use `password_hash($PASSWORD, PASSWORD_BCRYPT, $OPTIONS);`.
|
|
796
|
-
cwe:
|
|
797
|
-
- CWE-327
|
|
798
|
-
owasp:
|
|
799
|
-
- A03:2017
|
|
800
|
-
- A02:2021
|
|
801
|
-
- A04:2025
|
|
802
|
-
references:
|
|
803
|
-
- https://tools.ietf.org/html/rfc6151
|
|
804
|
-
- https://crypto.stackexchange.com/questions/44151/how-does-the-flame-malware-take-advantage-of-md5-collision
|
|
805
|
-
- https://security.stackexchange.com/questions/211/how-to-securely-hash-passwords
|
|
806
|
-
- https://github.com/returntocorp/semgrep-rules/issues/1609
|
|
807
|
-
- https://www.php.net/password_hash
|
|
808
|
-
tags:
|
|
809
|
-
- md5
|
|
810
|
-
- id: openssl-cbc-static-iv
|
|
811
|
-
name: openssl-cbc-static-iv
|
|
812
|
-
description: Static IV used with AES in CBC mode. Static IVs enable chosen-plaintext attacks against encrypted data.
|
|
813
|
-
category: security
|
|
814
|
-
severity: high
|
|
815
|
-
confidence: medium
|
|
816
|
-
languages:
|
|
817
|
-
- php
|
|
818
|
-
patterns:
|
|
819
|
-
- regex: .*
|
|
820
|
-
message: Static IV used with AES in CBC mode. Static IVs enable chosen-plaintext attacks against encrypted data.
|
|
821
|
-
cwe:
|
|
822
|
-
- CWE-329
|
|
823
|
-
owasp:
|
|
824
|
-
- A02:2021
|
|
825
|
-
- A04:2025
|
|
826
|
-
references:
|
|
827
|
-
- https://csrc.nist.gov/publications/detail/sp/800-38a/final
|
|
828
|
-
tags:
|
|
829
|
-
- php
|
|
830
|
-
- openssl
|
|
831
|
-
- id: php-permissive-cors
|
|
832
|
-
name: php-permissive-cors
|
|
833
|
-
description: Access-Control-Allow-Origin response header is set to "*". This will disable CORS Same Origin Policy restrictions.
|
|
834
|
-
category: api-security
|
|
835
|
-
severity: medium
|
|
836
|
-
confidence: medium
|
|
837
|
-
languages:
|
|
838
|
-
- php
|
|
839
|
-
patterns:
|
|
840
|
-
- pattern: header($VALUE,...)
|
|
841
|
-
message: >-
|
|
842
|
-
Access-Control-Allow-Origin response header is set to "*". This will disable CORS Same Origin Policy
|
|
843
|
-
restrictions.
|
|
844
|
-
cwe:
|
|
845
|
-
- CWE-346
|
|
846
|
-
owasp:
|
|
847
|
-
- A07:2021
|
|
848
|
-
- A07:2025
|
|
849
|
-
references:
|
|
850
|
-
- https://developer.mozilla.org/ru/docs/Web/HTTP/Headers/Access-Control-Allow-Origin
|
|
851
|
-
tags:
|
|
852
|
-
- php
|
|
853
|
-
- id: php-ssrf
|
|
854
|
-
name: php-ssrf
|
|
855
|
-
description: >-
|
|
856
|
-
The web server receives a URL or similar request from an upstream component and retrieves the contents of this
|
|
857
|
-
URL, but it does not sufficiently ensure that the request is being sent to the expected destination. Dangerous
|
|
858
|
-
function $FUNCS with payload $DATA
|
|
859
|
-
category: api-security
|
|
860
|
-
severity: high
|
|
861
|
-
confidence: medium
|
|
862
|
-
languages:
|
|
863
|
-
- php
|
|
864
|
-
patterns:
|
|
865
|
-
- regex: .*
|
|
866
|
-
message: >-
|
|
867
|
-
The web server receives a URL or similar request from an upstream component and retrieves the contents of this
|
|
868
|
-
URL, but it does not sufficiently ensure that the request is being sent to the expected destination. Dangerous
|
|
869
|
-
function $FUNCS with payload $DATA
|
|
870
|
-
cwe:
|
|
871
|
-
- CWE-918
|
|
872
|
-
owasp:
|
|
873
|
-
- A10:2021
|
|
874
|
-
- A01:2025
|
|
875
|
-
references:
|
|
876
|
-
- https://cheatsheetseries.owasp.org/cheatsheets/Server_Side_Request_Forgery_Prevention_Cheat_Sheet.html
|
|
877
|
-
tags:
|
|
878
|
-
- php
|
|
879
|
-
- id: phpinfo-use
|
|
880
|
-
name: phpinfo-use
|
|
881
|
-
description: The 'phpinfo' function may reveal sensitive information about your environment.
|
|
882
|
-
category: security
|
|
883
|
-
severity: high
|
|
884
|
-
confidence: medium
|
|
885
|
-
languages:
|
|
886
|
-
- php
|
|
887
|
-
patterns:
|
|
888
|
-
- pattern: phpinfo(...);
|
|
889
|
-
message: The 'phpinfo' function may reveal sensitive information about your environment.
|
|
890
|
-
cwe:
|
|
891
|
-
- CWE-200
|
|
892
|
-
owasp:
|
|
893
|
-
- A01:2021
|
|
894
|
-
- A01:2025
|
|
895
|
-
references:
|
|
896
|
-
- https://www.php.net/manual/en/function.phpinfo
|
|
897
|
-
- >-
|
|
898
|
-
https://github.com/FloeDesignTechnologies/phpcs-security-audit/blob/master/Security/Sniffs/BadFunctions/PhpinfosSniff.php
|
|
899
|
-
tags:
|
|
900
|
-
- php
|
|
901
|
-
- id: redirect-to-request-uri
|
|
902
|
-
name: redirect-to-request-uri
|
|
903
|
-
description: >-
|
|
904
|
-
Redirecting to the current request URL may redirect to another domain, if the current path starts with two
|
|
905
|
-
slashes. E.g. in https://www.example.com//attacker.com, the value of REQUEST_URI is //attacker.com, and
|
|
906
|
-
redirecting to it will redirect to that domain.
|
|
907
|
-
category: security
|
|
908
|
-
severity: medium
|
|
909
|
-
confidence: medium
|
|
910
|
-
languages:
|
|
911
|
-
- php
|
|
912
|
-
patterns:
|
|
913
|
-
- regex: .*
|
|
914
|
-
message: >-
|
|
915
|
-
Redirecting to the current request URL may redirect to another domain, if the current path starts with two
|
|
916
|
-
slashes. E.g. in https://www.example.com//attacker.com, the value of REQUEST_URI is //attacker.com, and
|
|
917
|
-
redirecting to it will redirect to that domain.
|
|
918
|
-
cwe:
|
|
919
|
-
- CWE-601
|
|
920
|
-
owasp:
|
|
921
|
-
- A05:2017
|
|
922
|
-
- A01:2021
|
|
923
|
-
- A01:2025
|
|
924
|
-
references:
|
|
925
|
-
- https://www.php.net/manual/en/reserved.variables.server.php
|
|
926
|
-
- https://owasp.org/www-project-top-ten/2017/A5_2017-Broken_Access_Control.html
|
|
927
|
-
tags:
|
|
928
|
-
- php
|
|
929
|
-
- id: unlink-use
|
|
930
|
-
name: unlink-use
|
|
931
|
-
description: >-
|
|
932
|
-
Using user input when deleting files with `unlink()` is potentially dangerous. A malicious actor could use this to
|
|
933
|
-
modify or access files they have no right to.
|
|
934
|
-
category: security
|
|
935
|
-
severity: medium
|
|
936
|
-
confidence: medium
|
|
937
|
-
languages:
|
|
938
|
-
- php
|
|
939
|
-
patterns:
|
|
940
|
-
- pattern: unlink(...)
|
|
941
|
-
message: >-
|
|
942
|
-
Using user input when deleting files with `unlink()` is potentially dangerous. A malicious actor could use
|
|
943
|
-
this to modify or access files they have no right to.
|
|
944
|
-
cwe:
|
|
945
|
-
- CWE-22
|
|
946
|
-
owasp:
|
|
947
|
-
- A05:2017
|
|
948
|
-
- A01:2021
|
|
949
|
-
- A01:2025
|
|
950
|
-
references:
|
|
951
|
-
- https://www.php.net/manual/en/function.unlink
|
|
952
|
-
- https://owasp.org/www-project-top-ten/2017/A5_2017-Broken_Access_Control.html
|
|
953
|
-
tags:
|
|
954
|
-
- php
|
|
955
|
-
- id: unserialize-use
|
|
956
|
-
name: unserialize-use
|
|
957
|
-
description: >-
|
|
958
|
-
Calling `unserialize()` with user input in the pattern can lead to arbitrary code execution. Consider using JSON
|
|
959
|
-
or structured data approaches (e.g. Google Protocol Buffers).
|
|
960
|
-
category: security
|
|
961
|
-
severity: medium
|
|
962
|
-
confidence: medium
|
|
963
|
-
languages:
|
|
964
|
-
- php
|
|
965
|
-
patterns:
|
|
966
|
-
- pattern: unserialize(...)
|
|
967
|
-
message: >-
|
|
968
|
-
Calling `unserialize()` with user input in the pattern can lead to arbitrary code execution. Consider using
|
|
969
|
-
JSON or structured data approaches (e.g. Google Protocol Buffers).
|
|
970
|
-
cwe:
|
|
971
|
-
- CWE-502
|
|
972
|
-
owasp:
|
|
973
|
-
- A08:2017
|
|
974
|
-
- A08:2021
|
|
975
|
-
- A08:2025
|
|
976
|
-
references:
|
|
977
|
-
- https://www.php.net/manual/en/function.unserialize.php
|
|
978
|
-
- https://owasp.org/www-project-top-ten/2017/A8_2017-Insecure_Deserialization.html
|
|
979
|
-
tags:
|
|
980
|
-
- php
|
|
981
|
-
- id: weak-crypto
|
|
982
|
-
name: weak-crypto
|
|
983
|
-
description: Detected usage of weak crypto function. Consider using stronger alternatives.
|
|
984
|
-
category: crypto
|
|
985
|
-
severity: high
|
|
986
|
-
confidence: medium
|
|
987
|
-
languages:
|
|
988
|
-
- php
|
|
989
|
-
patterns:
|
|
990
|
-
- regex: .*
|
|
991
|
-
message: Detected usage of weak crypto function. Consider using stronger alternatives.
|
|
992
|
-
cwe:
|
|
993
|
-
- CWE-328
|
|
994
|
-
owasp:
|
|
995
|
-
- A03:2017
|
|
996
|
-
- A02:2021
|
|
997
|
-
- A04:2025
|
|
998
|
-
references:
|
|
999
|
-
- https://www.php.net/manual/en/book.sodium.php
|
|
1000
|
-
- >-
|
|
1001
|
-
https://github.com/FloeDesignTechnologies/phpcs-security-audit/blob/master/Security/Sniffs/BadFunctions/CryptoFunctionsSniff.php
|
|
1002
|
-
tags:
|
|
1003
|
-
- php
|
|
1004
|
-
- id: laravel-active-debug-code
|
|
1005
|
-
name: laravel-active-debug-code
|
|
1006
|
-
description: >-
|
|
1007
|
-
Found an instance setting the APP_DEBUG environment variable to true. In your production environment, this should
|
|
1008
|
-
always be false. Otherwise, you risk exposing sensitive configuration values to potential attackers. Instead, set
|
|
1009
|
-
this to false.
|
|
1010
|
-
category: security
|
|
1011
|
-
severity: high
|
|
1012
|
-
confidence: medium
|
|
1013
|
-
languages:
|
|
1014
|
-
- php
|
|
1015
|
-
patterns:
|
|
1016
|
-
- regex: .*
|
|
1017
|
-
message: >-
|
|
1018
|
-
Found an instance setting the APP_DEBUG environment variable to true. In your production environment, this
|
|
1019
|
-
should always be false. Otherwise, you risk exposing sensitive configuration values to potential attackers.
|
|
1020
|
-
Instead, set this to false.
|
|
1021
|
-
cwe:
|
|
1022
|
-
- CWE-489
|
|
1023
|
-
owasp:
|
|
1024
|
-
- A05:2021
|
|
1025
|
-
- A02:2025
|
|
1026
|
-
references:
|
|
1027
|
-
- https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Laravel_Cheat_Sheet.md
|
|
1028
|
-
- https://laravel.com/docs/9.x/configuration
|
|
1029
|
-
tags:
|
|
1030
|
-
- php
|
|
1031
|
-
- laravel
|
|
1032
|
-
- id: laravel-api-route-sql-injection
|
|
1033
|
-
name: laravel-api-route-sql-injection
|
|
1034
|
-
description: >-
|
|
1035
|
-
HTTP method [$METHOD] to Laravel route $ROUTE_NAME is vulnerable to SQL injection via string concatenation or
|
|
1036
|
-
unsafe interpolation.
|
|
1037
|
-
category: injection
|
|
1038
|
-
severity: medium
|
|
1039
|
-
confidence: medium
|
|
1040
|
-
languages:
|
|
1041
|
-
- php
|
|
1042
|
-
patterns:
|
|
1043
|
-
- regex: .*
|
|
1044
|
-
message: >-
|
|
1045
|
-
HTTP method [$METHOD] to Laravel route $ROUTE_NAME is vulnerable to SQL injection via string concatenation or
|
|
1046
|
-
unsafe interpolation.
|
|
1047
|
-
cwe:
|
|
1048
|
-
- CWE-89
|
|
1049
|
-
owasp:
|
|
1050
|
-
- A01:2017
|
|
1051
|
-
- A03:2021
|
|
1052
|
-
- A05:2025
|
|
1053
|
-
references:
|
|
1054
|
-
- https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Laravel_Cheat_Sheet.md
|
|
1055
|
-
tags:
|
|
1056
|
-
- php
|
|
1057
|
-
- laravel
|
|
1058
|
-
- id: laravel-cookie-http-only
|
|
1059
|
-
name: laravel-cookie-http-only
|
|
1060
|
-
description: >-
|
|
1061
|
-
Found a configuration file where the HttpOnly attribute is not set to true. Setting `http_only` to true makes sure
|
|
1062
|
-
that your cookies are inaccessible from Javascript, which mitigates XSS attacks. Instead, set the 'http_only' like
|
|
1063
|
-
so: `http_only` => true
|
|
1064
|
-
category: security
|
|
1065
|
-
severity: high
|
|
1066
|
-
confidence: medium
|
|
1067
|
-
languages:
|
|
1068
|
-
- php
|
|
1069
|
-
patterns:
|
|
1070
|
-
- pattern: |
|
|
1071
|
-
'cookie'
|
|
1072
|
-
message: >-
|
|
1073
|
-
Found a configuration file where the HttpOnly attribute is not set to true. Setting `http_only` to true makes
|
|
1074
|
-
sure that your cookies are inaccessible from Javascript, which mitigates XSS attacks. Instead, set the
|
|
1075
|
-
'http_only' like so: `http_only` => true
|
|
1076
|
-
cwe:
|
|
1077
|
-
- CWE-1004
|
|
1078
|
-
owasp:
|
|
1079
|
-
- A05:2021
|
|
1080
|
-
- A02:2025
|
|
1081
|
-
references:
|
|
1082
|
-
- https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Laravel_Cheat_Sheet.md
|
|
1083
|
-
tags:
|
|
1084
|
-
- php
|
|
1085
|
-
- laravel
|
|
1086
|
-
- id: laravel-cookie-long-timeout
|
|
1087
|
-
name: laravel-cookie-long-timeout
|
|
1088
|
-
description: Found a configuration file where the lifetime attribute is over 30 minutes.
|
|
1089
|
-
category: security
|
|
1090
|
-
severity: high
|
|
1091
|
-
confidence: medium
|
|
1092
|
-
languages:
|
|
1093
|
-
- php
|
|
1094
|
-
patterns:
|
|
1095
|
-
- pattern: |
|
|
1096
|
-
'lifetime'
|
|
1097
|
-
message: Found a configuration file where the lifetime attribute is over 30 minutes.
|
|
1098
|
-
cwe:
|
|
1099
|
-
- CWE-1004
|
|
1100
|
-
owasp:
|
|
1101
|
-
- A05:2021
|
|
1102
|
-
- A02:2025
|
|
1103
|
-
references:
|
|
1104
|
-
- https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Laravel_Cheat_Sheet.md
|
|
1105
|
-
tags:
|
|
1106
|
-
- php
|
|
1107
|
-
- laravel
|
|
1108
|
-
- id: laravel-cookie-null-domain
|
|
1109
|
-
name: laravel-cookie-null-domain
|
|
1110
|
-
description: >-
|
|
1111
|
-
Found a configuration file where the domain attribute is not set to null. It is recommended (unless you are using
|
|
1112
|
-
sub-domain route registrations) to set this attribute to null so that only the same origin can set the cookie,
|
|
1113
|
-
thus protecting your cookies.
|
|
1114
|
-
category: security
|
|
1115
|
-
severity: high
|
|
1116
|
-
confidence: medium
|
|
1117
|
-
languages:
|
|
1118
|
-
- php
|
|
1119
|
-
patterns:
|
|
1120
|
-
- pattern: |
|
|
1121
|
-
'cookie'
|
|
1122
|
-
message: >-
|
|
1123
|
-
Found a configuration file where the domain attribute is not set to null. It is recommended (unless you are
|
|
1124
|
-
using sub-domain route registrations) to set this attribute to null so that only the same origin can set the
|
|
1125
|
-
cookie, thus protecting your cookies.
|
|
1126
|
-
cwe:
|
|
1127
|
-
- CWE-200
|
|
1128
|
-
owasp:
|
|
1129
|
-
- A01:2021
|
|
1130
|
-
- A01:2025
|
|
1131
|
-
references:
|
|
1132
|
-
- https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Laravel_Cheat_Sheet.md
|
|
1133
|
-
tags:
|
|
1134
|
-
- php
|
|
1135
|
-
- laravel
|
|
1136
|
-
- id: laravel-cookie-same-site
|
|
1137
|
-
name: laravel-cookie-same-site
|
|
1138
|
-
description: >-
|
|
1139
|
-
Found a configuration file where the same_site attribute is not set to 'lax' or 'strict'. Setting 'same_site' to
|
|
1140
|
-
'lax' or 'strict' restricts cookies to a first-party or same-site context, which will protect your cookies and
|
|
1141
|
-
prevent CSRF.
|
|
1142
|
-
category: security
|
|
1143
|
-
severity: high
|
|
1144
|
-
confidence: medium
|
|
1145
|
-
languages:
|
|
1146
|
-
- php
|
|
1147
|
-
patterns:
|
|
1148
|
-
- pattern: |
|
|
1149
|
-
'cookie'
|
|
1150
|
-
message: >-
|
|
1151
|
-
Found a configuration file where the same_site attribute is not set to 'lax' or 'strict'. Setting 'same_site'
|
|
1152
|
-
to 'lax' or 'strict' restricts cookies to a first-party or same-site context, which will protect your cookies
|
|
1153
|
-
and prevent CSRF.
|
|
1154
|
-
cwe:
|
|
1155
|
-
- CWE-1275
|
|
1156
|
-
owasp:
|
|
1157
|
-
- A01:2021
|
|
1158
|
-
- A01:2025
|
|
1159
|
-
references:
|
|
1160
|
-
- https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Laravel_Cheat_Sheet.md
|
|
1161
|
-
tags:
|
|
1162
|
-
- php
|
|
1163
|
-
- laravel
|
|
1164
|
-
- id: laravel-cookie-secure-set
|
|
1165
|
-
name: laravel-cookie-secure-set
|
|
1166
|
-
description: >-
|
|
1167
|
-
Found a configuration file where the secure attribute is not set to 'true'. Setting 'secure' to 'true' prevents
|
|
1168
|
-
the client from transmitting the cookie over unencrypted channels and therefore prevents cookies from being stolen
|
|
1169
|
-
through man in the middle attacks.
|
|
1170
|
-
category: security
|
|
1171
|
-
severity: high
|
|
1172
|
-
confidence: medium
|
|
1173
|
-
languages:
|
|
1174
|
-
- php
|
|
1175
|
-
patterns:
|
|
1176
|
-
- pattern: |
|
|
1177
|
-
'cookie'
|
|
1178
|
-
message: >-
|
|
1179
|
-
Found a configuration file where the secure attribute is not set to 'true'. Setting 'secure' to 'true'
|
|
1180
|
-
prevents the client from transmitting the cookie over unencrypted channels and therefore prevents cookies from
|
|
1181
|
-
being stolen through man in the middle attacks.
|
|
1182
|
-
cwe:
|
|
1183
|
-
- CWE-614
|
|
1184
|
-
owasp:
|
|
1185
|
-
- A05:2021
|
|
1186
|
-
- A02:2025
|
|
1187
|
-
references:
|
|
1188
|
-
- https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Laravel_Cheat_Sheet.md
|
|
1189
|
-
tags:
|
|
1190
|
-
- php
|
|
1191
|
-
- laravel
|
|
1192
|
-
- id: laravel-dangerous-model-construction
|
|
1193
|
-
name: laravel-dangerous-model-construction
|
|
1194
|
-
description: >-
|
|
1195
|
-
Setting `$guarded` to an empty array allows mass assignment to every property in a Laravel model. This explicitly
|
|
1196
|
-
overrides Eloquent's safe-by-default mass assignment protections.
|
|
1197
|
-
category: security
|
|
1198
|
-
severity: high
|
|
1199
|
-
confidence: medium
|
|
1200
|
-
languages:
|
|
1201
|
-
- php
|
|
1202
|
-
patterns:
|
|
1203
|
-
- pattern: |
|
|
1204
|
-
$guarded = [];
|
|
1205
|
-
message: >-
|
|
1206
|
-
Setting `$guarded` to an empty array allows mass assignment to every property in a Laravel model. This
|
|
1207
|
-
explicitly overrides Eloquent's safe-by-default mass assignment protections.
|
|
1208
|
-
cwe:
|
|
1209
|
-
- CWE-915
|
|
1210
|
-
owasp:
|
|
1211
|
-
- A08:2021
|
|
1212
|
-
- A08:2025
|
|
1213
|
-
references:
|
|
1214
|
-
- https://laravel.com/docs/9.x/eloquent#allowing-mass-assignment
|
|
1215
|
-
- https://github.com/OWASP/CheatSheetSeries/blob/master/cheatsheets/Laravel_Cheat_Sheet.md
|
|
1216
|
-
tags:
|
|
1217
|
-
- php
|
|
1218
|
-
- laravel
|
|
1219
|
-
- eloquent
|
|
1220
|
-
- id: laravel-sql-injection
|
|
1221
|
-
name: laravel-sql-injection
|
|
1222
|
-
description: >-
|
|
1223
|
-
Detected a SQL query based on user input. This could lead to SQL injection, which could potentially result in
|
|
1224
|
-
sensitive data being exfiltrated by attackers. Instead, use parameterized queries and prepared statements.
|
|
1225
|
-
category: injection
|
|
1226
|
-
severity: medium
|
|
1227
|
-
confidence: medium
|
|
1228
|
-
languages:
|
|
1229
|
-
- php
|
|
1230
|
-
patterns:
|
|
1231
|
-
- regex: .*
|
|
1232
|
-
message: >-
|
|
1233
|
-
Detected a SQL query based on user input. This could lead to SQL injection, which could potentially result in
|
|
1234
|
-
sensitive data being exfiltrated by attackers. Instead, use parameterized queries and prepared statements.
|
|
1235
|
-
cwe:
|
|
1236
|
-
- CWE-89
|
|
1237
|
-
owasp:
|
|
1238
|
-
- A01:2017
|
|
1239
|
-
- A03:2021
|
|
1240
|
-
- A05:2025
|
|
1241
|
-
references:
|
|
1242
|
-
- https://laravel.com/docs/8.x/queries
|
|
1243
|
-
tags:
|
|
1244
|
-
- laravel
|
|
1245
|
-
- id: laravel-unsafe-validator
|
|
1246
|
-
name: laravel-unsafe-validator
|
|
1247
|
-
description: Found a request argument passed to an `ignore()` definition in a Rule constraint. This can lead to SQL injection.
|
|
1248
|
-
category: security
|
|
1249
|
-
severity: high
|
|
1250
|
-
confidence: medium
|
|
1251
|
-
languages:
|
|
1252
|
-
- php
|
|
1253
|
-
patterns:
|
|
1254
|
-
- regex: .*
|
|
1255
|
-
message: >-
|
|
1256
|
-
Found a request argument passed to an `ignore()` definition in a Rule constraint. This can lead to SQL
|
|
1257
|
-
injection.
|
|
1258
|
-
cwe:
|
|
1259
|
-
- CWE-89
|
|
1260
|
-
owasp:
|
|
1261
|
-
- A01:2017
|
|
1262
|
-
- A03:2021
|
|
1263
|
-
- A05:2025
|
|
1264
|
-
references:
|
|
1265
|
-
- https://laravel.com/docs/9.x/validation#rule-unique
|
|
1266
|
-
tags:
|
|
1267
|
-
- php
|
|
1268
|
-
- laravel
|
|
1269
|
-
- id: symfony-csrf-protection-disabled
|
|
1270
|
-
name: symfony-csrf-protection-disabled
|
|
1271
|
-
description: >-
|
|
1272
|
-
CSRF protection is disabled for this configuration. This is a security risk. Make sure that it is safe or consider
|
|
1273
|
-
setting `csrf_protection` property to `true`.
|
|
1274
|
-
category: api-security
|
|
1275
|
-
severity: medium
|
|
1276
|
-
confidence: medium
|
|
1277
|
-
languages:
|
|
1278
|
-
- php
|
|
1279
|
-
patterns:
|
|
1280
|
-
- regex: .*
|
|
1281
|
-
message: >-
|
|
1282
|
-
CSRF protection is disabled for this configuration. This is a security risk. Make sure that it is safe or
|
|
1283
|
-
consider setting `csrf_protection` property to `true`.
|
|
1284
|
-
cwe:
|
|
1285
|
-
- CWE-352
|
|
1286
|
-
owasp:
|
|
1287
|
-
- A01:2021
|
|
1288
|
-
- A01:2025
|
|
1289
|
-
references:
|
|
1290
|
-
- https://symfony.com/doc/current/security/csrf.html
|
|
1291
|
-
tags:
|
|
1292
|
-
- symfony
|
|
1293
|
-
- id: symfony-non-literal-redirect
|
|
1294
|
-
name: symfony-non-literal-redirect
|
|
1295
|
-
description: >-
|
|
1296
|
-
The `redirect()` method does not check its destination in any way. If you redirect to a URL provided by end-users,
|
|
1297
|
-
your application may be open to the unvalidated redirects security vulnerability. Consider using literal values or
|
|
1298
|
-
an allowlist to validate URLs.
|
|
1299
|
-
category: security
|
|
1300
|
-
severity: medium
|
|
1301
|
-
confidence: medium
|
|
1302
|
-
languages:
|
|
1303
|
-
- php
|
|
1304
|
-
patterns:
|
|
1305
|
-
- pattern: $this->redirect(...)
|
|
1306
|
-
message: >-
|
|
1307
|
-
The `redirect()` method does not check its destination in any way. If you redirect to a URL provided by
|
|
1308
|
-
end-users, your application may be open to the unvalidated redirects security vulnerability. Consider using
|
|
1309
|
-
literal values or an allowlist to validate URLs.
|
|
1310
|
-
cwe:
|
|
1311
|
-
- CWE-601
|
|
1312
|
-
owasp:
|
|
1313
|
-
- A01:2021
|
|
1314
|
-
- A01:2025
|
|
1315
|
-
references:
|
|
1316
|
-
- https://symfony.com/doc/current/controller.html#redirecting
|
|
1317
|
-
- https://cheatsheetseries.owasp.org/cheatsheets/Unvalidated_Redirects_and_Forwards_Cheat_Sheet.html
|
|
1318
|
-
tags:
|
|
1319
|
-
- symfony
|
|
1320
|
-
- id: symfony-permissive-cors
|
|
1321
|
-
name: symfony-permissive-cors
|
|
1322
|
-
description: Access-Control-Allow-Origin response header is set to "*". This will disable CORS Same Origin Policy restrictions.
|
|
1323
|
-
category: api-security
|
|
1324
|
-
severity: medium
|
|
1325
|
-
confidence: medium
|
|
1326
|
-
languages:
|
|
1327
|
-
- php
|
|
1328
|
-
patterns:
|
|
1329
|
-
- regex: .*
|
|
1330
|
-
message: >-
|
|
1331
|
-
Access-Control-Allow-Origin response header is set to "*". This will disable CORS Same Origin Policy
|
|
1332
|
-
restrictions.
|
|
1333
|
-
cwe:
|
|
1334
|
-
- CWE-346
|
|
1335
|
-
owasp:
|
|
1336
|
-
- A07:2021
|
|
1337
|
-
- A07:2025
|
|
1338
|
-
references:
|
|
1339
|
-
- https://developer.mozilla.org/ru/docs/Web/HTTP/Headers/Access-Control-Allow-Origin
|
|
1340
|
-
tags:
|
|
1341
|
-
- symfony
|
|
1342
|
-
- id: wp-ajax-no-auth-and-auth-hooks-audit
|
|
1343
|
-
name: wp-ajax-no-auth-and-auth-hooks-audit
|
|
1344
|
-
description: >-
|
|
1345
|
-
These hooks allow the developer to handle the custom AJAX endpoints."wp_ajax_$action" hook get fires for any
|
|
1346
|
-
authenticated user and "wp_ajax_nopriv_$action" hook get fires for non-authenticated users.
|
|
1347
|
-
category: auth
|
|
1348
|
-
severity: medium
|
|
1349
|
-
confidence: medium
|
|
1350
|
-
languages:
|
|
1351
|
-
- php
|
|
1352
|
-
patterns:
|
|
1353
|
-
- pattern: add_action($HOOK,...)
|
|
1354
|
-
message: >-
|
|
1355
|
-
These hooks allow the developer to handle the custom AJAX endpoints."wp_ajax_$action" hook get fires for any
|
|
1356
|
-
authenticated user and "wp_ajax_nopriv_$action" hook get fires for non-authenticated users.
|
|
1357
|
-
cwe:
|
|
1358
|
-
- CWE-285
|
|
1359
|
-
owasp:
|
|
1360
|
-
- A01:2021
|
|
1361
|
-
- A01:2025
|
|
1362
|
-
references:
|
|
1363
|
-
- https://github.com/wpscanteam/wpscan/wiki/WordPress-Plugin-Security-Testing-Cheat-Sheet#authorisation
|
|
1364
|
-
- https://developer.wordpress.org/reference/hooks/wp_ajax_action/
|
|
1365
|
-
tags:
|
|
1366
|
-
- Wordpress Plugins
|
|
1367
|
-
- id: wp-authorisation-checks-audit
|
|
1368
|
-
name: wp-authorisation-checks-audit
|
|
1369
|
-
description: These are some of the patterns used for authorisation. Look properly if the authorisation is proper or not.
|
|
1370
|
-
category: auth
|
|
1371
|
-
severity: medium
|
|
1372
|
-
confidence: medium
|
|
1373
|
-
languages:
|
|
1374
|
-
- php
|
|
1375
|
-
patterns:
|
|
1376
|
-
- pattern: $FUNCTION(...)
|
|
1377
|
-
message: These are some of the patterns used for authorisation. Look properly if the authorisation is proper or not.
|
|
1378
|
-
cwe:
|
|
1379
|
-
- CWE-285
|
|
1380
|
-
owasp:
|
|
1381
|
-
- A01:2021
|
|
1382
|
-
- A01:2025
|
|
1383
|
-
references:
|
|
1384
|
-
- https://github.com/wpscanteam/wpscan/wiki/WordPress-Plugin-Security-Testing-Cheat-Sheet#authorisation
|
|
1385
|
-
tags:
|
|
1386
|
-
- Wordpress Plugins
|
|
1387
|
-
- id: wp-code-execution-audit
|
|
1388
|
-
name: wp-code-execution-audit
|
|
1389
|
-
description: >-
|
|
1390
|
-
These functions can lead to code injection if the data inside them is user-controlled. Don't use the input
|
|
1391
|
-
directly or validate the data properly before passing it to these functions.
|
|
1392
|
-
category: security
|
|
1393
|
-
severity: medium
|
|
1394
|
-
confidence: medium
|
|
1395
|
-
languages:
|
|
1396
|
-
- php
|
|
1397
|
-
patterns:
|
|
1398
|
-
- regex: .*
|
|
1399
|
-
message: >-
|
|
1400
|
-
These functions can lead to code injection if the data inside them is user-controlled. Don't use the input
|
|
1401
|
-
directly or validate the data properly before passing it to these functions.
|
|
1402
|
-
cwe:
|
|
1403
|
-
- CWE-94
|
|
1404
|
-
owasp:
|
|
1405
|
-
- A03:2021
|
|
1406
|
-
- A05:2025
|
|
1407
|
-
references:
|
|
1408
|
-
- https://github.com/wpscanteam/wpscan/wiki/WordPress-Plugin-Security-Testing-Cheat-Sheet#php-code-execution
|
|
1409
|
-
tags:
|
|
1410
|
-
- Wordpress Plugins
|
|
1411
|
-
- id: wp-command-execution-audit
|
|
1412
|
-
name: wp-command-execution-audit
|
|
1413
|
-
description: >-
|
|
1414
|
-
These functions can lead to command execution if the data inside them is user-controlled. Don't use the input
|
|
1415
|
-
directly or validate the data properly before passing it to these functions.
|
|
1416
|
-
category: security
|
|
1417
|
-
severity: medium
|
|
1418
|
-
confidence: medium
|
|
1419
|
-
languages:
|
|
1420
|
-
- php
|
|
1421
|
-
patterns:
|
|
1422
|
-
- regex: .*
|
|
1423
|
-
message: >-
|
|
1424
|
-
These functions can lead to command execution if the data inside them is user-controlled. Don't use the input
|
|
1425
|
-
directly or validate the data properly before passing it to these functions.
|
|
1426
|
-
cwe:
|
|
1427
|
-
- CWE-78
|
|
1428
|
-
owasp:
|
|
1429
|
-
- A03:2021
|
|
1430
|
-
- A05:2025
|
|
1431
|
-
references:
|
|
1432
|
-
- https://github.com/wpscanteam/wpscan/wiki/WordPress-Plugin-Security-Testing-Cheat-Sheet#command-execution
|
|
1433
|
-
tags:
|
|
1434
|
-
- Wordpress Plugins
|
|
1435
|
-
- id: wp-csrf-audit
|
|
1436
|
-
name: wp-csrf-audit
|
|
1437
|
-
description: >-
|
|
1438
|
-
Passing false or 0 as the third argument to this function will not cause the script to die, making the check
|
|
1439
|
-
useless.
|
|
1440
|
-
category: api-security
|
|
1441
|
-
severity: medium
|
|
1442
|
-
confidence: medium
|
|
1443
|
-
languages:
|
|
1444
|
-
- php
|
|
1445
|
-
patterns:
|
|
1446
|
-
- pattern: check_ajax_referer(...,...,false)
|
|
1447
|
-
message: >-
|
|
1448
|
-
Passing false or 0 as the third argument to this function will not cause the script to die, making the check
|
|
1449
|
-
useless.
|
|
1450
|
-
cwe:
|
|
1451
|
-
- CWE-352
|
|
1452
|
-
owasp:
|
|
1453
|
-
- A05:2021
|
|
1454
|
-
- A02:2025
|
|
1455
|
-
references:
|
|
1456
|
-
- >-
|
|
1457
|
-
https://github.com/wpscanteam/wpscan/wiki/WordPress-Plugin-Security-Testing-Cheat-Sheet#cross-site-request-forgery-csrf
|
|
1458
|
-
- https://developer.wordpress.org/reference/functions/check_ajax_referer/
|
|
1459
|
-
tags:
|
|
1460
|
-
- Wordpress Plugins
|
|
1461
|
-
- id: wp-file-download-audit
|
|
1462
|
-
name: wp-file-download-audit
|
|
1463
|
-
description: >-
|
|
1464
|
-
These functions can be used to read to content of the files if the data inside is user-controlled. Don't use the
|
|
1465
|
-
input directly or validate the data properly before passing it to these functions.
|
|
1466
|
-
category: file-ops
|
|
1467
|
-
severity: medium
|
|
1468
|
-
confidence: medium
|
|
1469
|
-
languages:
|
|
1470
|
-
- php
|
|
1471
|
-
patterns:
|
|
1472
|
-
- regex: .*
|
|
1473
|
-
message: >-
|
|
1474
|
-
These functions can be used to read to content of the files if the data inside is user-controlled. Don't use
|
|
1475
|
-
the input directly or validate the data properly before passing it to these functions.
|
|
1476
|
-
cwe:
|
|
1477
|
-
- CWE-73
|
|
1478
|
-
owasp:
|
|
1479
|
-
- A01:2021
|
|
1480
|
-
- A01:2025
|
|
1481
|
-
references:
|
|
1482
|
-
- https://github.com/wpscanteam/wpscan/wiki/WordPress-Plugin-Security-Testing-Cheat-Sheet#file-download
|
|
1483
|
-
tags:
|
|
1484
|
-
- Wordpress Plugins
|
|
1485
|
-
- id: wp-file-inclusion-audit
|
|
1486
|
-
name: wp-file-inclusion-audit
|
|
1487
|
-
description: >-
|
|
1488
|
-
These functions can lead to Local File Inclusion (LFI) or Remote File Inclusion (RFI) if the data inside is
|
|
1489
|
-
user-controlled. Validate the data properly before passing it to these functions.
|
|
1490
|
-
category: file-ops
|
|
1491
|
-
severity: medium
|
|
1492
|
-
confidence: medium
|
|
1493
|
-
languages:
|
|
1494
|
-
- php
|
|
1495
|
-
patterns:
|
|
1496
|
-
- regex: .*
|
|
1497
|
-
message: >-
|
|
1498
|
-
These functions can lead to Local File Inclusion (LFI) or Remote File Inclusion (RFI) if the data inside is
|
|
1499
|
-
user-controlled. Validate the data properly before passing it to these functions.
|
|
1500
|
-
cwe:
|
|
1501
|
-
- CWE-22
|
|
1502
|
-
- CWE-73
|
|
1503
|
-
- CWE-98
|
|
1504
|
-
owasp:
|
|
1505
|
-
- A01:2021
|
|
1506
|
-
- A08:2021
|
|
1507
|
-
- A01:2025
|
|
1508
|
-
- A08:2025
|
|
1509
|
-
references:
|
|
1510
|
-
- https://github.com/wpscanteam/wpscan/wiki/WordPress-Plugin-Security-Testing-Cheat-Sheet#file-inclusion
|
|
1511
|
-
tags:
|
|
1512
|
-
- Wordpress Plugins
|
|
1513
|
-
- id: wp-file-manipulation-audit
|
|
1514
|
-
name: wp-file-manipulation-audit
|
|
1515
|
-
description: >-
|
|
1516
|
-
These functions can be used to delete the files if the data inside the functions are user controlled. Use these
|
|
1517
|
-
functions carefully.
|
|
1518
|
-
category: file-ops
|
|
1519
|
-
severity: medium
|
|
1520
|
-
confidence: medium
|
|
1521
|
-
languages:
|
|
1522
|
-
- php
|
|
1523
|
-
patterns:
|
|
1524
|
-
- regex: .*
|
|
1525
|
-
message: >-
|
|
1526
|
-
These functions can be used to delete the files if the data inside the functions are user controlled. Use
|
|
1527
|
-
these functions carefully.
|
|
1528
|
-
cwe:
|
|
1529
|
-
- CWE-22
|
|
1530
|
-
- CWE-73
|
|
1531
|
-
- CWE-98
|
|
1532
|
-
owasp:
|
|
1533
|
-
- A01:2021
|
|
1534
|
-
- A08:2021
|
|
1535
|
-
- A01:2025
|
|
1536
|
-
- A08:2025
|
|
1537
|
-
references:
|
|
1538
|
-
- https://github.com/wpscanteam/wpscan/wiki/WordPress-Plugin-Security-Testing-Cheat-Sheet#file-manipulation
|
|
1539
|
-
tags:
|
|
1540
|
-
- Wordpress Plugins
|
|
1541
|
-
- id: wp-open-redirect-audit
|
|
1542
|
-
name: wp-open-redirect-audit
|
|
1543
|
-
description: >-
|
|
1544
|
-
This function can be used to redirect to user supplied URLs. If user input is not sanitised or validated, this
|
|
1545
|
-
could lead to Open Redirect vulnerabilities. Use "wp_safe_redirect()" to prevent this kind of attack.
|
|
1546
|
-
category: security
|
|
1547
|
-
severity: medium
|
|
1548
|
-
confidence: medium
|
|
1549
|
-
languages:
|
|
1550
|
-
- php
|
|
1551
|
-
patterns:
|
|
1552
|
-
- pattern: wp_redirect(...)
|
|
1553
|
-
message: >-
|
|
1554
|
-
This function can be used to redirect to user supplied URLs. If user input is not sanitised or validated, this
|
|
1555
|
-
could lead to Open Redirect vulnerabilities. Use "wp_safe_redirect()" to prevent this kind of attack.
|
|
1556
|
-
cwe:
|
|
1557
|
-
- CWE-601
|
|
1558
|
-
owasp:
|
|
1559
|
-
- A05:2021
|
|
1560
|
-
- A02:2025
|
|
1561
|
-
references:
|
|
1562
|
-
- https://github.com/wpscanteam/wpscan/wiki/WordPress-Plugin-Security-Testing-Cheat-Sheet#open-redirect
|
|
1563
|
-
- https://developer.wordpress.org/reference/functions/wp_safe_redirect/
|
|
1564
|
-
tags:
|
|
1565
|
-
- Wordpress Plugins
|
|
1566
|
-
- id: wp-php-object-injection-audit
|
|
1567
|
-
name: wp-php-object-injection-audit
|
|
1568
|
-
description: >-
|
|
1569
|
-
If the data used inside the patterns are directly used without proper sanitization, then this could lead to PHP
|
|
1570
|
-
Object Injection. Do not use these function with user-supplied input, use JSON functions instead.
|
|
1571
|
-
category: security
|
|
1572
|
-
severity: medium
|
|
1573
|
-
confidence: medium
|
|
1574
|
-
languages:
|
|
1575
|
-
- php
|
|
1576
|
-
patterns:
|
|
1577
|
-
- regex: .*
|
|
1578
|
-
message: >-
|
|
1579
|
-
If the data used inside the patterns are directly used without proper sanitization, then this could lead to
|
|
1580
|
-
PHP Object Injection. Do not use these function with user-supplied input, use JSON functions instead.
|
|
1581
|
-
cwe:
|
|
1582
|
-
- CWE-502
|
|
1583
|
-
owasp:
|
|
1584
|
-
- A03:2021
|
|
1585
|
-
- A05:2025
|
|
1586
|
-
references:
|
|
1587
|
-
- https://github.com/wpscanteam/wpscan/wiki/WordPress-Plugin-Security-Testing-Cheat-Sheet#php-object-injection
|
|
1588
|
-
- https://owasp.org/www-community/vulnerabilities/PHP_Object_Injection
|
|
1589
|
-
tags:
|
|
1590
|
-
- Wordpress Plugins
|
|
1591
|
-
- id: wp-sql-injection-audit
|
|
1592
|
-
name: wp-sql-injection-audit
|
|
1593
|
-
description: >-
|
|
1594
|
-
Detected unsafe API methods. This could lead to SQL Injection if the used variable in the functions are user
|
|
1595
|
-
controlled and not properly escaped or sanitized. In order to prevent SQL Injection, use safe api methods like
|
|
1596
|
-
"$wpdb->prepare" properly or escape/sanitize the data properly.
|
|
1597
|
-
category: injection
|
|
1598
|
-
severity: medium
|
|
1599
|
-
confidence: medium
|
|
1600
|
-
languages:
|
|
1601
|
-
- php
|
|
1602
|
-
patterns:
|
|
1603
|
-
- regex: .*
|
|
1604
|
-
message: >-
|
|
1605
|
-
Detected unsafe API methods. This could lead to SQL Injection if the used variable in the functions are user
|
|
1606
|
-
controlled and not properly escaped or sanitized. In order to prevent SQL Injection, use safe api methods like
|
|
1607
|
-
"$wpdb->prepare" properly or escape/sanitize the data properly.
|
|
1608
|
-
cwe:
|
|
1609
|
-
- CWE-89
|
|
1610
|
-
owasp:
|
|
1611
|
-
- A03:2021
|
|
1612
|
-
- A05:2025
|
|
1613
|
-
references:
|
|
1614
|
-
- https://github.com/wpscanteam/wpscan/wiki/WordPress-Plugin-Security-Testing-Cheat-Sheet#sql-injection
|
|
1615
|
-
- https://owasp.org/www-community/attacks/SQL_Injection
|
|
1616
|
-
tags:
|
|
1617
|
-
- Wordpress Plugins
|
|
1618
|
-
- id: wp-ssrf-audit
|
|
1619
|
-
name: wp-ssrf-audit
|
|
1620
|
-
description: Detected usage of vulnerable functions with user input, which could lead to SSRF vulnerabilities.
|
|
1621
|
-
category: api-security
|
|
1622
|
-
severity: medium
|
|
1623
|
-
confidence: medium
|
|
1624
|
-
languages:
|
|
1625
|
-
- php
|
|
1626
|
-
patterns:
|
|
1627
|
-
- regex: .*
|
|
1628
|
-
message: Detected usage of vulnerable functions with user input, which could lead to SSRF vulnerabilities.
|
|
1629
|
-
cwe:
|
|
1630
|
-
- CWE-918
|
|
1631
|
-
owasp:
|
|
1632
|
-
- A10:2021
|
|
1633
|
-
references:
|
|
1634
|
-
- https://developer.wordpress.org/reference/functions/wp_safe_remote_get/
|
|
1635
|
-
- https://developer.wordpress.org/reference/functions/wp_remote_get/
|
|
1636
|
-
- https://patchstack.com/articles/exploring-the-unpatched-wordpress-ssrf/
|
|
1637
|
-
tags:
|
|
1638
|
-
- Wordpress Plugins
|