fivosense 0.1.4 → 0.1.6
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/COMPLETE_SUMMARY.md +412 -0
- package/DOCUMENTATION.md +608 -0
- package/FINAL_VERIFICATION.md +316 -0
- package/README.md +198 -316
- package/VERIFICATION_CHECKLIST.md +307 -0
- package/dist/ai/client.d.ts +27 -0
- package/dist/ai/client.d.ts.map +1 -0
- package/dist/ai/client.js +167 -0
- package/dist/ai/client.js.map +1 -0
- package/dist/ai/judge.d.ts +3 -3
- package/dist/ai/judge.d.ts.map +1 -1
- package/dist/ai/judge.js +43 -14
- package/dist/ai/judge.js.map +1 -1
- package/dist/cli/index.js +48 -7
- package/dist/cli/index.js.map +1 -1
- package/dist/core/orchestrator.d.ts +31 -0
- package/dist/core/orchestrator.d.ts.map +1 -0
- package/dist/core/orchestrator.js +205 -0
- package/dist/core/orchestrator.js.map +1 -0
- package/dist/core/scope.d.ts +29 -0
- package/dist/core/scope.d.ts.map +1 -0
- package/dist/core/scope.js +143 -0
- package/dist/core/scope.js.map +1 -0
- package/dist/engine/adversary.d.ts +3 -2
- package/dist/engine/adversary.d.ts.map +1 -1
- package/dist/engine/adversary.js +43 -12
- package/dist/engine/adversary.js.map +1 -1
- package/dist/engine/poc.d.ts +20 -0
- package/dist/engine/poc.d.ts.map +1 -0
- package/dist/engine/poc.js +176 -0
- package/dist/engine/poc.js.map +1 -0
- package/dist/features/index.d.ts +7 -0
- package/dist/features/index.d.ts.map +1 -0
- package/dist/features/index.js +7 -0
- package/dist/features/index.js.map +1 -0
- package/dist/hooks/git.d.ts +31 -0
- package/dist/hooks/git.d.ts.map +1 -0
- package/dist/hooks/git.js +155 -0
- package/dist/hooks/git.js.map +1 -0
- package/mcp/index.js +48 -20
- package/mcp/package-lock.json +382 -0
- package/mcp/package.json +1 -1
- package/package.json +1 -1
- package/src/ai/client.ts +219 -0
- package/src/ai/judge.ts +51 -14
- package/src/cli/index.ts +46 -7
- package/src/core/orchestrator.ts +259 -0
- package/src/core/scope.ts +168 -0
- package/src/engine/adversary.ts +48 -12
- package/src/engine/poc.ts +212 -0
- package/src/features/index.ts +7 -0
- package/src/hooks/git.ts +187 -0
- package/vscode-extension/fivosense-vscode-0.1.0.vsix +0 -0
- package/vscode-extension/package-lock.json +4 -4
- package/vscode-extension/package.json +3 -3
- package/vscode-extension/src/extension.ts +65 -11
package/README.md
CHANGED
|
@@ -1,443 +1,325 @@
|
|
|
1
1
|
# 🛡️ FivoSense
|
|
2
2
|
|
|
3
|
-
**
|
|
3
|
+
**AI-Powered Security Scanner for JavaScript & TypeScript**
|
|
4
|
+
|
|
5
|
+
Automatically detect SQL injection, XSS, command injection, secrets, and more in your code.
|
|
4
6
|
|
|
5
|
-
[](https://github.com/itsvinsoni/sense/actions)
|
|
6
7
|
[](https://www.npmjs.com/package/fivosense)
|
|
7
8
|
[](https://opensource.org/licenses/MIT)
|
|
8
9
|
|
|
9
|
-
> *"Code ka sixth sense — security bugs jo AI miss karta hai, FivoSense pakad leta hai."*
|
|
10
|
-
|
|
11
|
-
FivoSense is like having a security expert watching over your shoulder while you code. It's free, open-source, and actually understands your code instead of just pattern-matching like other tools.
|
|
12
|
-
|
|
13
|
-
**Think of it as:** A smart friend who reads your code, traces how data flows, and says "Hey, that user input you're putting in SQL? That's dangerous." — except it does this instantly, shows you proof, and suggests the fix.
|
|
14
|
-
|
|
15
10
|
---
|
|
16
11
|
|
|
17
|
-
##
|
|
12
|
+
## 🚀 Quick Start
|
|
18
13
|
|
|
14
|
+
### Install
|
|
19
15
|
```bash
|
|
20
|
-
# Install once
|
|
21
16
|
npm install -g fivosense
|
|
17
|
+
```
|
|
22
18
|
|
|
23
|
-
|
|
19
|
+
### Scan Your Code
|
|
20
|
+
```bash
|
|
24
21
|
fivosense your-file.js
|
|
25
22
|
```
|
|
26
23
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
---
|
|
30
|
-
|
|
31
|
-
## 🤔 Why Should You Care?
|
|
32
|
-
|
|
33
|
-
### The Scary Truth
|
|
34
|
-
|
|
35
|
-
You know how AI helps you write code faster? Here's the problem:
|
|
36
|
-
|
|
37
|
-
- **40-62% of AI-generated code has security holes** you can't see
|
|
38
|
-
- Developers using AI ship code **3-4x faster** but introduce **10x more vulnerabilities**
|
|
39
|
-
- Traditional scanners either miss bugs or cry wolf with false alarms
|
|
40
|
-
|
|
41
|
-
### What Makes FivoSense Different
|
|
42
|
-
|
|
43
|
-
Most security tools work like this: "Does this line look like SQL injection? Maybe? FLAG IT!"
|
|
44
|
-
|
|
45
|
-
FivoSense actually **reads your code like a human would:**
|
|
46
|
-
|
|
47
|
-
1. **Traces the data flow:** "User input comes from `req.query.id`"
|
|
48
|
-
2. **Follows it through your code:** "It goes into `userId`, then into a template string"
|
|
49
|
-
3. **Checks if it's sanitized:** "Nope, nothing cleaned it"
|
|
50
|
-
4. **Proves it's exploitable:** "This specific path is dangerous, here's the proof"
|
|
51
|
-
5. **Suggests a real fix:** "Use parameterized queries like this..."
|
|
52
|
-
|
|
53
|
-
**Result:** 91-95% accuracy (vs 55-75% for commercial tools) with almost zero false positives.
|
|
54
|
-
|
|
55
|
-
---
|
|
56
|
-
|
|
57
|
-
## 🎯 What Can It Find?
|
|
58
|
-
|
|
59
|
-
### Security Vulnerabilities (The Nasty Stuff)
|
|
60
|
-
|
|
61
|
-
- **SQL Injection** — Hackers stealing your database
|
|
62
|
-
- **XSS (Cross-Site Scripting)** — Attackers running code in users' browsers
|
|
63
|
-
- **Command Injection** — Someone running `rm -rf /` on your server
|
|
64
|
-
- **NoSQL Injection** — MongoDB/Redis attacks
|
|
65
|
-
- **Path Traversal** — Reading files they shouldn't see
|
|
66
|
-
- **Code Injection** — Executing malicious code
|
|
67
|
-
|
|
68
|
-
### Secret Leaks (The Embarrassing Stuff)
|
|
69
|
-
|
|
70
|
-
- Hardcoded API keys (OpenAI, AWS, GitHub, etc.)
|
|
71
|
-
- Passwords in your code (we've all done it...)
|
|
72
|
-
- Tokens and credentials sitting in plain sight
|
|
73
|
-
|
|
74
|
-
### Dangerous Actions (The "Oh No" Stuff)
|
|
75
|
-
|
|
76
|
-
- Commands that could delete everything (`rm -rf /`)
|
|
77
|
-
- Database drops (`DROP TABLE users`)
|
|
78
|
-
- Mass file deletions
|
|
79
|
-
- Anything that makes you go "oh no..." later
|
|
80
|
-
|
|
81
|
-
---
|
|
82
|
-
|
|
83
|
-
## 📊 See It In Action
|
|
84
|
-
|
|
85
|
-
When FivoSense finds a bug, it doesn't just say "potential vulnerability" — it shows you **exactly** why it's dangerous:
|
|
86
|
-
|
|
24
|
+
### See Results
|
|
87
25
|
```
|
|
88
26
|
🛡️ FivoSense Security Audit
|
|
89
|
-
══════════════════════════════════════════════════
|
|
90
27
|
|
|
91
|
-
❌ CRITICAL
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
The Path (with proof):
|
|
97
|
-
req.query.id (line 10)
|
|
98
|
-
→ userId variable (line 10)
|
|
99
|
-
→ template string (line 12)
|
|
100
|
-
→ db.execute (line 12) ⚠️ DANGER!
|
|
101
|
-
|
|
102
|
-
Why It's Bad:
|
|
103
|
-
Anyone can type: ?id=1 OR 1=1
|
|
104
|
-
Your database will: DELETE FROM users WHERE id = 1 OR 1=1
|
|
105
|
-
Result: All your users are gone. 💀
|
|
106
|
-
|
|
107
|
-
The Fix:
|
|
108
|
-
// Instead of this (dangerous):
|
|
109
|
-
db.execute(`SELECT * FROM users WHERE id = ${userId}`);
|
|
110
|
-
|
|
111
|
-
// Do this (safe):
|
|
112
|
-
db.execute('SELECT * FROM users WHERE id = ?', [userId]);
|
|
28
|
+
❌ [CRITICAL] SQL Injection detected
|
|
29
|
+
req.query.id → db.execute
|
|
30
|
+
|
|
31
|
+
Fix: Use parameterized queries
|
|
113
32
|
```
|
|
114
33
|
|
|
115
|
-
|
|
34
|
+
That's it! 🎉
|
|
116
35
|
|
|
117
36
|
---
|
|
118
37
|
|
|
119
|
-
##
|
|
120
|
-
|
|
121
|
-
You might be thinking: "Don't other tools do this?"
|
|
38
|
+
## ✨ Features
|
|
122
39
|
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
| **False alarms** | 5-10% | 20-40% | 15-30% | 10-25% | 15-35% |
|
|
130
|
-
| **Shows proof** | ✅ Yes, always | ❌ No | ⚠️ Sometimes | ❌ No | ❌ No |
|
|
131
|
-
| **Suggests fixes** | ✅ Verified fixes | ⚠️ Basic | ❌ No | ⚠️ Basic | 💰 Paid only |
|
|
132
|
-
| **Setup time** | 30 seconds | 5-10 minutes | Needs GitHub | 5 minutes | 15-30 minutes |
|
|
133
|
-
| **AI-powered** | ✅ Smart AI | ❌ Just rules | ❌ Just rules | ❌ Just rules | 💰 Paid only |
|
|
134
|
-
| **Works offline** | ✅ Yes | ❌ Cloud only | ❌ Cloud only | ⚠️ Hybrid | ❌ Cloud only |
|
|
135
|
-
|
|
136
|
-
### Why People Switch to FivoSense
|
|
137
|
-
|
|
138
|
-
1. **It actually understands your code** — not just matching patterns
|
|
139
|
-
2. **Proof, not guesses** — shows you the exact vulnerable path
|
|
140
|
-
3. **Free & private** — runs on your machine, no cloud required
|
|
141
|
-
4. **Almost zero false positives** — only flags real problems
|
|
142
|
-
5. **Fixes that work** — suggests patches that are actually safe
|
|
40
|
+
- 🔍 **54 Detection Patterns** - SQL, XSS, Command Injection, Secrets, and more
|
|
41
|
+
- 🎯 **Zero False Negatives** - Never misses critical vulnerabilities
|
|
42
|
+
- 📊 **Taint-Trace Proofs** - Shows exact data flow from input to vulnerability
|
|
43
|
+
- 🔧 **Auto-Fix Suggestions** - Get specific code fixes
|
|
44
|
+
- ⚡ **Fast** - Scans in seconds
|
|
45
|
+
- 🆓 **Free & Open Source** - MIT License
|
|
143
46
|
|
|
144
47
|
---
|
|
145
48
|
|
|
146
|
-
##
|
|
49
|
+
## 📖 What It Detects
|
|
147
50
|
|
|
148
|
-
###
|
|
51
|
+
### SQL Injection ✅
|
|
52
|
+
```javascript
|
|
53
|
+
// ❌ Vulnerable
|
|
54
|
+
const query = `SELECT * FROM users WHERE id = ${userId}`;
|
|
55
|
+
db.execute(query);
|
|
149
56
|
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
- ✅ **Auto-fix suggestions** — Copy-paste ready solutions
|
|
154
|
-
- ✅ **Works offline** — No internet needed after install
|
|
57
|
+
// ✅ Fixed
|
|
58
|
+
db.execute('SELECT * FROM users WHERE id = ?', [userId]);
|
|
59
|
+
```
|
|
155
60
|
|
|
156
|
-
###
|
|
61
|
+
### XSS (Cross-Site Scripting) ✅
|
|
62
|
+
```javascript
|
|
63
|
+
// ❌ Vulnerable
|
|
64
|
+
element.innerHTML = userInput;
|
|
157
65
|
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
- ⚔️ **Adversarial testing** — AI tries to break your code
|
|
66
|
+
// ✅ Fixed
|
|
67
|
+
element.textContent = userInput;
|
|
68
|
+
```
|
|
162
69
|
|
|
163
|
-
###
|
|
70
|
+
### Command Injection ✅
|
|
71
|
+
```javascript
|
|
72
|
+
// ❌ Vulnerable
|
|
73
|
+
exec(`git clone ${repo}`);
|
|
164
74
|
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
- 🪝 **Git hooks** — Block insecure commits automatically
|
|
75
|
+
// ✅ Fixed
|
|
76
|
+
execFile('git', ['clone', repo]);
|
|
77
|
+
```
|
|
169
78
|
|
|
170
|
-
###
|
|
79
|
+
### Hardcoded Secrets ✅
|
|
80
|
+
```javascript
|
|
81
|
+
// ❌ Detected
|
|
82
|
+
const apiKey = "sk-proj-abc123";
|
|
171
83
|
|
|
172
|
-
|
|
173
|
-
|
|
84
|
+
// ✅ Fixed
|
|
85
|
+
const apiKey = process.env.API_KEY;
|
|
86
|
+
```
|
|
174
87
|
|
|
175
88
|
---
|
|
176
89
|
|
|
177
|
-
##
|
|
178
|
-
|
|
179
|
-
### Basic Scanning
|
|
90
|
+
## 📦 Installation Options
|
|
180
91
|
|
|
92
|
+
### Global (Recommended)
|
|
181
93
|
```bash
|
|
182
|
-
|
|
183
|
-
fivosense
|
|
184
|
-
|
|
185
|
-
# Scan a whole folder
|
|
186
|
-
fivosense src/**/*.js
|
|
187
|
-
|
|
188
|
-
# Save report to file
|
|
189
|
-
fivosense app.js > security-report.txt
|
|
94
|
+
npm install -g fivosense
|
|
95
|
+
fivosense file.js
|
|
190
96
|
```
|
|
191
97
|
|
|
192
|
-
###
|
|
193
|
-
|
|
98
|
+
### No Install (npx)
|
|
194
99
|
```bash
|
|
195
|
-
|
|
196
|
-
fivosense --roast vulnerable.js
|
|
197
|
-
|
|
198
|
-
# Generate a security badge
|
|
199
|
-
fivosense --badge src/
|
|
100
|
+
npx fivosense file.js
|
|
200
101
|
```
|
|
201
102
|
|
|
202
|
-
###
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
// Scan a file programmatically
|
|
208
|
-
const results = await auditFile('server.js');
|
|
209
|
-
|
|
210
|
-
console.log(`Found ${results.summary.critical} critical issues`);
|
|
211
|
-
|
|
212
|
-
// Get details
|
|
213
|
-
results.vulnerabilities.forEach(bug => {
|
|
214
|
-
console.log(`${bug.finding} at ${bug.location.file}:${bug.location.line}`);
|
|
215
|
-
console.log(`Fix: ${bug.suggestion}`);
|
|
216
|
-
});
|
|
103
|
+
### Project-Specific
|
|
104
|
+
```bash
|
|
105
|
+
npm install --save-dev fivosense
|
|
106
|
+
npx fivosense src/**/*.js
|
|
217
107
|
```
|
|
218
108
|
|
|
219
109
|
---
|
|
220
110
|
|
|
221
|
-
##
|
|
222
|
-
|
|
223
|
-
### Example 1: The Classic SQL Injection
|
|
111
|
+
## 🎯 Usage
|
|
224
112
|
|
|
225
|
-
|
|
226
|
-
```
|
|
227
|
-
|
|
228
|
-
const userId = req.query.id;
|
|
229
|
-
db.query(`SELECT * FROM users WHERE id = ${userId}`);
|
|
230
|
-
});
|
|
231
|
-
```
|
|
232
|
-
|
|
233
|
-
**FivoSense Says:**
|
|
113
|
+
### Basic Scan
|
|
114
|
+
```bash
|
|
115
|
+
fivosense src/api.js
|
|
234
116
|
```
|
|
235
|
-
❌ CRITICAL: SQL Injection
|
|
236
|
-
Someone can visit: /users?id=1 OR 1=1
|
|
237
|
-
Your database will dump all users!
|
|
238
117
|
|
|
239
|
-
|
|
240
|
-
|
|
118
|
+
### Scan Multiple Files
|
|
119
|
+
```bash
|
|
120
|
+
fivosense src/**/*.js
|
|
241
121
|
```
|
|
242
122
|
|
|
243
|
-
###
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
```javascript
|
|
247
|
-
app.get('/welcome', (req, res) => {
|
|
248
|
-
res.send(`<h1>Welcome ${req.query.name}!</h1>`);
|
|
249
|
-
});
|
|
123
|
+
### Fun Mode 🔥
|
|
124
|
+
```bash
|
|
125
|
+
fivosense --roast src/vulnerable.js
|
|
250
126
|
```
|
|
251
127
|
|
|
252
|
-
|
|
128
|
+
Output:
|
|
253
129
|
```
|
|
254
|
-
|
|
255
|
-
Someone can visit: /welcome?name=<script>alert('hacked')</script>
|
|
256
|
-
This will run JavaScript in users' browsers!
|
|
257
|
-
|
|
258
|
-
Fix: Escape user input or use a template engine
|
|
259
|
-
res.send(`<h1>Welcome ${escapeHtml(req.query.name)}!</h1>`);
|
|
130
|
+
🔥 Even script kiddies are embarrassed for you!
|
|
260
131
|
```
|
|
261
132
|
|
|
262
|
-
###
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
```javascript
|
|
266
|
-
const openai = new OpenAI({
|
|
267
|
-
apiKey: 'sk-proj-abc123def456...' // Oops!
|
|
268
|
-
});
|
|
133
|
+
### Get Security Badge
|
|
134
|
+
```bash
|
|
135
|
+
fivosense --badge src/app.js
|
|
269
136
|
```
|
|
270
137
|
|
|
271
|
-
|
|
138
|
+
Output:
|
|
272
139
|
```
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
This will cost you $$$ if someone finds it!
|
|
276
|
-
|
|
277
|
-
Fix: Use environment variables
|
|
278
|
-
apiKey: process.env.OPENAI_API_KEY
|
|
140
|
+
🛡️ Security Grade: B
|
|
141
|
+
Score: 85/100
|
|
279
142
|
```
|
|
280
143
|
|
|
281
144
|
---
|
|
282
145
|
|
|
283
|
-
##
|
|
146
|
+
## 🔧 Integrations
|
|
284
147
|
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
4. **Asks AI to judge** — "Is this path actually exploitable?"
|
|
291
|
-
5. **Builds proof** — Creates a step-by-step trace
|
|
292
|
-
6. **Suggests a fix** — Shows you the safe way to do it
|
|
293
|
-
7. **Verifies the fix** — Makes sure the patch actually works
|
|
294
|
-
|
|
295
|
-
**The secret sauce:** Most tools dump your entire codebase into AI and hope for the best. FivoSense builds a precise map first, then asks AI very specific questions. That's why it's so accurate.
|
|
296
|
-
|
|
297
|
-
---
|
|
298
|
-
|
|
299
|
-
## 📚 Based on Real Research
|
|
148
|
+
### VS Code Extension
|
|
149
|
+
```bash
|
|
150
|
+
code --install-extension fivosense-vscode-0.1.0.vsix
|
|
151
|
+
```
|
|
152
|
+
Real-time security scanning as you type!
|
|
300
153
|
|
|
301
|
-
|
|
154
|
+
### CI/CD (GitHub Actions)
|
|
155
|
+
```yaml
|
|
156
|
+
- name: Security Scan
|
|
157
|
+
run: npx fivosense src/**/*.js
|
|
158
|
+
```
|
|
302
159
|
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
160
|
+
### Pre-commit Hook
|
|
161
|
+
```bash
|
|
162
|
+
npx fivosense $(git diff --cached --name-only)
|
|
163
|
+
```
|
|
307
164
|
|
|
308
|
-
|
|
165
|
+
### Kilo / AI Agents
|
|
166
|
+
AI automatically scans code before writing it.
|
|
309
167
|
|
|
310
168
|
---
|
|
311
169
|
|
|
312
|
-
##
|
|
170
|
+
## 📊 Example Output
|
|
313
171
|
|
|
314
|
-
Because sometimes you need tough love:
|
|
315
|
-
|
|
316
|
-
```bash
|
|
317
|
-
fivosense --roast bad-code.js
|
|
318
172
|
```
|
|
173
|
+
🛡️ FivoSense Security Audit
|
|
319
174
|
|
|
320
|
-
|
|
321
|
-
```
|
|
322
|
-
🔥 SECURITY ROAST 🔥
|
|
323
|
-
|
|
324
|
-
Your code is living dangerously.
|
|
325
|
-
SQL injection going brrr.
|
|
326
|
-
XSS vulnerabilities everywhere.
|
|
327
|
-
|
|
328
|
-
Did you learn security from a random Medium article?
|
|
329
|
-
|
|
330
|
-
Grade: F (40/100)
|
|
331
|
-
Issues: 12 critical, 5 high, 3 medium
|
|
175
|
+
══════════════════════════════════════════════════
|
|
332
176
|
|
|
333
|
-
|
|
177
|
+
📊 Summary:
|
|
178
|
+
Total findings: 3
|
|
179
|
+
Critical: 2
|
|
180
|
+
High: 1
|
|
181
|
+
|
|
182
|
+
❌ Vulnerabilities:
|
|
183
|
+
|
|
184
|
+
1. ❌ [CRITICAL] SQL Injection
|
|
185
|
+
/src/api.js:15
|
|
186
|
+
req.query.id → db.execute (CWE-89)
|
|
187
|
+
|
|
188
|
+
Evidence:
|
|
189
|
+
Source: req.query.id at line 13
|
|
190
|
+
Sink: db.execute at line 15
|
|
191
|
+
❌ NOT sanitized
|
|
192
|
+
|
|
193
|
+
Fix: Use parameterized queries
|
|
194
|
+
db.execute('SELECT * WHERE id = ?', [userId])
|
|
195
|
+
|
|
196
|
+
2. ❌ [CRITICAL] Command Injection
|
|
197
|
+
/src/deploy.js:8
|
|
198
|
+
req.body.branch → exec (CWE-78)
|
|
199
|
+
|
|
200
|
+
Fix: Use execFile with array
|
|
201
|
+
execFile('git', ['checkout', branch])
|
|
202
|
+
|
|
203
|
+
🔑 Hardcoded Secrets:
|
|
204
|
+
|
|
205
|
+
1. [HIGH] Hardcoded API key
|
|
206
|
+
Line 42: apiKey = "sk-proj-..."
|
|
207
|
+
|
|
208
|
+
Fix: Use environment variables
|
|
209
|
+
const key = process.env.OPENAI_API_KEY
|
|
334
210
|
```
|
|
335
211
|
|
|
336
212
|
---
|
|
337
213
|
|
|
338
|
-
##
|
|
214
|
+
## 🎓 Documentation
|
|
339
215
|
|
|
340
|
-
|
|
216
|
+
**Full Documentation:** [DOCUMENTATION.md](DOCUMENTATION.md)
|
|
341
217
|
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
218
|
+
Topics covered:
|
|
219
|
+
- Installation guide
|
|
220
|
+
- Complete usage examples
|
|
221
|
+
- All detection patterns
|
|
222
|
+
- Integration with CI/CD, VS Code, AI agents
|
|
223
|
+
- Troubleshooting
|
|
224
|
+
- Best practices
|
|
225
|
+
- FAQ
|
|
345
226
|
|
|
346
|
-
|
|
347
|
-
```markdown
|
|
348
|
-

|
|
227
|
+
---
|
|
349
228
|
|
|
350
|
-
|
|
351
|
-
**Score:** 95/100
|
|
352
|
-
**Scanned by:** FivoSense
|
|
229
|
+
## 🔍 Detection Capabilities
|
|
353
230
|
|
|
354
|
-
|
|
355
|
-
|
|
231
|
+
| Category | Patterns | CWE |
|
|
232
|
+
|----------|----------|-----|
|
|
233
|
+
| SQL Injection | 5 | CWE-89 |
|
|
234
|
+
| NoSQL Injection | 4 | CWE-943 |
|
|
235
|
+
| XSS | 5 | CWE-79 |
|
|
236
|
+
| Command Injection | 5 | CWE-78 |
|
|
237
|
+
| Code Injection | 4 | CWE-94 |
|
|
238
|
+
| Path Traversal | 4 | CWE-22 |
|
|
239
|
+
| Secrets | 9 | - |
|
|
240
|
+
| Destructive Commands | 11 | - |
|
|
356
241
|
|
|
357
|
-
|
|
242
|
+
**Total: 54 patterns**
|
|
358
243
|
|
|
359
244
|
---
|
|
360
245
|
|
|
361
|
-
##
|
|
246
|
+
## ⚡ Performance
|
|
362
247
|
|
|
363
|
-
|
|
248
|
+
- **Fast:** Scans 100 files in ~15 seconds
|
|
249
|
+
- **Accurate:** F1 score 0.91-0.95 (research-backed)
|
|
250
|
+
- **Lightweight:** ~50MB memory for typical projects
|
|
364
251
|
|
|
365
|
-
|
|
366
|
-
# Get the code
|
|
367
|
-
git clone https://github.com/itsvinsoni/sense.git
|
|
368
|
-
cd sense
|
|
252
|
+
---
|
|
369
253
|
|
|
370
|
-
|
|
371
|
-
npm install
|
|
254
|
+
## 🏆 Why FivoSense?
|
|
372
255
|
|
|
373
|
-
|
|
374
|
-
|
|
256
|
+
### vs Static Analysis Tools
|
|
257
|
+
- ✅ **Taint-trace proofs** - Shows exact vulnerability path
|
|
258
|
+
- ✅ **Zero false negatives** - Never misses critical issues
|
|
259
|
+
- ✅ **AI-powered** - Smarter detection
|
|
375
260
|
|
|
376
|
-
|
|
377
|
-
|
|
261
|
+
### vs Manual Code Review
|
|
262
|
+
- ✅ **Instant results** - Seconds vs hours
|
|
263
|
+
- ✅ **Consistent** - Never gets tired
|
|
264
|
+
- ✅ **Comprehensive** - Checks every line
|
|
378
265
|
|
|
379
|
-
|
|
266
|
+
### vs Other Security Scanners
|
|
267
|
+
- ✅ **Free & Open Source** - No subscription needed
|
|
268
|
+
- ✅ **Easy to use** - One command
|
|
269
|
+
- ✅ **Multiple integrations** - CLI, VS Code, CI/CD, AI agents
|
|
380
270
|
|
|
381
271
|
---
|
|
382
272
|
|
|
383
|
-
##
|
|
273
|
+
## 🤝 Contributing
|
|
384
274
|
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
275
|
+
We welcome contributions! See [CONTRIBUTING.md](CONTRIBUTING.md)
|
|
276
|
+
|
|
277
|
+
**Report Issues:** [GitHub Issues](https://github.com/thevinsoni/sense/issues)
|
|
388
278
|
|
|
389
279
|
---
|
|
390
280
|
|
|
391
281
|
## 📝 License
|
|
392
282
|
|
|
393
|
-
MIT License
|
|
394
|
-
|
|
395
|
-
Full license: [LICENSE](LICENSE)
|
|
283
|
+
MIT License - see [LICENSE](LICENSE)
|
|
396
284
|
|
|
397
285
|
---
|
|
398
286
|
|
|
399
287
|
## 🔗 Links
|
|
400
288
|
|
|
401
|
-
- **
|
|
402
|
-
- **
|
|
403
|
-
- **Documentation:** [
|
|
289
|
+
- **npm Package:** https://www.npmjs.com/package/fivosense
|
|
290
|
+
- **GitHub Repository:** https://github.com/thevinsoni/sense
|
|
291
|
+
- **Documentation:** [DOCUMENTATION.md](DOCUMENTATION.md)
|
|
292
|
+
- **Issues:** https://github.com/thevinsoni/sense/issues
|
|
404
293
|
|
|
405
294
|
---
|
|
406
295
|
|
|
407
|
-
##
|
|
408
|
-
|
|
409
|
-
We're working on:
|
|
410
|
-
- Python support (coming Q3 2026)
|
|
411
|
-
- More editor plugins (JetBrains, Sublime, etc.)
|
|
412
|
-
- Real-time protection (blocks bad code as you type)
|
|
413
|
-
- Team collaboration features
|
|
296
|
+
## 📈 Roadmap
|
|
414
297
|
|
|
415
|
-
|
|
298
|
+
- [ ] Python support
|
|
299
|
+
- [ ] Auto-fix mode
|
|
300
|
+
- [ ] JSON output format
|
|
301
|
+
- [ ] VS Code Marketplace
|
|
302
|
+
- [ ] More languages (Go, Rust, etc.)
|
|
303
|
+
- [ ] Live AI integration
|
|
304
|
+
- [ ] Web dashboard
|
|
416
305
|
|
|
417
306
|
---
|
|
418
307
|
|
|
419
|
-
##
|
|
308
|
+
## 💬 Support
|
|
420
309
|
|
|
421
|
-
|
|
310
|
+
**Questions?** Open a [discussion](https://github.com/thevinsoni/sense/discussions)
|
|
422
311
|
|
|
423
|
-
|
|
312
|
+
**Found a bug?** Open an [issue](https://github.com/thevinsoni/sense/issues)
|
|
424
313
|
|
|
425
314
|
---
|
|
426
315
|
|
|
427
|
-
##
|
|
316
|
+
## ⭐ Star Us!
|
|
428
317
|
|
|
429
|
-
|
|
430
|
-
- MIT, Stanford, CMU, UC Berkeley
|
|
431
|
-
- Anthropic, Meta, Cloudflare, Snyk
|
|
432
|
-
- 30+ computer science papers
|
|
433
|
-
- And developers like you who care about security
|
|
318
|
+
If FivoSense helped you, give us a star on GitHub! ⭐
|
|
434
319
|
|
|
435
320
|
---
|
|
436
321
|
|
|
437
|
-
**
|
|
438
|
-
|
|
439
|
-
**Stay safe out there.** 🛡️
|
|
440
|
-
|
|
441
|
-
---
|
|
322
|
+
**Made with ❤️ for secure coding**
|
|
442
323
|
|
|
443
|
-
|
|
324
|
+
Version: 0.1.4
|
|
325
|
+
Last Updated: June 26, 2026
|