@lintsure/core 0.3.10 → 0.3.11
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/dist/src/index.d.ts +32 -1
- package/dist/src/index.js +153 -19
- package/dist/src/knowledge/cra.js +1 -1
- package/dist/src/knowledge/more.js +5 -5
- package/dist/src/knowledge/owasp-top10.js +3 -3
- package/dist/src/packs.d.ts +8 -0
- package/dist/src/packs.js +11 -1
- package/dist/src/plan.d.ts +3 -0
- package/dist/src/plan.js +35 -0
- package/dist/src/reach.d.ts +32 -0
- package/dist/src/reach.js +206 -0
- package/dist/src/rules/index.js +15 -4
- package/dist/src/rules/owasp.d.ts +2 -0
- package/dist/src/rules/owasp.js +60 -4
- package/dist/src/rules/stack.d.ts +12 -0
- package/dist/src/rules/stack.js +53 -5
- package/dist/src/rules/standards.js +20 -3
- package/dist/src/sarif.d.ts +56 -25
- package/dist/src/sarif.js +9 -1
- package/dist/src/types.d.ts +41 -0
- package/docs/README.md +13 -0
- package/docs/agents.md +107 -0
- package/docs/frameworks.md +147 -0
- package/docs/rules.md +600 -0
- package/package.json +42 -41
package/docs/rules.md
ADDED
|
@@ -0,0 +1,600 @@
|
|
|
1
|
+
<!-- Generated from Lintsure 0.3.11 by scripts/build-docs.mjs. -->
|
|
2
|
+
# Lintsure rules (74)
|
|
3
|
+
|
|
4
|
+
## pii.logged
|
|
5
|
+
**Personal data written to logs** · status when found: gap · risk: high
|
|
6
|
+
|
|
7
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A09:2025 (Security Logging and Alerting Failures); cra Annex I Part I (2)(g) (Data minimisation); owasp-llm LLM02:2026 (Sensitive Information Disclosure); cwe-top25 CWE-200 (Exposure of Sensitive Information)
|
|
8
|
+
- Fix: Mask or remove the personal field before logging, for example mask(user.email).
|
|
9
|
+
- Note: Logs are copied to many places and kept for a long time. Personal data in them is hard to find and delete.
|
|
10
|
+
- Page: https://lintsure.com/rules/pii-logged
|
|
11
|
+
|
|
12
|
+
## secret.in-source
|
|
13
|
+
**Secret or private key committed to source** · status when found: gap · risk: high
|
|
14
|
+
|
|
15
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A04:2025 (Cryptographic Failures); owasp-top10 A07:2025 (Authentication Failures); cra Annex I Part I (2)(e) (Confidentiality of data); owasp-llm LLM02:2026 (Sensitive Information Disclosure)
|
|
16
|
+
- Fix: Move the secret to an environment variable or secrets manager, then rotate it: it is already in your git history.
|
|
17
|
+
- Note: Anyone with read access to the repo, or a leaked copy of it, can use this key.
|
|
18
|
+
- Page: https://lintsure.com/rules/secret-in-source
|
|
19
|
+
|
|
20
|
+
## transport.plain-http
|
|
21
|
+
**Data sent over plain HTTP** · status when found: partial · risk: medium
|
|
22
|
+
|
|
23
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A04:2025 (Cryptographic Failures); cra Annex I Part I (2)(e) (Confidentiality of data)
|
|
24
|
+
- Fix: Use https:// for every external call.
|
|
25
|
+
- Note: Marked Partial: the call may carry no sensitive data. Confirm, then switch to HTTPS anyway.
|
|
26
|
+
- Page: https://lintsure.com/rules/transport-plain-http
|
|
27
|
+
|
|
28
|
+
## pii.to-analytics
|
|
29
|
+
**Personal data sent to an analytics or tracking tool** · status when found: gap · risk: high
|
|
30
|
+
|
|
31
|
+
- Controls: gdpr Art. 5(1)(c) (Data minimisation); cra Annex I Part I (2)(g) (Data minimisation)
|
|
32
|
+
- Fix: Send an internal user ID instead of the email or name. If personal data must go there, list the tool as a processor.
|
|
33
|
+
- Note: Analytics vendors keep what you send them. Personal data there needs a lawful basis and a processing agreement.
|
|
34
|
+
- Page: https://lintsure.com/rules/pii-to-analytics
|
|
35
|
+
|
|
36
|
+
## pii.in-url
|
|
37
|
+
**Personal data or tokens in a URL** · status when found: partial · risk: medium · medium confidence (shown with --all)
|
|
38
|
+
|
|
39
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A06:2025 (Insecure Design); cra Annex I Part I (2)(g) (Data minimisation); cwe-top25 CWE-200 (Exposure of Sensitive Information)
|
|
40
|
+
- Fix: Send it in the request body or a header instead of the query string.
|
|
41
|
+
- Note: URLs end up in server logs, browser history and referrer headers. Marked Partial: confirm the value is real personal data.
|
|
42
|
+
- Page: https://lintsure.com/rules/pii-in-url
|
|
43
|
+
|
|
44
|
+
## crypto.weak-password-hash
|
|
45
|
+
**Passwords hashed with a weak or fast algorithm** · status when found: gap · risk: high
|
|
46
|
+
|
|
47
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A04:2025 (Cryptographic Failures); cra Annex I Part I (2)(e) (Confidentiality of data)
|
|
48
|
+
- Fix: Use a password hashing function made for it: argon2id, scrypt or bcrypt.
|
|
49
|
+
- Note: MD5 and SHA-1 are fast, so leaked hashes can be cracked quickly.
|
|
50
|
+
- Page: https://lintsure.com/rules/crypto-weak-password-hash
|
|
51
|
+
|
|
52
|
+
## transport.tls-verify-off
|
|
53
|
+
**TLS certificate checks turned off** · status when found: gap · risk: high · medium confidence (shown with --all)
|
|
54
|
+
|
|
55
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A04:2025 (Cryptographic Failures); owasp-top10 A07:2025 (Authentication Failures); cra Annex I Part I (2)(e) (Confidentiality of data)
|
|
56
|
+
- Fix: Remove the override and trust a proper certificate. For self-signed certs in tests, scope it to the test only.
|
|
57
|
+
- Note: With checks off, anyone on the network path can read or change the traffic.
|
|
58
|
+
- Page: https://lintsure.com/rules/transport-tls-verify-off
|
|
59
|
+
|
|
60
|
+
## sql.string-built
|
|
61
|
+
**SQL query built from strings** · status when found: gap · risk: high · medium confidence (shown with --all)
|
|
62
|
+
|
|
63
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A05:2025 (Injection); cra Annex I Part I (2)(f) (Integrity of data and programs); cwe-top25 CWE-89 (SQL Injection)
|
|
64
|
+
- Fix: Use parameterized queries or your ORM's query builder. If the inserted value is fixed text from your own code, confirm it can never come from a user.
|
|
65
|
+
- Note: String-built SQL can let an attacker read or change your data (SQL injection). Marked Gap when the inserted value looks like user input, Partial when it may be fixed text from your code.
|
|
66
|
+
- Page: https://lintsure.com/rules/sql-string-built
|
|
67
|
+
|
|
68
|
+
## cors.any-origin
|
|
69
|
+
**API open to any website, with cookies or credentials** · status when found: partial · risk: high · medium confidence (shown with --all)
|
|
70
|
+
|
|
71
|
+
- Controls: owasp-top10 A02:2025 (Security Misconfiguration); owasp-top10 A01:2025 (Broken Access Control); cra Annex I Part I (2)(b) (Secure by default configuration)
|
|
72
|
+
- Fix: List the exact origins that may call the API. Never combine an open or reflected origin with credentials.
|
|
73
|
+
- Note: Any website can then make logged-in requests on your users' behalf and read the answers. An open origin without credentials is fine for a public API and is not reported (as in CodeQL's CORS check). Marked Partial: confirm the endpoint returns private data.
|
|
74
|
+
- Page: https://lintsure.com/rules/cors-any-origin
|
|
75
|
+
|
|
76
|
+
## session.cookie-insecure
|
|
77
|
+
**Session cookie without Secure or HttpOnly** · status when found: partial · risk: low · medium confidence (shown with --all)
|
|
78
|
+
|
|
79
|
+
- Controls: owasp-top10 A02:2025 (Security Misconfiguration); owasp-top10 A07:2025 (Authentication Failures); cra Annex I Part I (2)(b) (Secure by default configuration)
|
|
80
|
+
- Fix: Set secure: true and httpOnly: true on session cookies.
|
|
81
|
+
- Note: Without these flags a session cookie can be read by scripts or sent over plain HTTP. Marked Partial: confirm it is a session cookie.
|
|
82
|
+
- Page: https://lintsure.com/rules/session-cookie-insecure
|
|
83
|
+
|
|
84
|
+
## config.debug-on
|
|
85
|
+
**Debug mode switched on in code** · status when found: partial · risk: medium · medium confidence (shown with --all)
|
|
86
|
+
|
|
87
|
+
- Controls: owasp-top10 A02:2025 (Security Misconfiguration); cra Annex I Part I (2)(b) (Secure by default configuration)
|
|
88
|
+
- Fix: Read debug from an environment variable that is off in production.
|
|
89
|
+
- Note: Debug pages can show stack traces, settings and secrets. Marked Partial: it may only run locally.
|
|
90
|
+
- Page: https://lintsure.com/rules/config-debug-on
|
|
91
|
+
|
|
92
|
+
## ai.automated-decision
|
|
93
|
+
**AI makes a decision about a person with no human check in the code** · status when found: partial · risk: high
|
|
94
|
+
|
|
95
|
+
- Controls: eu-ai-act Art. 14 (Human oversight); gdpr Art. 22 (Automated individual decisions)
|
|
96
|
+
- Fix: Route the result to a review step where a person can confirm or override it, and record who did.
|
|
97
|
+
- Note: Credit, hiring, admission and similar decisions about people are high-risk under Annex III. Marked Partial: a review step may exist elsewhere.
|
|
98
|
+
- Page: https://lintsure.com/rules/ai-automated-decision
|
|
99
|
+
|
|
100
|
+
## ai.call-not-logged
|
|
101
|
+
**AI call with no record kept near it** · status when found: partial · risk: medium · medium confidence (shown with --all)
|
|
102
|
+
|
|
103
|
+
- Controls: eu-ai-act Art. 12 (Record-keeping); owasp-top10 A09:2025 (Security Logging and Alerting Failures)
|
|
104
|
+
- Fix: Log each AI call: time, model and version, input reference and output, without raw personal data.
|
|
105
|
+
- Note: High-risk systems must keep logs that let you trace what the AI did. Marked Partial: logging may happen in a wrapper or another file.
|
|
106
|
+
- Page: https://lintsure.com/rules/ai-call-not-logged
|
|
107
|
+
|
|
108
|
+
## ai.hides-being-ai
|
|
109
|
+
**AI told to hide that it is an AI** · status when found: partial · risk: high
|
|
110
|
+
|
|
111
|
+
- Controls: eu-ai-act Art. 50(1) (Transparency for AI interacting with people)
|
|
112
|
+
- Fix: Remove the instruction and tell users they are talking to an AI.
|
|
113
|
+
- Note: People must be told when they interact with an AI system, unless it is obvious. Marked Partial: role-play wording can be harmless.
|
|
114
|
+
- Page: https://lintsure.com/rules/ai-hides-being-ai
|
|
115
|
+
|
|
116
|
+
## ai.synthetic-media
|
|
117
|
+
**AI-generated images, audio or video** · status when found: partial · risk: medium · medium confidence (shown with --all)
|
|
118
|
+
|
|
119
|
+
- Controls: eu-ai-act Art. 50(2) (Marking AI-generated content)
|
|
120
|
+
- Fix: Mark generated media as AI-made in a machine-readable way (for example C2PA metadata) and label deepfakes for viewers.
|
|
121
|
+
- Note: Marked Partial: you may already add marking after this call. Confirm it does.
|
|
122
|
+
- Page: https://lintsure.com/rules/ai-synthetic-media
|
|
123
|
+
|
|
124
|
+
## ai.emotion-or-biometric
|
|
125
|
+
**Emotion recognition or biometric categorisation** · status when found: partial · risk: high
|
|
126
|
+
|
|
127
|
+
- Controls: eu-ai-act Art. 5(1)(f) (Prohibited: emotion recognition at work and in education); eu-ai-act Annex III(1) (High-risk: biometrics); gdpr Art. 9 (Special categories of personal data)
|
|
128
|
+
- Fix: Check whether this use is banned or high-risk before shipping. Remove it if it infers emotions of staff or students.
|
|
129
|
+
- Note: Some uses are banned outright since February 2025 (emotion recognition at work or in education); others are high-risk. Marked Partial: whether a ban applies depends on whose data is analysed and where, which code can't show.
|
|
130
|
+
- Page: https://lintsure.com/rules/ai-emotion-or-biometric
|
|
131
|
+
|
|
132
|
+
## path.user-input
|
|
133
|
+
**File path built from request data** · status when found: gap · risk: high
|
|
134
|
+
|
|
135
|
+
- Controls: owasp-top10 A01:2025 (Broken Access Control); cra Annex I Part I (2)(d) (Protection from unauthorised access); cwe-top25 CWE-22 (Path Traversal)
|
|
136
|
+
- Fix: Don't pass request values into file paths. Map the request to a known file name, or use path.basename and check the result stays inside the allowed folder.
|
|
137
|
+
- Note: A path like ../../etc/passwd lets someone read or overwrite files outside the folder you meant (path traversal, CWE-22).
|
|
138
|
+
- Page: https://lintsure.com/rules/path-user-input
|
|
139
|
+
|
|
140
|
+
## redirect.open
|
|
141
|
+
**Redirect to a URL taken from the request** · status when found: gap · risk: medium
|
|
142
|
+
|
|
143
|
+
- Controls: owasp-top10 A01:2025 (Broken Access Control); cra Annex I Part I (2)(j) (Limited attack surface)
|
|
144
|
+
- Fix: Redirect only to paths on your own site, or check the target against a list of allowed hosts.
|
|
145
|
+
- Note: Attackers send people a link to your site that bounces them to a phishing page (open redirect, CWE-601).
|
|
146
|
+
- Page: https://lintsure.com/rules/redirect-open
|
|
147
|
+
|
|
148
|
+
## ssrf.user-url
|
|
149
|
+
**Server fetches a URL taken from the request** · status when found: gap · risk: high
|
|
150
|
+
|
|
151
|
+
- Controls: owasp-top10 A01:2025 (Broken Access Control); cra Annex I Part I (2)(j) (Limited attack surface); cwe-top25 CWE-918 (Server-Side Request Forgery)
|
|
152
|
+
- Fix: Don't let users choose the full URL your server calls. Allow only known hosts, and block internal addresses such as 169.254.169.254 and localhost.
|
|
153
|
+
- Note: Your server can be made to call internal services or cloud metadata on an attacker's behalf (server-side request forgery, CWE-918).
|
|
154
|
+
- Page: https://lintsure.com/rules/ssrf-user-url
|
|
155
|
+
|
|
156
|
+
## csrf.disabled
|
|
157
|
+
**CSRF protection switched off** · status when found: partial · risk: medium
|
|
158
|
+
|
|
159
|
+
- Controls: owasp-top10 A01:2025 (Broken Access Control); cra Annex I Part I (2)(b) (Secure by default configuration); cwe-top25 CWE-352 (Cross-Site Request Forgery)
|
|
160
|
+
- Fix: Keep CSRF protection on for routes that use cookies. Turning it off is only safe for APIs that authenticate with a token header, not cookies.
|
|
161
|
+
- Note: Another site can make a logged-in user's browser submit forms to your app (cross-site request forgery, CWE-352).
|
|
162
|
+
- Page: https://lintsure.com/rules/csrf-disabled
|
|
163
|
+
|
|
164
|
+
## fs.world-writable
|
|
165
|
+
**File made readable and writable by everyone** · status when found: gap · risk: medium
|
|
166
|
+
|
|
167
|
+
- Controls: owasp-top10 A01:2025 (Broken Access Control); cra Annex I Part I (2)(d) (Protection from unauthorised access); cwe-top25 CWE-284 (Improper Access Control)
|
|
168
|
+
- Fix: Use the narrowest permissions that work, for example 0o600 for secrets and 0o644 or 0o755 for public files.
|
|
169
|
+
- Note: Any user or process on the machine can change the file (incorrect permissions, CWE-732).
|
|
170
|
+
- Page: https://lintsure.com/rules/fs-world-writable
|
|
171
|
+
|
|
172
|
+
## config.allowed-hosts-any
|
|
173
|
+
**Django accepts any host name** · status when found: gap · risk: medium
|
|
174
|
+
|
|
175
|
+
- Controls: owasp-top10 A02:2025 (Security Misconfiguration); cra Annex I Part I (2)(b) (Secure by default configuration)
|
|
176
|
+
- Fix: List your real domains in ALLOWED_HOSTS, ideally from an environment variable per environment.
|
|
177
|
+
- Note: Any Host header is accepted, which enables host header attacks such as poisoned password reset links.
|
|
178
|
+
- Page: https://lintsure.com/rules/config-allowed-hosts-any
|
|
179
|
+
|
|
180
|
+
## config.default-secret-key
|
|
181
|
+
**Default or placeholder secret key** · status when found: gap · risk: high
|
|
182
|
+
|
|
183
|
+
- Controls: owasp-top10 A02:2025 (Security Misconfiguration); owasp-top10 A07:2025 (Authentication Failures); cra Annex I Part I (2)(b) (Secure by default configuration)
|
|
184
|
+
- Fix: Generate a long random secret per environment and load it from an environment variable or secret manager.
|
|
185
|
+
- Note: With a known secret key, attackers can forge sessions, cookies or signed tokens (CWE-1394).
|
|
186
|
+
- Page: https://lintsure.com/rules/config-default-secret-key
|
|
187
|
+
|
|
188
|
+
## xml.external-entities
|
|
189
|
+
**XML parser may load external entities** · status when found: partial · risk: high
|
|
190
|
+
|
|
191
|
+
- Controls: owasp-top10 A02:2025 (Security Misconfiguration); cra Annex I Part I (2)(f) (Integrity of data and programs)
|
|
192
|
+
- Fix: Use defusedxml in Python, or turn off entity resolution and DTD loading in your parser.
|
|
193
|
+
- Note: A crafted XML file can read local files or call internal URLs (XML external entities, CWE-611).
|
|
194
|
+
- Page: https://lintsure.com/rules/xml-external-entities
|
|
195
|
+
|
|
196
|
+
## deps.unpinned-version
|
|
197
|
+
**Dependency with no version limit** · status when found: gap · risk: medium
|
|
198
|
+
|
|
199
|
+
- Controls: owasp-top10 A03:2025 (Software Supply Chain Failures); cra Annex I Part II (1) (Components identified, including an SBOM); owasp-llm LLM04:2026 (Supply Chain)
|
|
200
|
+
- Fix: Pin a version or a range in package.json and commit the lockfile, so every install gets the code you tested.
|
|
201
|
+
- Note: "*" or "latest" installs whatever is published next, including a compromised release (CWE-1357).
|
|
202
|
+
- Page: https://lintsure.com/rules/deps-unpinned-version
|
|
203
|
+
|
|
204
|
+
## deps.install-script
|
|
205
|
+
**Install script downloads code** · status when found: partial · risk: medium
|
|
206
|
+
|
|
207
|
+
- Controls: owasp-top10 A03:2025 (Software Supply Chain Failures); cra Annex I Part II (1) (Components identified, including an SBOM); owasp-llm LLM04:2026 (Supply Chain)
|
|
208
|
+
- Fix: Avoid downloading and running code in preinstall or postinstall. Vendor the file or document a manual step.
|
|
209
|
+
- Note: Code fetched at install time isn't pinned or reviewed and runs with the installer's permissions (CWE-829).
|
|
210
|
+
- Page: https://lintsure.com/rules/deps-install-script
|
|
211
|
+
|
|
212
|
+
## agent.config-runs-remote-code
|
|
213
|
+
**Agent config downloads and runs code** · status when found: gap · risk: high
|
|
214
|
+
|
|
215
|
+
- Controls: owasp-top10 A03:2025 (Software Supply Chain Failures)
|
|
216
|
+
- Fix: Don't download and run scripts from agent hooks, MCP server commands or editor tasks. Pin a reviewed local script or a versioned package instead, and review changes to these files like code.
|
|
217
|
+
- Note: Agents run these commands on their own, often at startup, with your user's permissions. A changed URL or script runs on every machine that opens the repo (CWE-829, CWE-494).
|
|
218
|
+
- Seen in a real incident: CVE-2025-59536: commands in a cloned repo's Claude Code project settings ran when it was opened (Check Point Research) (https://research.checkpoint.com/2026/rce-and-api-token-exfiltration-through-claude-code-project-files-cve-2025-59536/)
|
|
219
|
+
- Page: https://lintsure.com/rules/agent-config-runs-remote-code
|
|
220
|
+
|
|
221
|
+
## agent.instructions-unsafe
|
|
222
|
+
**Agent instructions that override, hide or download and run** · status when found: gap · risk: high
|
|
223
|
+
|
|
224
|
+
- Controls: owasp-top10 A03:2025 (Software Supply Chain Failures); owasp-llm LLM01:2026 (Prompt Injection)
|
|
225
|
+
- Fix: Remove the line, or rewrite it so the agent asks the user first. Install tools with a pinned, reviewed command instead of piping a download into a shell, and never tell an agent to keep something from the user.
|
|
226
|
+
- Note: Agents read these files as instructions and act on them with your permissions. Gap when the line overrides earlier instructions, hides something from the user or sends secrets out. Partial when it downloads and runs a script, which some setup guides do on purpose (CWE-829, OWASP LLM01).
|
|
227
|
+
- When Partial, Lintsure can't see: Lintsure reads the line, not who wrote it or whether the file came from a trusted skill. Check where this file came from before an agent uses it.
|
|
228
|
+
- Page: https://lintsure.com/rules/agent-instructions-unsafe
|
|
229
|
+
|
|
230
|
+
## agent.permissions-allow-all
|
|
231
|
+
**Agent settings that skip every permission prompt** · status when found: gap · risk: high
|
|
232
|
+
|
|
233
|
+
- Controls: owasp-top10 A02:2025 (Security Misconfiguration); owasp-llm LLM03:2026 (Excessive Agency)
|
|
234
|
+
- Fix: Remove the bypass from the shared project file. Allow the few commands you trust by name (for example Bash(npm test)), and keep wider permissions in your own local settings, not in the repo.
|
|
235
|
+
- Note: Committed agent settings apply to everyone who opens the repo with that agent. Skipping prompts or allowing every shell command lets a bad instruction, a poisoned file or a mistake run without a person seeing it (CWE-250, OWASP LLM03 Excessive Agency).
|
|
236
|
+
- Page: https://lintsure.com/rules/agent-permissions-allow-all
|
|
237
|
+
|
|
238
|
+
## ci.action-unpinned
|
|
239
|
+
**Third-party GitHub Action not pinned to a commit** · status when found: partial · risk: medium
|
|
240
|
+
|
|
241
|
+
- Controls: owasp-top10 A03:2025 (Software Supply Chain Failures); cra Annex I Part II (7) (Updates distributed securely)
|
|
242
|
+
- Fix: Pin third-party actions to a full commit SHA, with the version as a comment, for example uses: owner/action@<40-character sha> # v2.
|
|
243
|
+
- Note: A tag like @v1 can be moved by the action's owner, or by whoever takes over their account (CWE-829).
|
|
244
|
+
- Seen in a real incident: CVE-2025-30066: tj-actions/changed-files tags were moved to a malicious commit that printed CI secrets to logs (CISA alert) (https://www.cisa.gov/news-events/alerts/2025/03/18/supply-chain-compromise-third-party-tj-actionschanged-files-cve-2025-30066-and-reviewdogaction)
|
|
245
|
+
- Page: https://lintsure.com/rules/ci-action-unpinned
|
|
246
|
+
|
|
247
|
+
## ci.prt-checkout-head
|
|
248
|
+
**pull_request_target workflow checks out untrusted code** · status when found: gap · risk: high
|
|
249
|
+
|
|
250
|
+
- Controls: owasp-top10 A03:2025 (Software Supply Chain Failures); owasp-top10 A08:2025 (Software or Data Integrity Failures); cra Annex I Part II (7) (Updates distributed securely)
|
|
251
|
+
- Fix: Use the pull_request trigger for workflows that build or run code from a pull request. If you need pull_request_target, never check out the pull request's code in it.
|
|
252
|
+
- Note: pull_request_target runs with your repository's secrets; checking out the contributor's code lets a pull request run with them (CWE-829).
|
|
253
|
+
- Page: https://lintsure.com/rules/ci-prt-checkout-head
|
|
254
|
+
|
|
255
|
+
## crypto.weak-random-token
|
|
256
|
+
**Predictable random numbers used for a secret** · status when found: gap · risk: high · medium confidence (shown with --all)
|
|
257
|
+
|
|
258
|
+
- Controls: owasp-top10 A04:2025 (Cryptographic Failures); cra Annex I Part I (2)(e) (Confidentiality of data)
|
|
259
|
+
- Fix: Use crypto.randomBytes or crypto.randomUUID in Node, or the secrets module in Python, for tokens, codes and IDs people shouldn't guess.
|
|
260
|
+
- Note: Math.random and Python's random module are predictable; tokens made with them can be guessed (CWE-338).
|
|
261
|
+
- Page: https://lintsure.com/rules/crypto-weak-random-token
|
|
262
|
+
|
|
263
|
+
## crypto.weak-cipher
|
|
264
|
+
**Weak or broken encryption** · status when found: gap · risk: high · medium confidence (shown with --all)
|
|
265
|
+
|
|
266
|
+
- Controls: owasp-top10 A04:2025 (Cryptographic Failures); cra Annex I Part I (2)(e) (Confidentiality of data)
|
|
267
|
+
- Fix: Use AES-256-GCM or ChaCha20-Poly1305 with a random nonce, through a maintained library. Replace createCipher with createCipheriv.
|
|
268
|
+
- Note: DES, RC4 and ECB mode can be broken or leak patterns in the data; createCipher derives a weak key and IV (CWE-327).
|
|
269
|
+
- Page: https://lintsure.com/rules/crypto-weak-cipher
|
|
270
|
+
|
|
271
|
+
## jwt.unverified
|
|
272
|
+
**JWT accepted without checking its signature** · status when found: gap · risk: high · medium confidence (shown with --all)
|
|
273
|
+
|
|
274
|
+
- Controls: owasp-top10 A04:2025 (Cryptographic Failures); owasp-top10 A07:2025 (Authentication Failures); cra Annex I Part I (2)(d) (Protection from unauthorised access)
|
|
275
|
+
- Fix: Verify tokens with jwt.verify (Node) or jwt.decode with a key and an explicit algorithms list (Python). Never allow the 'none' algorithm.
|
|
276
|
+
- Note: Without signature checks anyone can write their own token and claim to be any user (CWE-347).
|
|
277
|
+
- Page: https://lintsure.com/rules/jwt-unverified
|
|
278
|
+
|
|
279
|
+
## cmd.shell-built
|
|
280
|
+
**Shell command built from strings** · status when found: gap · risk: high · medium confidence (shown with --all)
|
|
281
|
+
|
|
282
|
+
- Controls: owasp-top10 A05:2025 (Injection); cra Annex I Part I (2)(f) (Integrity of data and programs); cwe-top25 CWE-78 (OS Command Injection); cwe-top25 CWE-77 (Command Injection)
|
|
283
|
+
- Fix: Pass arguments as an array (execFile, spawn, subprocess.run([...])) instead of building a command string, and never use shell=True with outside input.
|
|
284
|
+
- Note: Characters like ; or $( ) in an inserted value run extra commands (OS command injection, CWE-78). Partial when the value may be fixed text from your own code.
|
|
285
|
+
- Page: https://lintsure.com/rules/cmd-shell-built
|
|
286
|
+
|
|
287
|
+
## code.eval
|
|
288
|
+
**Code run from a string** · status when found: gap · risk: high · medium confidence (shown with --all)
|
|
289
|
+
|
|
290
|
+
- Controls: owasp-top10 A05:2025 (Injection); cra Annex I Part I (2)(f) (Integrity of data and programs); cwe-top25 CWE-94 (Code Injection)
|
|
291
|
+
- Fix: Avoid eval and new Function. Parse data with JSON.parse or a real parser, and map names to functions with a lookup table.
|
|
292
|
+
- Note: If any part of the string comes from outside, it runs as your code (code injection, CWE-94). Partial when the input isn't visible on the line.
|
|
293
|
+
- Page: https://lintsure.com/rules/code-eval
|
|
294
|
+
|
|
295
|
+
## xss.raw-html
|
|
296
|
+
**HTML inserted without escaping** · status when found: partial · risk: medium · medium confidence (shown with --all)
|
|
297
|
+
|
|
298
|
+
- Controls: owasp-top10 A05:2025 (Injection); cra Annex I Part I (2)(f) (Integrity of data and programs); cwe-top25 CWE-79 (Cross-site Scripting)
|
|
299
|
+
- Fix: Set text with textContent, let your framework escape values, or sanitise with DOMPurify before inserting HTML.
|
|
300
|
+
- Note: If the HTML contains user input, attackers can run scripts in your users' browsers (cross-site scripting, CWE-79). Partial because fixed HTML from your own code is safe.
|
|
301
|
+
- Page: https://lintsure.com/rules/xss-raw-html
|
|
302
|
+
|
|
303
|
+
## template.user-string
|
|
304
|
+
**Template built from request data** · status when found: gap · risk: high
|
|
305
|
+
|
|
306
|
+
- Controls: owasp-top10 A05:2025 (Injection); cra Annex I Part I (2)(f) (Integrity of data and programs); cwe-top25 CWE-79 (Cross-site Scripting); cwe-top25 CWE-94 (Code Injection)
|
|
307
|
+
- Fix: Render a fixed template file and pass user values as variables, never as part of the template text.
|
|
308
|
+
- Note: Template syntax in user input runs on your server (server-side template injection, CWE-94).
|
|
309
|
+
- Page: https://lintsure.com/rules/template-user-string
|
|
310
|
+
|
|
311
|
+
## nosql.operator-input
|
|
312
|
+
**Database query object taken straight from the request** · status when found: partial · risk: high
|
|
313
|
+
|
|
314
|
+
- Controls: owasp-top10 A05:2025 (Injection); cra Annex I Part I (2)(f) (Integrity of data and programs); cwe-top25 CWE-20 (Improper Input Validation)
|
|
315
|
+
- Fix: Build the query from the specific fields you expect, and convert them to the expected types, so operators like $ne or $gt can't be injected.
|
|
316
|
+
- Note: A body such as {"password": {"$ne": null}} can match any record (NoSQL injection, CWE-943).
|
|
317
|
+
- Page: https://lintsure.com/rules/nosql-operator-input
|
|
318
|
+
|
|
319
|
+
## upload.unrestricted
|
|
320
|
+
**File upload with no type or size limit** · status when found: partial · risk: medium
|
|
321
|
+
|
|
322
|
+
- Controls: owasp-top10 A06:2025 (Insecure Design); cra Annex I Part I (2)(j) (Limited attack surface); cwe-top25 CWE-434 (Unrestricted Upload of File with Dangerous Type)
|
|
323
|
+
- Fix: Set limits.fileSize and a fileFilter that allows only the types you need, store uploads outside the web root, and give them new names.
|
|
324
|
+
- Note: Unlimited uploads let people fill your disk or upload files that later run or are served as pages (CWE-434).
|
|
325
|
+
- Page: https://lintsure.com/rules/upload-unrestricted
|
|
326
|
+
|
|
327
|
+
## mass-assignment
|
|
328
|
+
**Whole request body saved to a model** · status when found: partial · risk: medium · medium confidence (shown with --all)
|
|
329
|
+
|
|
330
|
+
- Controls: owasp-top10 A06:2025 (Insecure Design); owasp-top10 A08:2025 (Software or Data Integrity Failures); cra Annex I Part I (2)(f) (Integrity of data and programs); cwe-top25 CWE-20 (Improper Input Validation); cwe-top25 CWE-639 (Authorization Bypass Through User-Controlled Key)
|
|
331
|
+
- Fix: Copy only the fields a user may change, for example with a schema (zod, pydantic) that lists them.
|
|
332
|
+
- Note: Users can set fields you didn't expect, such as role or isAdmin (mass assignment, CWE-915).
|
|
333
|
+
- Page: https://lintsure.com/rules/mass-assignment
|
|
334
|
+
|
|
335
|
+
## auth.hardcoded-password
|
|
336
|
+
**Password written in the code** · status when found: partial · risk: high · medium confidence (shown with --all)
|
|
337
|
+
|
|
338
|
+
- Controls: owasp-top10 A07:2025 (Authentication Failures); cra Annex I Part I (2)(d) (Protection from unauthorised access)
|
|
339
|
+
- Fix: Load passwords from environment variables or a secret manager, and rotate any that were committed.
|
|
340
|
+
- Note: Anyone with the code has the password, and it can't be changed without a release (CWE-259, CWE-798).
|
|
341
|
+
- Page: https://lintsure.com/rules/auth-hardcoded-password
|
|
342
|
+
|
|
343
|
+
## jwt.no-expiry
|
|
344
|
+
**JWT signed without an expiry** · status when found: partial · risk: medium · medium confidence (shown with --all)
|
|
345
|
+
|
|
346
|
+
- Controls: owasp-top10 A07:2025 (Authentication Failures); cra Annex I Part I (2)(d) (Protection from unauthorised access)
|
|
347
|
+
- Fix: Add expiresIn (Node) or an exp claim (Python), and keep access tokens short-lived.
|
|
348
|
+
- Note: A stolen token without an expiry works forever (insufficient session expiration, CWE-613). Partial because the expiry may be set in a payload built elsewhere.
|
|
349
|
+
- Page: https://lintsure.com/rules/jwt-no-expiry
|
|
350
|
+
|
|
351
|
+
## deserialize.unsafe
|
|
352
|
+
**Unsafe deserialisation** · status when found: gap · risk: high · medium confidence (shown with --all)
|
|
353
|
+
|
|
354
|
+
- Controls: owasp-top10 A08:2025 (Software or Data Integrity Failures); cra Annex I Part I (2)(f) (Integrity of data and programs); cwe-top25 CWE-502 (Deserialization of Untrusted Data)
|
|
355
|
+
- Fix: Use JSON for data from outside. In Python use yaml.safe_load, never pickle or marshal on untrusted data.
|
|
356
|
+
- Note: Deserialising untrusted data with these functions can run attacker code on your server (CWE-502).
|
|
357
|
+
- Page: https://lintsure.com/rules/deserialize-unsafe
|
|
358
|
+
|
|
359
|
+
## html.script-no-sri
|
|
360
|
+
**Third-party script loaded without an integrity check** · status when found: partial · risk: low · medium confidence (shown with --all)
|
|
361
|
+
|
|
362
|
+
- Controls: owasp-top10 A08:2025 (Software or Data Integrity Failures); cra Annex I Part I (2)(f) (Integrity of data and programs)
|
|
363
|
+
- Fix: Add integrity and crossorigin attributes with the file's hash, or host the file yourself.
|
|
364
|
+
- Note: If the CDN or package is compromised, the changed script runs on your site (CWE-353, CWE-829).
|
|
365
|
+
- Page: https://lintsure.com/rules/html-script-no-sri
|
|
366
|
+
|
|
367
|
+
## cookie.trusted-role
|
|
368
|
+
**Permissions read from a cookie** · status when found: partial · risk: high
|
|
369
|
+
|
|
370
|
+
- Controls: owasp-top10 A08:2025 (Software or Data Integrity Failures); owasp-top10 A01:2025 (Broken Access Control); cra Annex I Part I (2)(d) (Protection from unauthorised access); cwe-top25 CWE-863 (Incorrect Authorization)
|
|
371
|
+
- Fix: Keep roles and permissions on the server, looked up from the authenticated user, not in a cookie the browser can change.
|
|
372
|
+
- Note: Users can edit their own cookies and give themselves admin rights (CWE-565).
|
|
373
|
+
- Page: https://lintsure.com/rules/cookie-trusted-role
|
|
374
|
+
|
|
375
|
+
## log.secret
|
|
376
|
+
**Secret or token written to logs** · status when found: gap · risk: high · medium confidence (shown with --all)
|
|
377
|
+
|
|
378
|
+
- Controls: owasp-top10 A09:2025 (Security Logging and Alerting Failures); cra Annex I Part I (2)(l) (Security logging); owasp-llm LLM02:2026 (Sensitive Information Disclosure); cwe-top25 CWE-200 (Exposure of Sensitive Information)
|
|
379
|
+
- Fix: Remove the value from the log call, or log only that it was present.
|
|
380
|
+
- Note: Logs are copied to many tools and people; a token in a log is a token anyone with log access can use (CWE-532).
|
|
381
|
+
- Page: https://lintsure.com/rules/log-secret
|
|
382
|
+
|
|
383
|
+
## log.injection
|
|
384
|
+
**Raw request data written to logs** · status when found: partial · risk: low · medium confidence (shown with --all)
|
|
385
|
+
|
|
386
|
+
- Controls: owasp-top10 A09:2025 (Security Logging and Alerting Failures); cra Annex I Part I (2)(l) (Security logging)
|
|
387
|
+
- Fix: Log specific, validated fields, and strip line breaks from user input before logging it.
|
|
388
|
+
- Note: Line breaks in user input can forge fake log entries and mislead an investigation (CWE-117).
|
|
389
|
+
- Page: https://lintsure.com/rules/log-injection
|
|
390
|
+
|
|
391
|
+
## error.empty-catch
|
|
392
|
+
**Error caught and ignored** · status when found: partial · risk: low · medium confidence (shown with --all)
|
|
393
|
+
|
|
394
|
+
- Controls: owasp-top10 A10:2025 (Mishandling of Exceptional Conditions)
|
|
395
|
+
- Fix: Handle the error, log it, or let it propagate. If ignoring it is deliberate, say why in a comment and catch only the specific error.
|
|
396
|
+
- Note: Silent failures hide attacks and bugs, and can leave the app running in a broken or unsafe state (CWE-390).
|
|
397
|
+
- Page: https://lintsure.com/rules/error-empty-catch
|
|
398
|
+
|
|
399
|
+
## error.stack-to-client
|
|
400
|
+
**Error details sent to the user** · status when found: gap · risk: medium
|
|
401
|
+
|
|
402
|
+
- Controls: owasp-top10 A10:2025 (Mishandling of Exceptional Conditions); owasp-top10 A02:2025 (Security Misconfiguration); cra Annex I Part I (2)(j) (Limited attack surface); cwe-top25 CWE-200 (Exposure of Sensitive Information)
|
|
403
|
+
- Fix: Log the full error on the server and send users a short, generic message with a reference id.
|
|
404
|
+
- Note: Stack traces show file paths, library versions and sometimes data, which helps attackers (CWE-209).
|
|
405
|
+
- Page: https://lintsure.com/rules/error-stack-to-client
|
|
406
|
+
|
|
407
|
+
## supabase.rls-disabled
|
|
408
|
+
**Database table without row level security** · status when found: partial · risk: high
|
|
409
|
+
|
|
410
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A01:2025 (Broken Access Control); cra Annex I Part I (2)(d) (Protection from unauthorised access); cwe-top25 CWE-862 (Missing Authorization)
|
|
411
|
+
- Fix: Add `alter table <name> enable row level security;` and a policy that limits each row to its owner, for example `using (auth.uid() = user_id)`.
|
|
412
|
+
- Note: In Supabase, a table without row level security can be read and changed by anyone with your public anon key, which ships in every browser. Lintsure looks across every SQL file in supabase/. Marked Partial: it may be switched on outside these files, for example in the dashboard.
|
|
413
|
+
- Seen in a real incident: CVE-2025-48757: missing row level security let anyone read or write the tables of apps generated with Lovable (https://www.cve.org/CVERecord?id=CVE-2025-48757)
|
|
414
|
+
- Page: https://lintsure.com/rules/supabase-rls-disabled
|
|
415
|
+
|
|
416
|
+
## supabase.policy-allows-all
|
|
417
|
+
**Database policy that lets everyone in** · status when found: partial · risk: high
|
|
418
|
+
|
|
419
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A01:2025 (Broken Access Control); cra Annex I Part I (2)(d) (Protection from unauthorised access); cwe-top25 CWE-284 (Improper Access Control)
|
|
420
|
+
- Fix: Limit the policy to the right people, for example `using (auth.uid() = user_id)`. Keep `using (true)` only for data that is meant to be public, such as published posts.
|
|
421
|
+
- Note: `using (true)` or `with check (true)` turns row level security on but lets every request through, so the table is as open as having no security at all. Marked Partial: public read access can be intended.
|
|
422
|
+
- Page: https://lintsure.com/rules/supabase-policy-allows-all
|
|
423
|
+
|
|
424
|
+
## supabase.function-no-auth
|
|
425
|
+
**Supabase Edge Function anyone can call** · status when found: partial · risk: high
|
|
426
|
+
|
|
427
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A01:2025 (Broken Access Control); cra Annex I Part I (2)(d) (Protection from unauthorised access); cwe-top25 CWE-306 (Missing Authentication for Critical Function)
|
|
428
|
+
- Fix: Keep verify_jwt on for this function, or check the caller yourself at the top of the handler: supabase.auth.getUser() for users, or the provider's signature for a webhook.
|
|
429
|
+
- Note: verify_jwt = false switches off Supabase's check that the caller is logged in, so anyone who knows the URL can call the function. Webhooks do this on purpose and verify a signature instead. Lintsure flags it only when the function's own code shows no check of its own. Marked Gap when the function also uses the service-role key or a paid AI API, because then anyone can read or change data, or spend your credits.
|
|
430
|
+
- Page: https://lintsure.com/rules/supabase-function-no-auth
|
|
431
|
+
|
|
432
|
+
## secret.public-env
|
|
433
|
+
**Secret in a variable the browser can see** · status when found: gap · risk: high
|
|
434
|
+
|
|
435
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A04:2025 (Cryptographic Failures); cra Annex I Part I (2)(e) (Confidentiality of data); owasp-llm LLM02:2026 (Sensitive Information Disclosure); cwe-top25 CWE-200 (Exposure of Sensitive Information)
|
|
436
|
+
- Fix: Rename the variable without the public prefix (NEXT_PUBLIC_, VITE_ and so on), use it only in server code, and rotate the key, since it has already been shipped to browsers.
|
|
437
|
+
- Note: Variables starting with NEXT_PUBLIC_, VITE_, EXPO_PUBLIC_ or REACT_APP_ are copied into the JavaScript every visitor downloads. Anyone can read a secret, service-role or private key put there. Keys that are public by design (Supabase anon, Stripe publishable, Firebase) are not flagged.
|
|
438
|
+
- Page: https://lintsure.com/rules/secret-public-env
|
|
439
|
+
|
|
440
|
+
## supabase.service-key-in-client
|
|
441
|
+
**Supabase service-role key used in browser code** · status when found: gap · risk: high
|
|
442
|
+
|
|
443
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A01:2025 (Broken Access Control); cra Annex I Part I (2)(d) (Protection from unauthorised access); cwe-top25 CWE-284 (Improper Access Control)
|
|
444
|
+
- Fix: Use the service-role key only in server code (API routes, server actions, edge functions). In browser code, use the anon key with row level security, and rotate the service-role key if it was ever shipped.
|
|
445
|
+
- Note: The service-role key skips every row level security rule. In a file marked "use client", or in browser-exposed env vars, it reaches every visitor, who can then read and change your whole database.
|
|
446
|
+
- Page: https://lintsure.com/rules/supabase-service-key-in-client
|
|
447
|
+
|
|
448
|
+
## build.sourcemaps-public
|
|
449
|
+
**Source maps published in production** · status when found: partial · risk: low
|
|
450
|
+
|
|
451
|
+
- Controls: owasp-top10 A02:2025 (Security Misconfiguration); cra Annex I Part I (2)(b) (Secure by default configuration); cwe-top25 CWE-200 (Exposure of Sensitive Information)
|
|
452
|
+
- Fix: Turn off browser source maps for production, or upload them privately to your error tracker instead of serving them.
|
|
453
|
+
- Note: Public source maps let anyone read your original front-end code, comments and file structure, which makes other weaknesses easier to find. Marked Partial: some teams publish them on purpose.
|
|
454
|
+
- Page: https://lintsure.com/rules/build-sourcemaps-public
|
|
455
|
+
|
|
456
|
+
## release.env-not-ignored
|
|
457
|
+
**Env files not kept out of git** · status when found: partial · risk: medium
|
|
458
|
+
|
|
459
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A02:2025 (Security Misconfiguration)
|
|
460
|
+
- Fix: Add .env and .env.* to .gitignore (keep !.env.example if you share one), then check `git ls-files` for env files already committed and rotate any secret keys they held.
|
|
461
|
+
- Note: The project keeps settings in .env files, but .gitignore has no line for them, so the next `git add .` can publish them. Marked Gap when a file holds a secret-looking value (a key, token or password without a public prefix such as VITE_ or NEXT_PUBLIC_). Partial when only public settings are in it. Example and template files (.env.example) don't count.
|
|
462
|
+
- When Partial, Lintsure can't see: Lintsure reads files, not git, so it can't tell whether the env file is already committed. Check with git ls-files.
|
|
463
|
+
- Page: https://lintsure.com/rules/release-env-not-ignored
|
|
464
|
+
|
|
465
|
+
## auth.no-rate-limit
|
|
466
|
+
**Login or password reset with no rate limit in sight** · status when found: partial · risk: medium · medium confidence (shown with --all)
|
|
467
|
+
|
|
468
|
+
- Controls: owasp-top10 A07:2025 (Authentication Failures)
|
|
469
|
+
- Fix: Limit how often one IP or account can try: a middleware limiter (for example @upstash/ratelimit, express-rate-limit or rate-limiter-flexible), or a firewall rule for this path. Lock or slow down after repeated failures.
|
|
470
|
+
- Note: Without a limit, anyone can try passwords, one-time codes or reset links as fast as they like (CWE-307). Partial: a firewall, an API gateway or your auth provider may already limit this outside the code.
|
|
471
|
+
- When Partial, Lintsure can't see: Lintsure looked for a rate limiter in this file, middleware and package.json. It can't see limits set in a firewall, gateway or hosting dashboard.
|
|
472
|
+
- Page: https://lintsure.com/rules/auth-no-rate-limit
|
|
473
|
+
|
|
474
|
+
## repo.no-security-policy
|
|
475
|
+
**No way for people to report a vulnerability** · status when found: partial · risk: medium
|
|
476
|
+
|
|
477
|
+
- Controls: cra Annex I Part II (5) (Coordinated vulnerability disclosure policy)
|
|
478
|
+
- Fix: Add a SECURITY.md to the repository root (or .github/) saying where to report a vulnerability, what to include and how soon you'll reply.
|
|
479
|
+
- Note: The Cyber Resilience Act expects a policy for coordinated vulnerability disclosure and a contact address for reports. Marked Partial: the policy may live on your website, or you scanned a subfolder of a larger repo.
|
|
480
|
+
- Page: https://lintsure.com/rules/repo-no-security-policy
|
|
481
|
+
|
|
482
|
+
## repo.no-sbom
|
|
483
|
+
**No software bill of materials (SBOM)** · status when found: partial · risk: low
|
|
484
|
+
|
|
485
|
+
- Controls: cra Annex I Part II (1) (Components identified, including an SBOM)
|
|
486
|
+
- Fix: Generate an SBOM in CycloneDX or SPDX format at release, for example with `npx @cyclonedx/cyclonedx-npm` or `syft`, and keep it with each release.
|
|
487
|
+
- Note: The Cyber Resilience Act asks makers to list the components in their product, at least the top-level dependencies, in a machine-readable SBOM. Marked Partial: it may be generated in CI or at release instead of kept in the repo; if so, accept this finding with that reason.
|
|
488
|
+
- Page: https://lintsure.com/rules/repo-no-sbom
|
|
489
|
+
|
|
490
|
+
## update.unverified-download
|
|
491
|
+
**Downloaded script run without a check** · status when found: partial · risk: medium
|
|
492
|
+
|
|
493
|
+
- Controls: cra Annex I Part II (7) (Updates distributed securely); owasp-top10 A03:2025 (Software Supply Chain Failures); owasp-top10 A08:2025 (Software or Data Integrity Failures)
|
|
494
|
+
- Fix: Download the file first, check it against a published checksum or signature, then run it. Or install from a package manager that verifies packages.
|
|
495
|
+
- Note: Piping `curl` or `wget` straight into a shell runs whatever the server sends at that moment, with no check that it is the file you expect. Marked Partial: well-known installers over HTTPS are a common, accepted risk.
|
|
496
|
+
- Page: https://lintsure.com/rules/update-unverified-download
|
|
497
|
+
|
|
498
|
+
## ci.write-all-permissions
|
|
499
|
+
**Workflow gives its token write access to everything** · status when found: gap · risk: medium
|
|
500
|
+
|
|
501
|
+
- Controls: cra Annex I Part II (7) (Updates distributed securely); owasp-top10 A03:2025 (Software Supply Chain Failures)
|
|
502
|
+
- Fix: Replace `permissions: write-all` with only what the job needs, for example `permissions: contents: read`, and grant write access per job where it's really used.
|
|
503
|
+
- Note: With write-all, any step that is compromised, including a third-party action, can push code, change releases or edit issues with the workflow's token.
|
|
504
|
+
- Page: https://lintsure.com/rules/ci-write-all-permissions
|
|
505
|
+
|
|
506
|
+
## ci.script-injection
|
|
507
|
+
**Text from a pull request or issue pasted into a workflow command** · status when found: gap · risk: high · medium confidence (shown with --all)
|
|
508
|
+
|
|
509
|
+
- Controls: cra Annex I Part II (7) (Updates distributed securely); owasp-top10 A03:2025 (Software Supply Chain Failures); owasp-top10 A08:2025 (Software or Data Integrity Failures)
|
|
510
|
+
- Fix: Pass the value through an environment variable instead, for example `env: TITLE: ${{ github.event.issue.title }}` and then use "$TITLE" in the script.
|
|
511
|
+
- Note: Anyone who opens an issue or pull request controls its title, body and branch name. Pasted into a `run:` step, that text becomes part of the shell command and can run anything with the workflow's secrets.
|
|
512
|
+
- Page: https://lintsure.com/rules/ci-script-injection
|
|
513
|
+
|
|
514
|
+
## repo.binary-committed
|
|
515
|
+
**Compiled program committed to the repository** · status when found: partial · risk: low
|
|
516
|
+
|
|
517
|
+
- Controls: cra Annex I Part II (1) (Components identified, including an SBOM)
|
|
518
|
+
- Fix: Remove the file and build it from source in CI, or download it at build time from a release with a checksum.
|
|
519
|
+
- Note: Nobody can review what a compiled file does, and it isn't covered by dependency checks. Marked Partial: some projects keep a reviewed binary on purpose.
|
|
520
|
+
- Page: https://lintsure.com/rules/repo-binary-committed
|
|
521
|
+
|
|
522
|
+
## repo.no-dependency-updates
|
|
523
|
+
**No automated dependency updates** · status when found: partial · risk: low
|
|
524
|
+
|
|
525
|
+
- Controls: cra Annex I Part II (2) (Vulnerabilities fixed without delay)
|
|
526
|
+
- Fix: Turn on Dependabot (add .github/dependabot.yml) or Renovate (renovate.json), so security fixes in your dependencies reach you as pull requests.
|
|
527
|
+
- Note: The Cyber Resilience Act expects vulnerabilities to be fixed without delay, including in the components you use. Marked Partial: updates may be handled another way, such as a hosted setting.
|
|
528
|
+
- Page: https://lintsure.com/rules/repo-no-dependency-updates
|
|
529
|
+
|
|
530
|
+
## llm.user-input-in-system-prompt
|
|
531
|
+
**User text placed inside the AI's system instructions** · status when found: partial · risk: high
|
|
532
|
+
|
|
533
|
+
- Controls: owasp-llm LLM01:2026 (Prompt Injection); owasp-llm LLM08:2026 (Hidden Context Exposure)
|
|
534
|
+
- Fix: Keep the system prompt fixed. Send what the user typed as a separate user message, and never put it inside the system instructions.
|
|
535
|
+
- Note: Text in the system prompt is treated as the app's own instructions. If user text goes there, a user can rewrite the rules the AI follows (prompt injection). Marked Partial: the inserted value may be safe text your app controls.
|
|
536
|
+
- Page: https://lintsure.com/rules/llm-user-input-in-system-prompt
|
|
537
|
+
|
|
538
|
+
## llm.output-to-sink
|
|
539
|
+
**AI output run as code, a command, a query or page HTML** · status when found: gap · risk: high
|
|
540
|
+
|
|
541
|
+
- Controls: owasp-llm LLM10:2026 (Improper Output Handling); cwe-top25 CWE-94 (Code Injection); cwe-top25 CWE-79 (Cross-site Scripting); cwe-top25 CWE-78 (OS Command Injection); cwe-top25 CWE-89 (SQL Injection)
|
|
542
|
+
- Fix: Treat model output like input from a stranger: validate it against what you expect, escape it for HTML, and never run it as code, a shell command or SQL.
|
|
543
|
+
- Note: A model's reply can be steered by anyone who can influence its input. Passing it straight to eval, a shell, a database query or innerHTML lets them run code or change data.
|
|
544
|
+
- Page: https://lintsure.com/rules/llm-output-to-sink
|
|
545
|
+
|
|
546
|
+
## llm.unbounded-agent-loop
|
|
547
|
+
**AI agent loop with no real step limit** · status when found: gap · risk: medium
|
|
548
|
+
|
|
549
|
+
- Controls: owasp-llm LLM06:2026 (Unbounded Consumption)
|
|
550
|
+
- Fix: Stop the loop after a small number of steps, for example stopWhen: stepCountIs(10), and set maxOutputTokens.
|
|
551
|
+
- Note: Each step is another paid model call and maybe another tool run. With no limit, one request, or one prompt-injected document, can keep the agent going until something times out.
|
|
552
|
+
- Page: https://lintsure.com/rules/llm-unbounded-agent-loop
|
|
553
|
+
|
|
554
|
+
## llm.client-controls-system
|
|
555
|
+
**The browser chooses the AI's system instructions** · status when found: gap · risk: high
|
|
556
|
+
|
|
557
|
+
- Controls: owasp-llm LLM01:2026 (Prompt Injection)
|
|
558
|
+
- Fix: Build the system prompt on the server. Take only the user's messages from the request, and ignore any system text it sends.
|
|
559
|
+
- Note: Whoever calls the route can rewrite the rules the AI follows, including what it may say or which tools it may use (prompt injection, OWASP LLM01).
|
|
560
|
+
- Page: https://lintsure.com/rules/llm-client-controls-system
|
|
561
|
+
|
|
562
|
+
## llm.no-output-limit
|
|
563
|
+
**AI call with no limit on how much it may generate** · status when found: partial · risk: low · medium confidence (shown with --all)
|
|
564
|
+
|
|
565
|
+
- Controls: owasp-llm LLM06:2026 (Unbounded Consumption); cwe-top25 CWE-770 (Allocation of Resources Without Limits or Throttling)
|
|
566
|
+
- Fix: Set a maximum output size on each call (max_tokens, maxTokens or max_output_tokens), and limit how often each user can call it.
|
|
567
|
+
- Note: Without a limit, one request can run up a large bill or tie up the service (unbounded consumption). Marked Partial: the limit may be set in a shared client or wrapper.
|
|
568
|
+
- Page: https://lintsure.com/rules/llm-no-output-limit
|
|
569
|
+
|
|
570
|
+
## mobile.token-in-plain-storage
|
|
571
|
+
**Token or password saved in the phone's plain storage** · status when found: gap · risk: high · medium confidence (shown with --all)
|
|
572
|
+
|
|
573
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A04:2025 (Cryptographic Failures)
|
|
574
|
+
- Fix: Store tokens and passwords in the platform's secure storage: expo-secure-store, react-native-keychain, the Android Keystore or the iOS Keychain.
|
|
575
|
+
- Note: AsyncStorage and SharedPreferences aren't encrypted. Other apps on a rooted phone, or a device backup, can read what's saved there.
|
|
576
|
+
- Page: https://lintsure.com/rules/mobile-token-in-plain-storage
|
|
577
|
+
|
|
578
|
+
## mobile.cleartext-traffic
|
|
579
|
+
**App allows unencrypted network traffic** · status when found: gap · risk: high · medium confidence (shown with --all)
|
|
580
|
+
|
|
581
|
+
- Controls: gdpr Art. 32 (Security of processing); owasp-top10 A04:2025 (Cryptographic Failures)
|
|
582
|
+
- Fix: Turn off cleartext traffic (usesCleartextTraffic false on Android, no NSAllowsArbitraryLoads on iOS) and use HTTPS everywhere. Allow exceptions per domain only if you must.
|
|
583
|
+
- Note: With cleartext allowed, anyone on the same Wi-Fi can read and change what the app sends and receives.
|
|
584
|
+
- Page: https://lintsure.com/rules/mobile-cleartext-traffic
|
|
585
|
+
|
|
586
|
+
## mobile.backup-allowed
|
|
587
|
+
**App data included in device backups** · status when found: partial · risk: low
|
|
588
|
+
|
|
589
|
+
- Controls: gdpr Art. 32 (Security of processing)
|
|
590
|
+
- Fix: Set android:allowBackup="false", or limit what's backed up with backup rules that leave out tokens and personal data.
|
|
591
|
+
- Note: Backups can be copied off the phone and read elsewhere. Marked Partial: backing up non-sensitive settings is fine.
|
|
592
|
+
- Page: https://lintsure.com/rules/mobile-backup-allowed
|
|
593
|
+
|
|
594
|
+
## mobile.webview-any-origin
|
|
595
|
+
**In-app browser that loads any website** · status when found: partial · risk: medium
|
|
596
|
+
|
|
597
|
+
- Controls: owasp-top10 A06:2025 (Insecure Design)
|
|
598
|
+
- Fix: List only the sites the WebView should open in originWhitelist, and open other links in the phone's browser.
|
|
599
|
+
- Note: A WebView that accepts any origin can be sent to a page that abuses the bridge between the web page and your app. Marked Partial: it may only ever load your own content.
|
|
600
|
+
- Page: https://lintsure.com/rules/mobile-webview-any-origin
|