@orionscanner/cli 0.1.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/LICENSE +21 -0
- package/README.md +248 -0
- package/assets/logo.png +0 -0
- package/bin/orion.js +48 -0
- package/docs/API_REFERENCE.md +211 -0
- package/docs/ARCHITECTURE.md +183 -0
- package/docs/CHANGELOG.md +112 -0
- package/docs/CONTRIBUTING.md +157 -0
- package/docs/ENGINE_CATALOG.md +87 -0
- package/docs/GETTING_STARTED.md +226 -0
- package/package.json +48 -0
- package/pyproject.toml +16 -0
- package/src/orion/__init__.py +0 -0
- package/src/orion/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/orion/engine/__init__.py +17 -0
- package/src/orion/engine/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/orion/engine/__pycache__/config.cpython-313.pyc +0 -0
- package/src/orion/engine/__pycache__/core.cpython-313.pyc +0 -0
- package/src/orion/engine/__pycache__/ir.cpython-313.pyc +0 -0
- package/src/orion/engine/__pycache__/languages.cpython-313.pyc +0 -0
- package/src/orion/engine/__pycache__/registry.cpython-313.pyc +0 -0
- package/src/orion/engine/__pycache__/results.cpython-313.pyc +0 -0
- package/src/orion/engine/__pycache__/runner.cpython-313.pyc +0 -0
- package/src/orion/engine/api_security/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/api_security/engine.py +125 -0
- package/src/orion/engine/architecture/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/architecture/engine.py +463 -0
- package/src/orion/engine/authorization/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/authorization/engine.py +337 -0
- package/src/orion/engine/callgraph/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/callgraph/engine.py +236 -0
- package/src/orion/engine/cfg/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/cfg/engine.py +509 -0
- package/src/orion/engine/chaos/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/chaos/engine.py +268 -0
- package/src/orion/engine/chaos_config/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/chaos_config/engine.py +322 -0
- package/src/orion/engine/complexity/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/complexity/engine.py +144 -0
- package/src/orion/engine/compliance/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/compliance/engine.py +325 -0
- package/src/orion/engine/config.py +41 -0
- package/src/orion/engine/config_engine/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/config_engine/engine.py +364 -0
- package/src/orion/engine/config_validation/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/config_validation/engine.py +313 -0
- package/src/orion/engine/container/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/container/engine.py +546 -0
- package/src/orion/engine/contract_probe/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/contract_probe/engine.py +316 -0
- package/src/orion/engine/core.py +75 -0
- package/src/orion/engine/crypto_guard/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/crypto_guard/engine.py +134 -0
- package/src/orion/engine/data_residency/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/data_residency/engine.py +238 -0
- package/src/orion/engine/dataflow/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/dataflow/engine.py +398 -0
- package/src/orion/engine/dead_import/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/dead_import/engine.py +293 -0
- package/src/orion/engine/deps/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/deps/engine.py +244 -0
- package/src/orion/engine/dispatcher.py +350 -0
- package/src/orion/engine/docs/AUDIT_PROMPT.md +1248 -0
- package/src/orion/engine/duplication/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/duplication/engine.py +120 -0
- package/src/orion/engine/error_handling/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/error_handling/engine.py +256 -0
- package/src/orion/engine/fp_learn/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/fp_learn/engine.py +248 -0
- package/src/orion/engine/hunter/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/hunter/engine.py +324 -0
- package/src/orion/engine/iac_security/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/iac_security/engine.py +218 -0
- package/src/orion/engine/ir.py +22 -0
- package/src/orion/engine/languages.py +454 -0
- package/src/orion/engine/license/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/license/engine.py +172 -0
- package/src/orion/engine/lint/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/lint/engine.py +558 -0
- package/src/orion/engine/llm_security/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/llm_security/engine.py +125 -0
- package/src/orion/engine/logging_c/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/logging_c/engine.py +164 -0
- package/src/orion/engine/noise/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/noise/engine.py +140 -0
- package/src/orion/engine/orphan/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/orphan/engine.py +244 -0
- package/src/orion/engine/perf_guard/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/perf_guard/engine.py +345 -0
- package/src/orion/engine/prompt_security/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/prompt_security/detectors/__init__.py +4 -0
- package/src/orion/engine/prompt_security/engine.py +170 -0
- package/src/orion/engine/provenance/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/provenance/engine.py +242 -0
- package/src/orion/engine/registry.py +55 -0
- package/src/orion/engine/regression/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/regression/engine.py +213 -0
- package/src/orion/engine/results.py +21 -0
- package/src/orion/engine/runner.py +1310 -0
- package/src/orion/engine/sandbox_escape/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/sandbox_escape/engine.py +284 -0
- package/src/orion/engine/sast/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/sast/engine.py +217 -0
- package/src/orion/engine/sast/patterns/__init__.py +513 -0
- package/src/orion/engine/sast/patterns/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/orion/engine/secrets/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/secrets/engine.py +77 -0
- package/src/orion/engine/secrets/patterns/__init__.py +74 -0
- package/src/orion/engine/secrets/patterns/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/orion/engine/sensitive_data/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/sensitive_data/engine.py +143 -0
- package/src/orion/engine/state/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/state/engine.py +218 -0
- package/src/orion/engine/supply_chain_sbom/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/supply_chain_sbom/engine.py +290 -0
- package/src/orion/engine/symbol/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/symbol/engine.py +463 -0
- package/src/orion/engine/taint/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/taint/engine.py +464 -0
- package/src/orion/engine/test_coverage/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/test_coverage/engine.py +445 -0
- package/src/orion/engine/threat_model/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/threat_model/engine.py +126 -0
- package/src/orion/engine/wiring_trace/__pycache__/engine.cpython-313.pyc +0 -0
- package/src/orion/engine/wiring_trace/engine.py +200 -0
- package/src/orion_engine.egg-info/PKG-INFO +7 -0
- package/src/orion_engine.egg-info/SOURCES.txt +65 -0
- package/src/orion_engine.egg-info/dependency_links.txt +1 -0
- package/src/orion_engine.egg-info/entry_points.txt +2 -0
- package/src/orion_engine.egg-info/top_level.txt +1 -0
|
@@ -0,0 +1,1248 @@
|
|
|
1
|
+
# Orion Engine — Autonomous Ultra-Modern Audit Intelligence Build Specification
|
|
2
|
+
|
|
3
|
+
## Mission
|
|
4
|
+
|
|
5
|
+
Transform **Orion Engine** into a production-grade, deeply contextual, future-proof code auditing and security analysis platform.
|
|
6
|
+
|
|
7
|
+
Orion must not behave like a collection of regex scanners.
|
|
8
|
+
|
|
9
|
+
It must behave like a **software reasoning system**:
|
|
10
|
+
|
|
11
|
+
* understand the structure of a repository
|
|
12
|
+
* understand relationships between components
|
|
13
|
+
* trace data and control flow
|
|
14
|
+
* reason about security boundaries
|
|
15
|
+
* correlate evidence across analyzers
|
|
16
|
+
* distinguish exploitable behavior from merely suspicious syntax
|
|
17
|
+
* minimize false positives
|
|
18
|
+
* explain exactly why a finding exists
|
|
19
|
+
* identify uncertainty rather than inventing conclusions
|
|
20
|
+
* remain deterministic and reproducible
|
|
21
|
+
* continuously improve through regression fixtures and evidence-driven heuristics
|
|
22
|
+
|
|
23
|
+
The target is **LLM-level contextual usefulness implemented primarily through deterministic program analysis, graph reasoning, symbolic reasoning, heuristics, and evidence correlation**.
|
|
24
|
+
|
|
25
|
+
Do not claim that Orion is equivalent to an LLM. Instead, build an architecture capable of achieving comparable contextual depth for code-audit tasks without requiring an LLM for its core correctness.
|
|
26
|
+
|
|
27
|
+
---
|
|
28
|
+
|
|
29
|
+
# 1. Non-Negotiable Principles
|
|
30
|
+
|
|
31
|
+
## 1.1 No fake implementations
|
|
32
|
+
|
|
33
|
+
Every registered engine must contain real analysis logic.
|
|
34
|
+
|
|
35
|
+
Never use:
|
|
36
|
+
|
|
37
|
+
```python
|
|
38
|
+
return EngineResult(findings=[])
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
as a placeholder.
|
|
42
|
+
|
|
43
|
+
Never mark an engine as successful when it did not actually analyze its input.
|
|
44
|
+
|
|
45
|
+
A failed engine must produce an explicit failure state.
|
|
46
|
+
|
|
47
|
+
These states must remain distinct:
|
|
48
|
+
|
|
49
|
+
```text
|
|
50
|
+
SUCCESS_WITH_FINDINGS
|
|
51
|
+
SUCCESS_WITH_NO_FINDINGS
|
|
52
|
+
PARTIAL
|
|
53
|
+
UNAVAILABLE
|
|
54
|
+
FAILED
|
|
55
|
+
TIMEOUT
|
|
56
|
+
RESOURCE_LIMIT
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
---
|
|
60
|
+
|
|
61
|
+
# 2. Build a Shared Intelligence Substrate
|
|
62
|
+
|
|
63
|
+
Do not implement the 38 engines as isolated scanners.
|
|
64
|
+
|
|
65
|
+
Create a shared Orion analysis substrate.
|
|
66
|
+
|
|
67
|
+
Conceptually:
|
|
68
|
+
|
|
69
|
+
```text
|
|
70
|
+
Repository
|
|
71
|
+
↓
|
|
72
|
+
File Discovery
|
|
73
|
+
↓
|
|
74
|
+
Language Detection
|
|
75
|
+
↓
|
|
76
|
+
Parsing
|
|
77
|
+
↓
|
|
78
|
+
Canonical Orion IR
|
|
79
|
+
↓
|
|
80
|
+
Symbol Graph
|
|
81
|
+
↓
|
|
82
|
+
Call Graph
|
|
83
|
+
↓
|
|
84
|
+
Control Flow Graph
|
|
85
|
+
↓
|
|
86
|
+
Data Flow Graph
|
|
87
|
+
↓
|
|
88
|
+
Dependency Graph
|
|
89
|
+
↓
|
|
90
|
+
Configuration Graph
|
|
91
|
+
↓
|
|
92
|
+
Authorization / Trust-Boundary Graph
|
|
93
|
+
↓
|
|
94
|
+
Evidence Graph
|
|
95
|
+
↓
|
|
96
|
+
38 Engines
|
|
97
|
+
↓
|
|
98
|
+
Cross-Engine Correlation
|
|
99
|
+
↓
|
|
100
|
+
Finding Intelligence
|
|
101
|
+
↓
|
|
102
|
+
Deduplication / Confidence
|
|
103
|
+
↓
|
|
104
|
+
Audit Findings
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
The shared representation is more important than individual rule count.
|
|
108
|
+
|
|
109
|
+
---
|
|
110
|
+
|
|
111
|
+
# 3. Orion IR
|
|
112
|
+
|
|
113
|
+
Design a versioned canonical IR capable of representing:
|
|
114
|
+
|
|
115
|
+
* files
|
|
116
|
+
* modules
|
|
117
|
+
* packages
|
|
118
|
+
* functions
|
|
119
|
+
* methods
|
|
120
|
+
* classes
|
|
121
|
+
* variables
|
|
122
|
+
* constants
|
|
123
|
+
* imports
|
|
124
|
+
* exports
|
|
125
|
+
* decorators
|
|
126
|
+
* annotations
|
|
127
|
+
* types
|
|
128
|
+
* calls
|
|
129
|
+
* arguments
|
|
130
|
+
* returns
|
|
131
|
+
* branches
|
|
132
|
+
* loops
|
|
133
|
+
* exceptions
|
|
134
|
+
* assignments
|
|
135
|
+
* expressions
|
|
136
|
+
* control-flow edges
|
|
137
|
+
* data-flow edges
|
|
138
|
+
* taint propagation
|
|
139
|
+
* sinks
|
|
140
|
+
* sources
|
|
141
|
+
* sanitizers
|
|
142
|
+
* authentication boundaries
|
|
143
|
+
* authorization boundaries
|
|
144
|
+
* network boundaries
|
|
145
|
+
* process boundaries
|
|
146
|
+
* filesystem boundaries
|
|
147
|
+
* serialization boundaries
|
|
148
|
+
* database operations
|
|
149
|
+
* external services
|
|
150
|
+
* configuration
|
|
151
|
+
* environment variables
|
|
152
|
+
* dependencies
|
|
153
|
+
* generated code
|
|
154
|
+
* test code
|
|
155
|
+
* build artifacts
|
|
156
|
+
|
|
157
|
+
Every node and edge must preserve source provenance:
|
|
158
|
+
|
|
159
|
+
```text
|
|
160
|
+
repository
|
|
161
|
+
file
|
|
162
|
+
line
|
|
163
|
+
column
|
|
164
|
+
AST node
|
|
165
|
+
symbol
|
|
166
|
+
engine
|
|
167
|
+
analysis pass
|
|
168
|
+
```
|
|
169
|
+
|
|
170
|
+
IR must be versioned so future analyzers can evolve without breaking old findings.
|
|
171
|
+
|
|
172
|
+
---
|
|
173
|
+
|
|
174
|
+
# 4. Evidence Graph
|
|
175
|
+
|
|
176
|
+
Create a first-class Evidence Graph.
|
|
177
|
+
|
|
178
|
+
Every engine should be able to contribute evidence.
|
|
179
|
+
|
|
180
|
+
Example:
|
|
181
|
+
|
|
182
|
+
```text
|
|
183
|
+
HTTP_PARAMETER
|
|
184
|
+
│
|
|
185
|
+
↓
|
|
186
|
+
request.args["id"]
|
|
187
|
+
│
|
|
188
|
+
↓
|
|
189
|
+
Function: get_user()
|
|
190
|
+
│
|
|
191
|
+
↓
|
|
192
|
+
Function: query_user()
|
|
193
|
+
│
|
|
194
|
+
↓
|
|
195
|
+
string concatenation
|
|
196
|
+
│
|
|
197
|
+
↓
|
|
198
|
+
SQL_QUERY
|
|
199
|
+
│
|
|
200
|
+
↓
|
|
201
|
+
database.execute()
|
|
202
|
+
```
|
|
203
|
+
|
|
204
|
+
Evidence must be structured.
|
|
205
|
+
|
|
206
|
+
Each evidence item should contain:
|
|
207
|
+
|
|
208
|
+
```text
|
|
209
|
+
type
|
|
210
|
+
source
|
|
211
|
+
location
|
|
212
|
+
confidence
|
|
213
|
+
provenance
|
|
214
|
+
relationship
|
|
215
|
+
supporting_engine
|
|
216
|
+
```
|
|
217
|
+
|
|
218
|
+
Never rely solely on textual messages.
|
|
219
|
+
|
|
220
|
+
---
|
|
221
|
+
|
|
222
|
+
# 5. Evidence-Based Findings
|
|
223
|
+
|
|
224
|
+
A finding must contain:
|
|
225
|
+
|
|
226
|
+
```text
|
|
227
|
+
finding_id
|
|
228
|
+
title
|
|
229
|
+
category
|
|
230
|
+
severity
|
|
231
|
+
confidence
|
|
232
|
+
certainty
|
|
233
|
+
description
|
|
234
|
+
impact
|
|
235
|
+
source_location
|
|
236
|
+
sink_location
|
|
237
|
+
attack_path
|
|
238
|
+
evidence
|
|
239
|
+
related_findings
|
|
240
|
+
related_engines
|
|
241
|
+
remediation
|
|
242
|
+
references
|
|
243
|
+
limitations
|
|
244
|
+
```
|
|
245
|
+
|
|
246
|
+
The distinction between **severity** and **confidence** is mandatory.
|
|
247
|
+
|
|
248
|
+
Example:
|
|
249
|
+
|
|
250
|
+
```text
|
|
251
|
+
severity: CRITICAL
|
|
252
|
+
confidence: 0.98
|
|
253
|
+
```
|
|
254
|
+
|
|
255
|
+
means:
|
|
256
|
+
|
|
257
|
+
> If true, this is extremely dangerous, and Orion has very strong evidence that it is real.
|
|
258
|
+
|
|
259
|
+
Whereas:
|
|
260
|
+
|
|
261
|
+
```text
|
|
262
|
+
severity: CRITICAL
|
|
263
|
+
confidence: 0.42
|
|
264
|
+
```
|
|
265
|
+
|
|
266
|
+
means:
|
|
267
|
+
|
|
268
|
+
> Potentially critical, but insufficient evidence.
|
|
269
|
+
|
|
270
|
+
Do not report these identically.
|
|
271
|
+
|
|
272
|
+
---
|
|
273
|
+
|
|
274
|
+
# 6. Confidence Engine
|
|
275
|
+
|
|
276
|
+
Build a dedicated confidence/evidence scoring system.
|
|
277
|
+
|
|
278
|
+
Confidence must increase when independent evidence agrees.
|
|
279
|
+
|
|
280
|
+
Example:
|
|
281
|
+
|
|
282
|
+
```text
|
|
283
|
+
SAST pattern +0.20
|
|
284
|
+
attacker-controlled source +0.25
|
|
285
|
+
valid data-flow path +0.20
|
|
286
|
+
reachable sink +0.15
|
|
287
|
+
missing sanitizer +0.10
|
|
288
|
+
missing authorization +0.05
|
|
289
|
+
cross-engine confirmation +0.10
|
|
290
|
+
```
|
|
291
|
+
|
|
292
|
+
Confidence must decrease for:
|
|
293
|
+
|
|
294
|
+
```text
|
|
295
|
+
sanitization
|
|
296
|
+
validation
|
|
297
|
+
constant input
|
|
298
|
+
unreachable code
|
|
299
|
+
test-only code
|
|
300
|
+
dead code
|
|
301
|
+
known-safe wrapper
|
|
302
|
+
trusted source
|
|
303
|
+
framework guarantee
|
|
304
|
+
false-positive suppression
|
|
305
|
+
```
|
|
306
|
+
|
|
307
|
+
Do not use arbitrary scores blindly.
|
|
308
|
+
|
|
309
|
+
Make scoring explainable and configurable.
|
|
310
|
+
|
|
311
|
+
---
|
|
312
|
+
|
|
313
|
+
# 7. Cross-Engine Reasoning
|
|
314
|
+
|
|
315
|
+
The engines must cooperate.
|
|
316
|
+
|
|
317
|
+
For example:
|
|
318
|
+
|
|
319
|
+
```text
|
|
320
|
+
SAST
|
|
321
|
+
+
|
|
322
|
+
Taint
|
|
323
|
+
+
|
|
324
|
+
Callgraph
|
|
325
|
+
+
|
|
326
|
+
Dataflow
|
|
327
|
+
+
|
|
328
|
+
Authorization
|
|
329
|
+
```
|
|
330
|
+
|
|
331
|
+
should be capable of producing one high-confidence security finding.
|
|
332
|
+
|
|
333
|
+
Do not produce five duplicate findings for one root cause.
|
|
334
|
+
|
|
335
|
+
Create a correlation layer:
|
|
336
|
+
|
|
337
|
+
```text
|
|
338
|
+
Finding A
|
|
339
|
+
Finding B
|
|
340
|
+
Finding C
|
|
341
|
+
Finding D
|
|
342
|
+
↓
|
|
343
|
+
Root Cause Analysis
|
|
344
|
+
↓
|
|
345
|
+
Unified Finding
|
|
346
|
+
```
|
|
347
|
+
|
|
348
|
+
Maintain all supporting evidence underneath the unified finding.
|
|
349
|
+
|
|
350
|
+
---
|
|
351
|
+
|
|
352
|
+
# 8. The 38 Engines
|
|
353
|
+
|
|
354
|
+
Implement all 38 as real analyzers:
|
|
355
|
+
|
|
356
|
+
1. SAST
|
|
357
|
+
2. Secrets
|
|
358
|
+
3. Dependencies
|
|
359
|
+
4. Taint
|
|
360
|
+
5. Callgraph
|
|
361
|
+
6. CFG
|
|
362
|
+
7. Symbol
|
|
363
|
+
8. Dataflow
|
|
364
|
+
9. Authorization
|
|
365
|
+
10. Orphan
|
|
366
|
+
11. Prompt Security
|
|
367
|
+
12. Contract Probe
|
|
368
|
+
13. Wiring Trace
|
|
369
|
+
14. State
|
|
370
|
+
15. License
|
|
371
|
+
16. Complexity
|
|
372
|
+
17. Duplication
|
|
373
|
+
18. Dead Import
|
|
374
|
+
19. Error Handling
|
|
375
|
+
20. Logging
|
|
376
|
+
21. Config Engine
|
|
377
|
+
22. Chaos
|
|
378
|
+
23. Chaos Config
|
|
379
|
+
24. Regression
|
|
380
|
+
25. Performance Guard
|
|
381
|
+
26. Data Residency
|
|
382
|
+
27. Noise
|
|
383
|
+
28. Supply Chain / SBOM
|
|
384
|
+
29. Hunter
|
|
385
|
+
30. Lint
|
|
386
|
+
31. Architecture
|
|
387
|
+
32. Test Coverage
|
|
388
|
+
33. Container
|
|
389
|
+
34. Compliance
|
|
390
|
+
35. Provenance
|
|
391
|
+
36. False-Positive Learning
|
|
392
|
+
37. Sandbox Escape
|
|
393
|
+
38. Config Validation
|
|
394
|
+
|
|
395
|
+
Every engine must implement the same Orion contract.
|
|
396
|
+
|
|
397
|
+
---
|
|
398
|
+
|
|
399
|
+
# 9. SAST Must Be Semantic, Not Regex-Only
|
|
400
|
+
|
|
401
|
+
SAST may use patterns, but patterns are only candidates.
|
|
402
|
+
|
|
403
|
+
Implement layered analysis:
|
|
404
|
+
|
|
405
|
+
```text
|
|
406
|
+
Pattern Candidate
|
|
407
|
+
↓
|
|
408
|
+
AST Context
|
|
409
|
+
↓
|
|
410
|
+
Type Context
|
|
411
|
+
↓
|
|
412
|
+
Symbol Resolution
|
|
413
|
+
↓
|
|
414
|
+
Data Flow
|
|
415
|
+
↓
|
|
416
|
+
Control Flow
|
|
417
|
+
↓
|
|
418
|
+
Reachability
|
|
419
|
+
↓
|
|
420
|
+
Sanitizer Analysis
|
|
421
|
+
↓
|
|
422
|
+
Framework Knowledge
|
|
423
|
+
↓
|
|
424
|
+
Confidence
|
|
425
|
+
```
|
|
426
|
+
|
|
427
|
+
Example:
|
|
428
|
+
|
|
429
|
+
Do not report every string concatenation as SQL injection.
|
|
430
|
+
|
|
431
|
+
Determine:
|
|
432
|
+
|
|
433
|
+
```text
|
|
434
|
+
Is the value attacker controlled?
|
|
435
|
+
Is it actually used as SQL?
|
|
436
|
+
Is the query dynamically constructed?
|
|
437
|
+
Is a safe parameterization API used?
|
|
438
|
+
Is the code reachable?
|
|
439
|
+
Is there a sanitizer?
|
|
440
|
+
Is this test/mock code?
|
|
441
|
+
```
|
|
442
|
+
|
|
443
|
+
Only then create a strong finding.
|
|
444
|
+
|
|
445
|
+
---
|
|
446
|
+
|
|
447
|
+
# 10. Taint Analysis
|
|
448
|
+
|
|
449
|
+
Support:
|
|
450
|
+
|
|
451
|
+
* intra-procedural propagation
|
|
452
|
+
* inter-procedural propagation
|
|
453
|
+
* cross-module propagation
|
|
454
|
+
* object/property propagation
|
|
455
|
+
* container propagation
|
|
456
|
+
* return-value propagation
|
|
457
|
+
* argument propagation
|
|
458
|
+
* framework sources
|
|
459
|
+
* framework sinks
|
|
460
|
+
* sanitizers
|
|
461
|
+
* validators
|
|
462
|
+
* trust boundaries
|
|
463
|
+
|
|
464
|
+
Support configurable taint policies.
|
|
465
|
+
|
|
466
|
+
Never silently swallow analysis exceptions.
|
|
467
|
+
|
|
468
|
+
---
|
|
469
|
+
|
|
470
|
+
# 11. Callgraph
|
|
471
|
+
|
|
472
|
+
Build multiple resolution strategies:
|
|
473
|
+
|
|
474
|
+
```text
|
|
475
|
+
exact resolution
|
|
476
|
+
type-based resolution
|
|
477
|
+
inheritance resolution
|
|
478
|
+
dynamic dispatch approximation
|
|
479
|
+
import resolution
|
|
480
|
+
framework routing
|
|
481
|
+
reflection heuristics
|
|
482
|
+
```
|
|
483
|
+
|
|
484
|
+
Represent uncertainty explicitly.
|
|
485
|
+
|
|
486
|
+
Never pretend an approximate call edge is certain.
|
|
487
|
+
|
|
488
|
+
---
|
|
489
|
+
|
|
490
|
+
# 12. CFG + Dataflow
|
|
491
|
+
|
|
492
|
+
Construct real control/data-flow graphs.
|
|
493
|
+
|
|
494
|
+
Track:
|
|
495
|
+
|
|
496
|
+
```text
|
|
497
|
+
definitions
|
|
498
|
+
uses
|
|
499
|
+
assignments
|
|
500
|
+
branches
|
|
501
|
+
loops
|
|
502
|
+
returns
|
|
503
|
+
exceptions
|
|
504
|
+
conditions
|
|
505
|
+
aliases
|
|
506
|
+
mutations
|
|
507
|
+
```
|
|
508
|
+
|
|
509
|
+
Support path-sensitive analysis where practical.
|
|
510
|
+
|
|
511
|
+
Use bounded exploration to prevent path explosion.
|
|
512
|
+
|
|
513
|
+
---
|
|
514
|
+
|
|
515
|
+
# 13. Authorization Intelligence
|
|
516
|
+
|
|
517
|
+
Model:
|
|
518
|
+
|
|
519
|
+
```text
|
|
520
|
+
identity
|
|
521
|
+
roles
|
|
522
|
+
permissions
|
|
523
|
+
resources
|
|
524
|
+
actions
|
|
525
|
+
routes
|
|
526
|
+
middleware
|
|
527
|
+
guards
|
|
528
|
+
policies
|
|
529
|
+
ownership checks
|
|
530
|
+
tenant boundaries
|
|
531
|
+
```
|
|
532
|
+
|
|
533
|
+
Look for:
|
|
534
|
+
|
|
535
|
+
* missing authorization
|
|
536
|
+
* inconsistent authorization
|
|
537
|
+
* privilege escalation
|
|
538
|
+
* IDOR/BOLA
|
|
539
|
+
* route protection gaps
|
|
540
|
+
* tenant isolation failures
|
|
541
|
+
|
|
542
|
+
Do not flag an endpoint merely because authorization isn't visible locally.
|
|
543
|
+
|
|
544
|
+
Search the actual execution path and framework middleware.
|
|
545
|
+
|
|
546
|
+
---
|
|
547
|
+
|
|
548
|
+
# 14. Secrets Engine
|
|
549
|
+
|
|
550
|
+
Do not rely solely on regex.
|
|
551
|
+
|
|
552
|
+
Combine:
|
|
553
|
+
|
|
554
|
+
```text
|
|
555
|
+
pattern detection
|
|
556
|
+
entropy
|
|
557
|
+
context
|
|
558
|
+
known prefixes
|
|
559
|
+
assignment semantics
|
|
560
|
+
variable names
|
|
561
|
+
provider formats
|
|
562
|
+
test-fixture detection
|
|
563
|
+
documentation detection
|
|
564
|
+
allowlists
|
|
565
|
+
```
|
|
566
|
+
|
|
567
|
+
Distinguish:
|
|
568
|
+
|
|
569
|
+
```text
|
|
570
|
+
real credential
|
|
571
|
+
example credential
|
|
572
|
+
placeholder
|
|
573
|
+
test fixture
|
|
574
|
+
documentation
|
|
575
|
+
revoked/invalid-looking credential
|
|
576
|
+
```
|
|
577
|
+
|
|
578
|
+
Avoid exposing detected secret values in reports.
|
|
579
|
+
|
|
580
|
+
Immediately redact sensitive material.
|
|
581
|
+
|
|
582
|
+
---
|
|
583
|
+
|
|
584
|
+
# 15. Dependency Intelligence
|
|
585
|
+
|
|
586
|
+
Support:
|
|
587
|
+
|
|
588
|
+
* lockfiles
|
|
589
|
+
* manifests
|
|
590
|
+
* transitive dependencies
|
|
591
|
+
* version constraints
|
|
592
|
+
* vulnerability matching
|
|
593
|
+
* dependency reachability
|
|
594
|
+
* runtime usage
|
|
595
|
+
* abandoned packages
|
|
596
|
+
* suspicious packages
|
|
597
|
+
* license issues
|
|
598
|
+
* supply-chain anomalies
|
|
599
|
+
|
|
600
|
+
Do not report a vulnerable dependency with identical severity whether it is:
|
|
601
|
+
|
|
602
|
+
```text
|
|
603
|
+
installed but unreachable
|
|
604
|
+
```
|
|
605
|
+
|
|
606
|
+
or:
|
|
607
|
+
|
|
608
|
+
```text
|
|
609
|
+
directly imported by internet-facing code
|
|
610
|
+
```
|
|
611
|
+
|
|
612
|
+
Reachability should influence confidence and prioritization.
|
|
613
|
+
|
|
614
|
+
---
|
|
615
|
+
|
|
616
|
+
# 16. Prompt Security
|
|
617
|
+
|
|
618
|
+
Analyze modern AI applications.
|
|
619
|
+
|
|
620
|
+
Detect:
|
|
621
|
+
|
|
622
|
+
* prompt injection
|
|
623
|
+
* indirect prompt injection
|
|
624
|
+
* unsafe tool exposure
|
|
625
|
+
* privilege confusion
|
|
626
|
+
* untrusted content entering prompts
|
|
627
|
+
* secret exposure
|
|
628
|
+
* unsafe tool arguments
|
|
629
|
+
* missing authorization around tools
|
|
630
|
+
* cross-agent trust violations
|
|
631
|
+
* memory poisoning
|
|
632
|
+
* retrieval poisoning
|
|
633
|
+
* instruction/data confusion
|
|
634
|
+
|
|
635
|
+
Understand the relationship between:
|
|
636
|
+
|
|
637
|
+
```text
|
|
638
|
+
user
|
|
639
|
+
retrieval
|
|
640
|
+
system prompt
|
|
641
|
+
developer instruction
|
|
642
|
+
tool
|
|
643
|
+
agent
|
|
644
|
+
memory
|
|
645
|
+
external content
|
|
646
|
+
```
|
|
647
|
+
|
|
648
|
+
Do not flag ordinary prompt text merely because it contains security terminology.
|
|
649
|
+
|
|
650
|
+
---
|
|
651
|
+
|
|
652
|
+
# 17. Contract Probe
|
|
653
|
+
|
|
654
|
+
Understand declared contracts:
|
|
655
|
+
|
|
656
|
+
```text
|
|
657
|
+
OpenAPI
|
|
658
|
+
JSON Schema
|
|
659
|
+
type hints
|
|
660
|
+
dataclasses
|
|
661
|
+
protobuf
|
|
662
|
+
GraphQL
|
|
663
|
+
function signatures
|
|
664
|
+
configuration schemas
|
|
665
|
+
```
|
|
666
|
+
|
|
667
|
+
Compare:
|
|
668
|
+
|
|
669
|
+
```text
|
|
670
|
+
declared behavior
|
|
671
|
+
vs
|
|
672
|
+
actual implementation
|
|
673
|
+
```
|
|
674
|
+
|
|
675
|
+
Detect mismatches with evidence.
|
|
676
|
+
|
|
677
|
+
---
|
|
678
|
+
|
|
679
|
+
# 18. Wiring Trace
|
|
680
|
+
|
|
681
|
+
Allow Orion to answer:
|
|
682
|
+
|
|
683
|
+
> Where does this input go?
|
|
684
|
+
|
|
685
|
+
and:
|
|
686
|
+
|
|
687
|
+
> What components can reach this operation?
|
|
688
|
+
|
|
689
|
+
Trace:
|
|
690
|
+
|
|
691
|
+
```text
|
|
692
|
+
entrypoint
|
|
693
|
+
→ router
|
|
694
|
+
→ middleware
|
|
695
|
+
→ controller
|
|
696
|
+
→ service
|
|
697
|
+
→ repository
|
|
698
|
+
→ external system
|
|
699
|
+
```
|
|
700
|
+
|
|
701
|
+
Produce explainable paths.
|
|
702
|
+
|
|
703
|
+
---
|
|
704
|
+
|
|
705
|
+
# 19. State Engine
|
|
706
|
+
|
|
707
|
+
Construct state-transition models.
|
|
708
|
+
|
|
709
|
+
Detect:
|
|
710
|
+
|
|
711
|
+
* invalid transitions
|
|
712
|
+
* missing transitions
|
|
713
|
+
* inconsistent cleanup
|
|
714
|
+
* race-sensitive states
|
|
715
|
+
* impossible states
|
|
716
|
+
* state-dependent authorization bugs
|
|
717
|
+
|
|
718
|
+
---
|
|
719
|
+
|
|
720
|
+
# 20. Quality Engines
|
|
721
|
+
|
|
722
|
+
Complexity, duplication, dead imports, error handling, and logging must be context-aware.
|
|
723
|
+
|
|
724
|
+
Do not turn style preferences into security findings.
|
|
725
|
+
|
|
726
|
+
Separate:
|
|
727
|
+
|
|
728
|
+
```text
|
|
729
|
+
ERROR
|
|
730
|
+
WARNING
|
|
731
|
+
INFO
|
|
732
|
+
```
|
|
733
|
+
|
|
734
|
+
from actual vulnerabilities.
|
|
735
|
+
|
|
736
|
+
---
|
|
737
|
+
|
|
738
|
+
# 21. Configuration Intelligence
|
|
739
|
+
|
|
740
|
+
Understand:
|
|
741
|
+
|
|
742
|
+
* environment variables
|
|
743
|
+
* configuration files
|
|
744
|
+
* defaults
|
|
745
|
+
* overrides
|
|
746
|
+
* deployment configuration
|
|
747
|
+
* secrets
|
|
748
|
+
* security-sensitive flags
|
|
749
|
+
* production/development differences
|
|
750
|
+
|
|
751
|
+
Detect unsafe combinations rather than isolated settings.
|
|
752
|
+
|
|
753
|
+
---
|
|
754
|
+
|
|
755
|
+
# 22. Chaos / Resilience
|
|
756
|
+
|
|
757
|
+
Do not randomly break systems without control.
|
|
758
|
+
|
|
759
|
+
Use safe simulation models first.
|
|
760
|
+
|
|
761
|
+
Analyze:
|
|
762
|
+
|
|
763
|
+
```text
|
|
764
|
+
timeouts
|
|
765
|
+
dependency failures
|
|
766
|
+
network failures
|
|
767
|
+
resource exhaustion
|
|
768
|
+
partial failures
|
|
769
|
+
retry storms
|
|
770
|
+
circuit breakers
|
|
771
|
+
idempotency
|
|
772
|
+
```
|
|
773
|
+
|
|
774
|
+
Keep destructive runtime behavior explicitly isolated and opt-in.
|
|
775
|
+
|
|
776
|
+
---
|
|
777
|
+
|
|
778
|
+
# 23. Regression Engine
|
|
779
|
+
|
|
780
|
+
Maintain a baseline.
|
|
781
|
+
|
|
782
|
+
Compare:
|
|
783
|
+
|
|
784
|
+
```text
|
|
785
|
+
BASELINE
|
|
786
|
+
↓
|
|
787
|
+
CURRENT
|
|
788
|
+
↓
|
|
789
|
+
NEW
|
|
790
|
+
FIXED
|
|
791
|
+
UNCHANGED
|
|
792
|
+
REGRESSED
|
|
793
|
+
```
|
|
794
|
+
|
|
795
|
+
Finding identity must be stable across runs.
|
|
796
|
+
|
|
797
|
+
---
|
|
798
|
+
|
|
799
|
+
# 24. Noise / False Positive Intelligence
|
|
800
|
+
|
|
801
|
+
Create a dedicated layer for reducing noise.
|
|
802
|
+
|
|
803
|
+
Consider:
|
|
804
|
+
|
|
805
|
+
```text
|
|
806
|
+
duplicate findings
|
|
807
|
+
same root cause
|
|
808
|
+
test code
|
|
809
|
+
generated code
|
|
810
|
+
dead code
|
|
811
|
+
known-safe wrappers
|
|
812
|
+
framework guarantees
|
|
813
|
+
suppressions
|
|
814
|
+
historical false positives
|
|
815
|
+
confidence
|
|
816
|
+
cross-engine disagreement
|
|
817
|
+
```
|
|
818
|
+
|
|
819
|
+
Never suppress findings merely because suppression makes the report smaller.
|
|
820
|
+
|
|
821
|
+
Every suppression must be explainable.
|
|
822
|
+
|
|
823
|
+
---
|
|
824
|
+
|
|
825
|
+
# 25. FP Learning
|
|
826
|
+
|
|
827
|
+
Do not blindly train on developer dismissals.
|
|
828
|
+
|
|
829
|
+
Represent:
|
|
830
|
+
|
|
831
|
+
```text
|
|
832
|
+
finding
|
|
833
|
+
reason dismissed
|
|
834
|
+
location
|
|
835
|
+
rule
|
|
836
|
+
context
|
|
837
|
+
historical behavior
|
|
838
|
+
```
|
|
839
|
+
|
|
840
|
+
Learn contextual suppression patterns while retaining safeguards against poisoning.
|
|
841
|
+
|
|
842
|
+
Never allow a single dismissal to globally disable a vulnerability class.
|
|
843
|
+
|
|
844
|
+
---
|
|
845
|
+
|
|
846
|
+
# 26. Runtime Hunter
|
|
847
|
+
|
|
848
|
+
Keep runtime analysis isolated and permission-controlled.
|
|
849
|
+
|
|
850
|
+
Support:
|
|
851
|
+
|
|
852
|
+
```text
|
|
853
|
+
collector
|
|
854
|
+
probe
|
|
855
|
+
session
|
|
856
|
+
observation
|
|
857
|
+
runtime evidence
|
|
858
|
+
```
|
|
859
|
+
|
|
860
|
+
Runtime evidence must be clearly distinguished from static evidence.
|
|
861
|
+
|
|
862
|
+
---
|
|
863
|
+
|
|
864
|
+
# 27. Security Boundaries
|
|
865
|
+
|
|
866
|
+
Every engine must respect:
|
|
867
|
+
|
|
868
|
+
* filesystem boundaries
|
|
869
|
+
* network policy
|
|
870
|
+
* subprocess policy
|
|
871
|
+
* resource limits
|
|
872
|
+
* timeout limits
|
|
873
|
+
* memory limits
|
|
874
|
+
* recursion limits
|
|
875
|
+
* file limits
|
|
876
|
+
* archive extraction limits
|
|
877
|
+
* symlink handling
|
|
878
|
+
* untrusted repository content
|
|
879
|
+
|
|
880
|
+
Never execute repository code merely to analyze it unless explicitly enabled.
|
|
881
|
+
|
|
882
|
+
---
|
|
883
|
+
|
|
884
|
+
# 28. Determinism
|
|
885
|
+
|
|
886
|
+
The same repository and configuration should produce stable output.
|
|
887
|
+
|
|
888
|
+
Guarantee:
|
|
889
|
+
|
|
890
|
+
```text
|
|
891
|
+
stable finding IDs
|
|
892
|
+
stable ordering
|
|
893
|
+
stable serialization
|
|
894
|
+
stable severity
|
|
895
|
+
stable confidence
|
|
896
|
+
```
|
|
897
|
+
|
|
898
|
+
Avoid dependence on:
|
|
899
|
+
|
|
900
|
+
* hash iteration order
|
|
901
|
+
* filesystem ordering
|
|
902
|
+
* current time
|
|
903
|
+
* random values
|
|
904
|
+
* machine-specific state
|
|
905
|
+
|
|
906
|
+
unless explicitly recorded.
|
|
907
|
+
|
|
908
|
+
---
|
|
909
|
+
|
|
910
|
+
# 29. Error Handling
|
|
911
|
+
|
|
912
|
+
This rule is mandatory:
|
|
913
|
+
|
|
914
|
+
> NEVER silently convert an analysis failure into a clean result.
|
|
915
|
+
|
|
916
|
+
Forbidden:
|
|
917
|
+
|
|
918
|
+
```python
|
|
919
|
+
try:
|
|
920
|
+
analyze()
|
|
921
|
+
except Exception:
|
|
922
|
+
pass
|
|
923
|
+
```
|
|
924
|
+
|
|
925
|
+
Instead:
|
|
926
|
+
|
|
927
|
+
```text
|
|
928
|
+
engine failure
|
|
929
|
+
↓
|
|
930
|
+
structured EngineError
|
|
931
|
+
↓
|
|
932
|
+
affected analysis scope
|
|
933
|
+
↓
|
|
934
|
+
partial/failed status
|
|
935
|
+
↓
|
|
936
|
+
visible diagnostic
|
|
937
|
+
```
|
|
938
|
+
|
|
939
|
+
A broken analyzer must never create a false sense of security.
|
|
940
|
+
|
|
941
|
+
---
|
|
942
|
+
|
|
943
|
+
# 30. Evidence Provenance
|
|
944
|
+
|
|
945
|
+
Every finding must answer:
|
|
946
|
+
|
|
947
|
+
```text
|
|
948
|
+
Which engine produced this?
|
|
949
|
+
Which version?
|
|
950
|
+
Which source locations?
|
|
951
|
+
Which analysis passes?
|
|
952
|
+
Which assumptions?
|
|
953
|
+
Which evidence?
|
|
954
|
+
Which configuration?
|
|
955
|
+
Which rules?
|
|
956
|
+
```
|
|
957
|
+
|
|
958
|
+
Use content-addressed IDs where appropriate.
|
|
959
|
+
|
|
960
|
+
---
|
|
961
|
+
|
|
962
|
+
# 31. Test Strategy
|
|
963
|
+
|
|
964
|
+
Create extensive fixtures.
|
|
965
|
+
|
|
966
|
+
Every engine requires:
|
|
967
|
+
|
|
968
|
+
```text
|
|
969
|
+
true positives
|
|
970
|
+
true negatives
|
|
971
|
+
edge cases
|
|
972
|
+
framework cases
|
|
973
|
+
cross-file cases
|
|
974
|
+
adversarial cases
|
|
975
|
+
regression cases
|
|
976
|
+
large-project cases
|
|
977
|
+
```
|
|
978
|
+
|
|
979
|
+
Test false positives as aggressively as true positives.
|
|
980
|
+
|
|
981
|
+
A detector that catches 100 vulnerabilities but creates 10,000 false positives is not considered successful.
|
|
982
|
+
|
|
983
|
+
---
|
|
984
|
+
|
|
985
|
+
# 32. Adversarial Testing
|
|
986
|
+
|
|
987
|
+
Continuously test Orion against:
|
|
988
|
+
|
|
989
|
+
* obfuscated code
|
|
990
|
+
* unusual formatting
|
|
991
|
+
* aliases
|
|
992
|
+
* wrappers
|
|
993
|
+
* decorators
|
|
994
|
+
* inheritance
|
|
995
|
+
* dynamic imports
|
|
996
|
+
* generated code
|
|
997
|
+
* nested calls
|
|
998
|
+
* indirect calls
|
|
999
|
+
* framework abstractions
|
|
1000
|
+
* dead branches
|
|
1001
|
+
* unreachable code
|
|
1002
|
+
* misleading variable names
|
|
1003
|
+
* intentionally confusing source structures
|
|
1004
|
+
|
|
1005
|
+
The objective is not merely benchmark performance.
|
|
1006
|
+
|
|
1007
|
+
The objective is **robust reasoning under hostile code structure**.
|
|
1008
|
+
|
|
1009
|
+
---
|
|
1010
|
+
|
|
1011
|
+
# 33. Performance
|
|
1012
|
+
|
|
1013
|
+
Implement:
|
|
1014
|
+
|
|
1015
|
+
```text
|
|
1016
|
+
incremental analysis
|
|
1017
|
+
caching
|
|
1018
|
+
parallel analysis
|
|
1019
|
+
bounded graph exploration
|
|
1020
|
+
memoization
|
|
1021
|
+
content-addressed artifacts
|
|
1022
|
+
changed-file analysis
|
|
1023
|
+
dependency-aware invalidation
|
|
1024
|
+
```
|
|
1025
|
+
|
|
1026
|
+
Never allow one pathological file to destroy an entire scan.
|
|
1027
|
+
|
|
1028
|
+
---
|
|
1029
|
+
|
|
1030
|
+
# 34. Finding Deduplication
|
|
1031
|
+
|
|
1032
|
+
Use structural fingerprints.
|
|
1033
|
+
|
|
1034
|
+
Two findings should be considered related when they share:
|
|
1035
|
+
|
|
1036
|
+
```text
|
|
1037
|
+
root cause
|
|
1038
|
+
source
|
|
1039
|
+
sink
|
|
1040
|
+
attack path
|
|
1041
|
+
symbol
|
|
1042
|
+
data-flow path
|
|
1043
|
+
```
|
|
1044
|
+
|
|
1045
|
+
Preserve all supporting evidence but present a clean unified result.
|
|
1046
|
+
|
|
1047
|
+
---
|
|
1048
|
+
|
|
1049
|
+
# 35. Explainability
|
|
1050
|
+
|
|
1051
|
+
Every high-severity finding must be explainable.
|
|
1052
|
+
|
|
1053
|
+
Example:
|
|
1054
|
+
|
|
1055
|
+
```text
|
|
1056
|
+
CRITICAL — SQL Injection
|
|
1057
|
+
|
|
1058
|
+
Confidence: 97%
|
|
1059
|
+
|
|
1060
|
+
Attack path:
|
|
1061
|
+
|
|
1062
|
+
request.args["id"]
|
|
1063
|
+
↓
|
|
1064
|
+
UserController.get()
|
|
1065
|
+
↓
|
|
1066
|
+
UserService.find()
|
|
1067
|
+
↓
|
|
1068
|
+
query = "... " + id
|
|
1069
|
+
↓
|
|
1070
|
+
db.execute(query)
|
|
1071
|
+
|
|
1072
|
+
Why Orion believes this is exploitable:
|
|
1073
|
+
✓ attacker-controlled source
|
|
1074
|
+
✓ interprocedural propagation confirmed
|
|
1075
|
+
✓ SQL sink confirmed
|
|
1076
|
+
✓ no recognized sanitizer
|
|
1077
|
+
✓ route reachable without required authorization
|
|
1078
|
+
|
|
1079
|
+
Supporting engines:
|
|
1080
|
+
SAST
|
|
1081
|
+
Taint
|
|
1082
|
+
Callgraph
|
|
1083
|
+
Dataflow
|
|
1084
|
+
Authorization
|
|
1085
|
+
```
|
|
1086
|
+
|
|
1087
|
+
The explanation must be generated from structured evidence, not invented prose.
|
|
1088
|
+
|
|
1089
|
+
---
|
|
1090
|
+
|
|
1091
|
+
# 36. No Hallucinated Findings
|
|
1092
|
+
|
|
1093
|
+
Orion must never claim evidence it did not actually observe.
|
|
1094
|
+
|
|
1095
|
+
Forbidden:
|
|
1096
|
+
|
|
1097
|
+
```text
|
|
1098
|
+
"Authentication appears to be missing"
|
|
1099
|
+
```
|
|
1100
|
+
|
|
1101
|
+
when the engine never inspected the relevant middleware.
|
|
1102
|
+
|
|
1103
|
+
Prefer:
|
|
1104
|
+
|
|
1105
|
+
```text
|
|
1106
|
+
"Orion could not establish an authentication check on this execution path."
|
|
1107
|
+
```
|
|
1108
|
+
|
|
1109
|
+
Distinguish:
|
|
1110
|
+
|
|
1111
|
+
```text
|
|
1112
|
+
NOT FOUND
|
|
1113
|
+
NOT OBSERVED
|
|
1114
|
+
UNKNOWN
|
|
1115
|
+
CONFIRMED
|
|
1116
|
+
```
|
|
1117
|
+
|
|
1118
|
+
These are not equivalent.
|
|
1119
|
+
|
|
1120
|
+
---
|
|
1121
|
+
|
|
1122
|
+
# 37. Future-Proof Architecture
|
|
1123
|
+
|
|
1124
|
+
Use versioned interfaces:
|
|
1125
|
+
|
|
1126
|
+
```text
|
|
1127
|
+
IR v1
|
|
1128
|
+
Finding Schema v1
|
|
1129
|
+
Evidence Schema v1
|
|
1130
|
+
Engine Contract v1
|
|
1131
|
+
Configuration Schema v1
|
|
1132
|
+
```
|
|
1133
|
+
|
|
1134
|
+
Keep engine internals replaceable.
|
|
1135
|
+
|
|
1136
|
+
Do not hard-code the architecture around one programming language or framework.
|
|
1137
|
+
|
|
1138
|
+
Where possible, build language adapters around a common semantic model.
|
|
1139
|
+
|
|
1140
|
+
---
|
|
1141
|
+
|
|
1142
|
+
# 38. Completion Criteria
|
|
1143
|
+
|
|
1144
|
+
Do NOT declare Orion complete because:
|
|
1145
|
+
|
|
1146
|
+
```text
|
|
1147
|
+
38 directories exist
|
|
1148
|
+
```
|
|
1149
|
+
|
|
1150
|
+
or:
|
|
1151
|
+
|
|
1152
|
+
```text
|
|
1153
|
+
38 modules import
|
|
1154
|
+
```
|
|
1155
|
+
|
|
1156
|
+
Completion requires:
|
|
1157
|
+
|
|
1158
|
+
```text
|
|
1159
|
+
38 real implementations
|
|
1160
|
+
+
|
|
1161
|
+
shared IR
|
|
1162
|
+
+
|
|
1163
|
+
cross-engine correlation
|
|
1164
|
+
+
|
|
1165
|
+
confidence system
|
|
1166
|
+
+
|
|
1167
|
+
finding deduplication
|
|
1168
|
+
+
|
|
1169
|
+
evidence provenance
|
|
1170
|
+
+
|
|
1171
|
+
deterministic output
|
|
1172
|
+
+
|
|
1173
|
+
resource isolation
|
|
1174
|
+
+
|
|
1175
|
+
failure transparency
|
|
1176
|
+
+
|
|
1177
|
+
positive fixtures
|
|
1178
|
+
+
|
|
1179
|
+
negative fixtures
|
|
1180
|
+
+
|
|
1181
|
+
regression suite
|
|
1182
|
+
+
|
|
1183
|
+
adversarial tests
|
|
1184
|
+
+
|
|
1185
|
+
integration tests
|
|
1186
|
+
+
|
|
1187
|
+
performance tests
|
|
1188
|
+
```
|
|
1189
|
+
|
|
1190
|
+
Every engine must demonstrate actual analytical behavior.
|
|
1191
|
+
|
|
1192
|
+
---
|
|
1193
|
+
|
|
1194
|
+
# Final Engineering Objective
|
|
1195
|
+
|
|
1196
|
+
Build Orion so that its reasoning pipeline resembles:
|
|
1197
|
+
|
|
1198
|
+
```text
|
|
1199
|
+
OBSERVE
|
|
1200
|
+
↓
|
|
1201
|
+
UNDERSTAND
|
|
1202
|
+
↓
|
|
1203
|
+
MODEL
|
|
1204
|
+
↓
|
|
1205
|
+
TRACE
|
|
1206
|
+
↓
|
|
1207
|
+
CORRELATE
|
|
1208
|
+
↓
|
|
1209
|
+
CHALLENGE
|
|
1210
|
+
↓
|
|
1211
|
+
VALIDATE
|
|
1212
|
+
↓
|
|
1213
|
+
SCORE
|
|
1214
|
+
↓
|
|
1215
|
+
DEDUPLICATE
|
|
1216
|
+
↓
|
|
1217
|
+
EXPLAIN
|
|
1218
|
+
↓
|
|
1219
|
+
REPORT
|
|
1220
|
+
```
|
|
1221
|
+
|
|
1222
|
+
Do not optimize for the number of findings.
|
|
1223
|
+
|
|
1224
|
+
Optimize for:
|
|
1225
|
+
|
|
1226
|
+
**high-confidence findings + strong evidence + low false positives + useful explanations + reproducibility.**
|
|
1227
|
+
|
|
1228
|
+
When uncertain, Orion must prefer:
|
|
1229
|
+
|
|
1230
|
+
```text
|
|
1231
|
+
"I cannot establish this"
|
|
1232
|
+
```
|
|
1233
|
+
|
|
1234
|
+
over:
|
|
1235
|
+
|
|
1236
|
+
```text
|
|
1237
|
+
"This is definitely vulnerable"
|
|
1238
|
+
```
|
|
1239
|
+
|
|
1240
|
+
Do not delete existing analysis infrastructure until its functionality has been understood, migrated, and covered by regression tests.
|
|
1241
|
+
|
|
1242
|
+
Do not create stubs merely to satisfy an engine count.
|
|
1243
|
+
|
|
1244
|
+
Do not use the name "THANOS" anywhere in the product. The product is **Orion Engine**.
|
|
1245
|
+
|
|
1246
|
+
The final system should feel like a serious next-generation software auditing platform rather than a bundle of linters.
|
|
1247
|
+
|
|
1248
|
+
Build incrementally, test continuously, preserve working functionality, and only remove legacy components after equivalent or superior Orion functionality has been demonstrated by tests.
|