@hoanghainh/komagu 2.5.0 → 2.6.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/CHANGELOG.md +17 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/ai-run-stats.json +87 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/auth-model.md +120 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/batches/index.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/batches/injection-001.json +383 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/batches/injection-002.json +205 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/batches/privilege-001.json +838 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/batches/privilege-002.json +124 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/batches/routes-001.json +778 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/batches/routes-002.json +546 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/batches/routes-003.json +661 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/batches/routes-004.json +659 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/batches/routes-005.json +612 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/batches/routes-006.json +106 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/coverage.json +19 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/bola-routes-001.json +516 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/bola-routes-002.json +332 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/bola-routes-003.json +218 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/bola-routes-004.json +561 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/bola-routes-005.json +316 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/bola-routes-006.json +14 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/inj-injection-001.json +782 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/inj-injection-002.json +418 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/priv-privilege-001.json +627 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/priv-privilege-002.json +253 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-1.json +68 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-10.json +68 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-11.json +61 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-12.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-13.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-14.json +66 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-15.json +69 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-16.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-17.json +61 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-18.json +69 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-19.json +64 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-2.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-20.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-21.json +61 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-22.json +50 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-3.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-4.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-5.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-6.json +70 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-7.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-8.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings/verified-9.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/findings.json +4857 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/mass-assignment.candidates.json +232 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/report.ja.md +2112 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/report.md +2112 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/routes/routes-001.json +425 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/routes/routes-002.json +333 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/routes/routes-003.json +400 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/routes/routes-004.json +403 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/routes/routes-005.json +398 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/routes/routes-006.json +63 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/score.json +82 -0
- package/assess/lsa/examples/eval-run-6/gptoss-a/stack-profile.json +225 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/ai-run-stats.json +91 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/auth-model.md +120 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/batches/index.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/batches/injection-001.json +383 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/batches/injection-002.json +205 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/batches/privilege-001.json +838 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/batches/privilege-002.json +124 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/batches/routes-001.json +778 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/batches/routes-002.json +546 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/batches/routes-003.json +661 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/batches/routes-004.json +659 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/batches/routes-005.json +612 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/batches/routes-006.json +106 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/coverage.json +21 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/bola-routes-001.json +593 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/bola-routes-002.json +367 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/bola-routes-003.json +207 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/bola-routes-004.json +477 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/bola-routes-005.json +341 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/bola-routes-006.json +14 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/inj-injection-001.json +821 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/inj-injection-002.json +410 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/priv-privilege-001.json +649 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/priv-privilege-002.json +222 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-1.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-10.json +67 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-11.json +68 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-12.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-13.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-14.json +64 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-15.json +70 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-16.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-17.json +61 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-18.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-19.json +65 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-2.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-20.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-21.json +62 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-22.json +50 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-3.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-4.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-5.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-6.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-7.json +64 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-8.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings/verified-9.json +60 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/findings.json +4966 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/mass-assignment.candidates.json +232 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/routes/routes-001.json +425 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/routes/routes-002.json +333 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/routes/routes-003.json +400 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/routes/routes-004.json +403 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/routes/routes-005.json +398 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/routes/routes-006.json +63 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/score.json +87 -0
- package/assess/lsa/examples/eval-run-6/gptoss-b/stack-profile.json +225 -0
- package/assess/lsa/examples/eval-run-6/ground-truth.json +851 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/ai-run-stats.json +96 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/auth-model.md +191 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/batches/index.json +60 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/batches/injection-001.json +383 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/batches/injection-002.json +205 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/batches/privilege-001.json +838 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/batches/privilege-002.json +124 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/batches/routes-001.json +778 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/batches/routes-002.json +546 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/batches/routes-003.json +661 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/batches/routes-004.json +659 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/batches/routes-005.json +612 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/batches/routes-006.json +106 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/coverage.json +31 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/bola-routes-001.json +527 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/bola-routes-002.json +568 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/bola-routes-003.json +467 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/bola-routes-004.json +342 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/bola-routes-005.json +693 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/bola-routes-006.json +16 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/inj-injection-001.json +1123 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/inj-injection-002.json +391 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/priv-privilege-001.json +726 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/priv-privilege-002.json +306 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-1.json +137 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-10.json +106 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-11.json +81 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-12.json +135 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-13.json +135 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-14.json +135 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-15.json +110 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-16.json +116 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-17.json +141 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-18.json +135 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-19.json +140 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-2.json +135 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-20.json +82 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-21.json +74 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-22.json +99 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-3.json +140 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-4.json +145 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-5.json +135 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-6.json +135 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-7.json +87 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-8.json +125 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings/verified-9.json +135 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/findings.json +6989 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/mass-assignment.candidates.json +232 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/memory.log +36 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/routes/routes-001.json +425 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/routes/routes-002.json +333 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/routes/routes-003.json +400 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/routes/routes-004.json +403 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/routes/routes-005.json +398 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/routes/routes-006.json +63 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/score.json +106 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-nothink/stack-profile.json +225 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-partial/auth-model.md +517 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-partial/findings/bola-routes-001.json +5 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-partial/findings/bola-routes-002.json +428 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-partial/findings/bola-routes-003.json +388 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-partial/findings/bola-routes-004.json +463 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-partial/findings/bola-routes-005.json +5 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-partial/findings/bola-routes-006.json +67 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-partial/findings/inj-injection-001.json +964 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-partial/findings.partial.json +1872 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-partial/memory.log +194 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-partial/score.partial.json +108 -0
- package/assess/lsa/examples/eval-run-6/qwen-16k-partial/stack-profile.json +225 -0
- package/assess/lsa/scripts/laravel_routes.py +102 -0
- package/assess/lsa/scripts/map_routes.py +4 -1
- package/assess/lsa/tests/EVAL-RESULTS.md +126 -0
- package/assess/lsa/tests/test_eval_run_6.py +104 -0
- package/assess/lsa/tests/test_laravel_routes.py +95 -0
- package/operate/ai/client.py +22 -9
- package/operate/ai/runner.py +4 -2
- package/operate/cli/__init__.py +1 -1
- package/operate/cli/commands/scan.py +8 -1
- package/operate/tests/test_ai_reasoning_effort.py +65 -0
- package/operate/tests/test_ai_route_inventory.py +53 -0
- package/package.json +1 -1
|
@@ -0,0 +1,341 @@
|
|
|
1
|
+
{
|
|
2
|
+
"batch_id": "routes-005",
|
|
3
|
+
"findings": [
|
|
4
|
+
{
|
|
5
|
+
"finding_id": "BOLA-R-0073",
|
|
6
|
+
"category": "bola",
|
|
7
|
+
"subtype": "missing_ownership_check",
|
|
8
|
+
"title": "BOLA in POST /users/<int:uid>/name: missing owner verification",
|
|
9
|
+
"route_id": "R-0073",
|
|
10
|
+
"endpoint": {
|
|
11
|
+
"method": "POST",
|
|
12
|
+
"path": "/users/<int:uid>/name"
|
|
13
|
+
},
|
|
14
|
+
"location": {
|
|
15
|
+
"file": "python-flask/profile.py",
|
|
16
|
+
"start_line": 18
|
|
17
|
+
},
|
|
18
|
+
"evidence": [
|
|
19
|
+
{
|
|
20
|
+
"file": "python-flask/profile.py",
|
|
21
|
+
"start_line": 18,
|
|
22
|
+
"code": "user = User.query.get(uid)\nuser.name = request.json[\"name\"]",
|
|
23
|
+
"why": "The user ID comes from the URL and is not bound to the authenticated user; any logged\u2011in user can change any other user's name.",
|
|
24
|
+
"line": 18
|
|
25
|
+
}
|
|
26
|
+
],
|
|
27
|
+
"severity": "high",
|
|
28
|
+
"confidence": "high",
|
|
29
|
+
"cwe": [
|
|
30
|
+
"CWE-284",
|
|
31
|
+
"CWE-639"
|
|
32
|
+
],
|
|
33
|
+
"recommendation": "Bind the target user ID to the authenticated user by loading the user with a query that includes the current user\u2019s ID or by checking that the loaded user\u2019s ID matches the session user before updating.",
|
|
34
|
+
"status": "unverified",
|
|
35
|
+
"attack_vector": {
|
|
36
|
+
"target_param": "uid"
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
"finding_id": "BOLA-R-0074",
|
|
41
|
+
"category": "bola",
|
|
42
|
+
"subtype": "missing_ownership_check",
|
|
43
|
+
"title": "BOLA in PATCH /users/<int:uid>: missing owner verification",
|
|
44
|
+
"route_id": "R-0074",
|
|
45
|
+
"endpoint": {
|
|
46
|
+
"method": "PATCH",
|
|
47
|
+
"path": "/users/<int:uid>"
|
|
48
|
+
},
|
|
49
|
+
"location": {
|
|
50
|
+
"file": "python-flask/profile.py",
|
|
51
|
+
"start_line": 26
|
|
52
|
+
},
|
|
53
|
+
"evidence": [
|
|
54
|
+
{
|
|
55
|
+
"file": "python-flask/profile.py",
|
|
56
|
+
"start_line": 26,
|
|
57
|
+
"code": "user = User.query.get(uid)\nfor key, value in request.json.items():\n setattr(user, key, value)",
|
|
58
|
+
"why": "The endpoint accepts any user ID from the URL and updates that user\u2019s record without verifying ownership.",
|
|
59
|
+
"line": 26
|
|
60
|
+
}
|
|
61
|
+
],
|
|
62
|
+
"severity": "high",
|
|
63
|
+
"confidence": "high",
|
|
64
|
+
"cwe": [
|
|
65
|
+
"CWE-284",
|
|
66
|
+
"CWE-639"
|
|
67
|
+
],
|
|
68
|
+
"recommendation": "Ensure the user ID in the request matches the authenticated user\u2019s ID before applying changes, or load the user with a query that includes the session user ID.",
|
|
69
|
+
"status": "unverified",
|
|
70
|
+
"attack_vector": {
|
|
71
|
+
"target_param": "uid"
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
"finding_id": "BOLA-R-0010",
|
|
76
|
+
"category": "bola",
|
|
77
|
+
"subtype": "missing_ownership_check",
|
|
78
|
+
"title": "BOLA in POST /Customer/Edit: missing owner verification",
|
|
79
|
+
"route_id": "R-0010",
|
|
80
|
+
"endpoint": {
|
|
81
|
+
"method": "POST",
|
|
82
|
+
"path": "/Customer/Edit"
|
|
83
|
+
},
|
|
84
|
+
"location": {
|
|
85
|
+
"file": "dotnet-legacy/Web/Controllers/CustomerController.cs",
|
|
86
|
+
"start_line": 12
|
|
87
|
+
},
|
|
88
|
+
"evidence": [
|
|
89
|
+
{
|
|
90
|
+
"file": "dotnet-legacy/Web/Controllers/CustomerController.cs",
|
|
91
|
+
"start_line": 12,
|
|
92
|
+
"code": "public ActionResult Edit(Customer customer)\n{\n db.Entry(customer).State = System.Data.Entity.EntityState.Modified;\n db.SaveChanges();",
|
|
93
|
+
"why": "The method accepts a Customer object with an arbitrary Id and updates it without checking that the Id belongs to the authenticated user.",
|
|
94
|
+
"line": 12
|
|
95
|
+
}
|
|
96
|
+
],
|
|
97
|
+
"severity": "high",
|
|
98
|
+
"confidence": "high",
|
|
99
|
+
"cwe": [
|
|
100
|
+
"CWE-284",
|
|
101
|
+
"CWE-639"
|
|
102
|
+
],
|
|
103
|
+
"recommendation": "Verify that the customer Id belongs to the current user before calling SaveChanges, or load the customer via a query that includes the user\u2019s Id.",
|
|
104
|
+
"status": "unverified"
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
"finding_id": "BOLA-R-0011",
|
|
108
|
+
"category": "bola",
|
|
109
|
+
"subtype": "missing_ownership_check",
|
|
110
|
+
"title": "BOLA in POST /Customer/EditName: missing owner verification",
|
|
111
|
+
"route_id": "R-0011",
|
|
112
|
+
"endpoint": {
|
|
113
|
+
"method": "POST",
|
|
114
|
+
"path": "/Customer/EditName"
|
|
115
|
+
},
|
|
116
|
+
"location": {
|
|
117
|
+
"file": "dotnet-legacy/Web/Controllers/CustomerController.cs",
|
|
118
|
+
"start_line": 20
|
|
119
|
+
},
|
|
120
|
+
"evidence": [
|
|
121
|
+
{
|
|
122
|
+
"file": "dotnet-legacy/Web/Controllers/CustomerController.cs",
|
|
123
|
+
"start_line": 20,
|
|
124
|
+
"code": "public ActionResult EditName([Bind(Include = \"Id,Name\")] Customer customer)\n{\n db.SaveChanges();",
|
|
125
|
+
"why": "The customer Id is taken from the request and the record is updated without verifying ownership.",
|
|
126
|
+
"line": 20
|
|
127
|
+
}
|
|
128
|
+
],
|
|
129
|
+
"severity": "high",
|
|
130
|
+
"confidence": "high",
|
|
131
|
+
"cwe": [
|
|
132
|
+
"CWE-284",
|
|
133
|
+
"CWE-639"
|
|
134
|
+
],
|
|
135
|
+
"recommendation": "Ensure the Id belongs to the authenticated user before saving, or load the customer by user Id and update only that record.",
|
|
136
|
+
"status": "unverified",
|
|
137
|
+
"attack_vector": {
|
|
138
|
+
"target_param": "id"
|
|
139
|
+
}
|
|
140
|
+
},
|
|
141
|
+
{
|
|
142
|
+
"finding_id": "BOLA-R-0012",
|
|
143
|
+
"category": "bola",
|
|
144
|
+
"subtype": "missing_ownership_check",
|
|
145
|
+
"title": "BOLA in POST /Customer/Refresh: missing owner verification",
|
|
146
|
+
"route_id": "R-0012",
|
|
147
|
+
"endpoint": {
|
|
148
|
+
"method": "POST",
|
|
149
|
+
"path": "/Customer/Refresh"
|
|
150
|
+
},
|
|
151
|
+
"location": {
|
|
152
|
+
"file": "dotnet-legacy/Web/Controllers/CustomerController.cs",
|
|
153
|
+
"start_line": 27
|
|
154
|
+
},
|
|
155
|
+
"evidence": [
|
|
156
|
+
{
|
|
157
|
+
"file": "dotnet-legacy/Web/Controllers/CustomerController.cs",
|
|
158
|
+
"start_line": 27,
|
|
159
|
+
"code": "public ActionResult Refresh(int id)\n{\n var customer = db.Customers.Find(id);\n TryUpdateModel(customer);\n db.SaveChanges();",
|
|
160
|
+
"why": "The id is supplied by the caller and the customer is updated without checking that it belongs to the authenticated user.",
|
|
161
|
+
"line": 27
|
|
162
|
+
}
|
|
163
|
+
],
|
|
164
|
+
"severity": "high",
|
|
165
|
+
"confidence": "high",
|
|
166
|
+
"cwe": [
|
|
167
|
+
"CWE-284",
|
|
168
|
+
"CWE-639"
|
|
169
|
+
],
|
|
170
|
+
"recommendation": "Validate that the customer Id belongs to the current user before applying updates, or load the customer via a query that includes the user\u2019s Id.",
|
|
171
|
+
"status": "unverified",
|
|
172
|
+
"attack_vector": {
|
|
173
|
+
"target_param": "id"
|
|
174
|
+
}
|
|
175
|
+
},
|
|
176
|
+
{
|
|
177
|
+
"finding_id": "BOLA-R-0016",
|
|
178
|
+
"category": "bola",
|
|
179
|
+
"subtype": "missing_ownership_check",
|
|
180
|
+
"title": "BOLA in ANY /dotnet-legacy/Web/Handlers/GetFile.ashx: missing owner verification",
|
|
181
|
+
"route_id": "R-0016",
|
|
182
|
+
"endpoint": {
|
|
183
|
+
"method": "ANY",
|
|
184
|
+
"path": "/dotnet-legacy/Web/Handlers/GetFile.ashx"
|
|
185
|
+
},
|
|
186
|
+
"location": {
|
|
187
|
+
"file": "dotnet-legacy/Web/Handlers/GetFile.ashx",
|
|
188
|
+
"start_line": 8
|
|
189
|
+
},
|
|
190
|
+
"evidence": [
|
|
191
|
+
{
|
|
192
|
+
"file": "dotnet-legacy/Web/Handlers/GetFile.ashx",
|
|
193
|
+
"start_line": 8,
|
|
194
|
+
"code": "string fileId = context.Request.QueryString[\"file_id\"];\nstring path = DocStore.PathFor(fileId);\ncontext.Response.TransmitFile(path);",
|
|
195
|
+
"why": "The file identifier comes from the query string and is used to locate and transmit a file without any check that the requesting user owns or is authorized to view that file.",
|
|
196
|
+
"line": 8
|
|
197
|
+
}
|
|
198
|
+
],
|
|
199
|
+
"severity": "high",
|
|
200
|
+
"confidence": "high",
|
|
201
|
+
"cwe": [
|
|
202
|
+
"CWE-284",
|
|
203
|
+
"CWE-639"
|
|
204
|
+
],
|
|
205
|
+
"recommendation": "Add an ownership check that the file belongs to the authenticated user before transmitting, or restrict the handler to authenticated users only.",
|
|
206
|
+
"status": "unverified",
|
|
207
|
+
"attack_vector": {
|
|
208
|
+
"target_param": "file_id"
|
|
209
|
+
}
|
|
210
|
+
},
|
|
211
|
+
{
|
|
212
|
+
"finding_id": "BOLA-R-0029",
|
|
213
|
+
"category": "bola",
|
|
214
|
+
"subtype": "missing_ownership_check",
|
|
215
|
+
"title": "BOLA in POST <see web.xml servlet-mapping>: missing owner verification",
|
|
216
|
+
"route_id": "R-0029",
|
|
217
|
+
"endpoint": {
|
|
218
|
+
"method": "POST",
|
|
219
|
+
"path": "<see web.xml servlet-mapping>"
|
|
220
|
+
},
|
|
221
|
+
"location": {
|
|
222
|
+
"file": "java-legacy/src/com/acme/web/ProfileServlet.java",
|
|
223
|
+
"start_line": 9
|
|
224
|
+
},
|
|
225
|
+
"evidence": [
|
|
226
|
+
{
|
|
227
|
+
"file": "java-legacy/src/com/acme/web/ProfileServlet.java",
|
|
228
|
+
"start_line": 9,
|
|
229
|
+
"code": "protected void doPost(HttpServletRequest request, HttpServletResponse response) throws IOException {\n Account account = new Account();\n try {\n BeanUtils.populate(account, request.getParameterMap());\n } catch (Exception e) {\n throw new IOException(e);\n }",
|
|
230
|
+
"why": "The servlet populates an Account object from arbitrary request parameters and does not verify that the account belongs to the authenticated user.",
|
|
231
|
+
"line": 9
|
|
232
|
+
}
|
|
233
|
+
],
|
|
234
|
+
"severity": "high",
|
|
235
|
+
"confidence": "high",
|
|
236
|
+
"cwe": [
|
|
237
|
+
"CWE-284",
|
|
238
|
+
"CWE-639"
|
|
239
|
+
],
|
|
240
|
+
"recommendation": "Validate that the account being updated belongs to the current user, or load the account via a query that includes the user\u2019s Id before applying changes.",
|
|
241
|
+
"status": "unverified",
|
|
242
|
+
"attack_vector": {
|
|
243
|
+
"target_param": "id"
|
|
244
|
+
}
|
|
245
|
+
},
|
|
246
|
+
{
|
|
247
|
+
"finding_id": "BOLA-R-0060",
|
|
248
|
+
"category": "bola",
|
|
249
|
+
"subtype": "missing_ownership_check",
|
|
250
|
+
"title": "BOLA in GET /php-plain/mongo_find.php: missing owner verification",
|
|
251
|
+
"route_id": "R-0060",
|
|
252
|
+
"endpoint": {
|
|
253
|
+
"method": "GET",
|
|
254
|
+
"path": "/php-plain/mongo_find.php"
|
|
255
|
+
},
|
|
256
|
+
"location": {
|
|
257
|
+
"file": "php-plain/mongo_find.php",
|
|
258
|
+
"start_line": 5
|
|
259
|
+
},
|
|
260
|
+
"evidence": [
|
|
261
|
+
{
|
|
262
|
+
"file": "php-plain/mongo_find.php",
|
|
263
|
+
"start_line": 5,
|
|
264
|
+
"code": "$doc = $coll->findOne(array('login' => $_GET['login'], 'pass' => $_GET['pass']));\n$docs = $coll->find(array('$where' => \"this.name == '\" . $_GET['n'] . \"'\"));",
|
|
265
|
+
"why": "The endpoint accepts arbitrary query parameters and returns matching documents without restricting them to the authenticated user.",
|
|
266
|
+
"line": 5
|
|
267
|
+
}
|
|
268
|
+
],
|
|
269
|
+
"severity": "high",
|
|
270
|
+
"confidence": "high",
|
|
271
|
+
"cwe": [
|
|
272
|
+
"CWE-284",
|
|
273
|
+
"CWE-639"
|
|
274
|
+
],
|
|
275
|
+
"recommendation": "Add a filter that limits returned documents to those owned by the current user, or remove the endpoint from public access.",
|
|
276
|
+
"status": "unverified"
|
|
277
|
+
}
|
|
278
|
+
],
|
|
279
|
+
"route_verdicts": [
|
|
280
|
+
{
|
|
281
|
+
"route_id": "R-0072",
|
|
282
|
+
"verdict": "safe"
|
|
283
|
+
},
|
|
284
|
+
{
|
|
285
|
+
"route_id": "R-0073",
|
|
286
|
+
"verdict": "vulnerable"
|
|
287
|
+
},
|
|
288
|
+
{
|
|
289
|
+
"route_id": "R-0074",
|
|
290
|
+
"verdict": "vulnerable"
|
|
291
|
+
},
|
|
292
|
+
{
|
|
293
|
+
"route_id": "R-0010",
|
|
294
|
+
"verdict": "vulnerable"
|
|
295
|
+
},
|
|
296
|
+
{
|
|
297
|
+
"route_id": "R-0011",
|
|
298
|
+
"verdict": "vulnerable"
|
|
299
|
+
},
|
|
300
|
+
{
|
|
301
|
+
"route_id": "R-0012",
|
|
302
|
+
"verdict": "vulnerable"
|
|
303
|
+
},
|
|
304
|
+
{
|
|
305
|
+
"route_id": "R-0016",
|
|
306
|
+
"verdict": "vulnerable"
|
|
307
|
+
},
|
|
308
|
+
{
|
|
309
|
+
"route_id": "R-0029",
|
|
310
|
+
"verdict": "vulnerable"
|
|
311
|
+
},
|
|
312
|
+
{
|
|
313
|
+
"route_id": "R-0039",
|
|
314
|
+
"verdict": "safe"
|
|
315
|
+
},
|
|
316
|
+
{
|
|
317
|
+
"route_id": "R-0040",
|
|
318
|
+
"verdict": "safe"
|
|
319
|
+
},
|
|
320
|
+
{
|
|
321
|
+
"route_id": "R-0041",
|
|
322
|
+
"verdict": "safe"
|
|
323
|
+
},
|
|
324
|
+
{
|
|
325
|
+
"route_id": "R-0042",
|
|
326
|
+
"verdict": "safe"
|
|
327
|
+
},
|
|
328
|
+
{
|
|
329
|
+
"route_id": "R-0063",
|
|
330
|
+
"verdict": "safe"
|
|
331
|
+
},
|
|
332
|
+
{
|
|
333
|
+
"route_id": "R-0068",
|
|
334
|
+
"verdict": "safe"
|
|
335
|
+
},
|
|
336
|
+
{
|
|
337
|
+
"route_id": "R-0060",
|
|
338
|
+
"verdict": "vulnerable"
|
|
339
|
+
}
|
|
340
|
+
]
|
|
341
|
+
}
|