wormclaude 1.0.168 → 1.0.170
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/commands.js +2 -2
- package/dist/theme.js +1 -1
- package/dist/tools.js +12 -0
- package/package.json +1 -1
package/dist/commands.js
CHANGED
|
@@ -172,7 +172,7 @@ const _REMED = {
|
|
|
172
172
|
'open-redirect': { t: 'Açık Yönlendirme', cwe: 'CWE-601', impact: 'Oltalama/phishing — kullanıcı güvenilen alandan kötücül siteye yönlenir.', fix: 'Yönlendirme hedefini allowlist’le; harici URL’e doğrudan yönlendirme yapma.' },
|
|
173
173
|
crlf: { t: 'CRLF / HTTP Başlık Enjeksiyonu', cwe: 'CWE-113', impact: 'Başlık enjeksiyonu, önbellek zehirleme, oturum sabitleme.', fix: 'Yanıt başlığına giren girdiden CR/LF (%0d%0a) temizle.' },
|
|
174
174
|
'graphql-introspection': { t: 'GraphQL Introspection Açık', cwe: 'CWE-200', impact: 'Tüm API şeması/gizli uçlar ifşa → saldırı yüzeyi haritalanır.', fix: 'Üretimde introspection’ı kapat; şema ifşasını sınırla.' },
|
|
175
|
-
path: { t: '
|
|
175
|
+
path: { t: 'Keşfedilen uç/dosya', cwe: '', impact: 'Erişilebilir bir uç bulundu; içerik hassas değilse risk DÜŞÜKTÜR (robots.txt/sitemap/login normaldir, 403 = korumalı).', fix: 'Beklenmeyen/hassas yolları kaldır ya da erişimi kısıtla.' },
|
|
176
176
|
weak_headers: { t: 'Eksik Güvenlik Başlıkları', cwe: 'CWE-693', impact: 'Clickjacking/MIME-sniffing/MITM riskini artırır.', fix: 'CSP, HSTS, X-Frame-Options, X-Content-Type-Options, Referrer-Policy ekle.' },
|
|
177
177
|
cors: { t: 'CORS Yanlış Yapılandırması', cwe: 'CWE-942', impact: 'Kötücül site kullanıcı adına yetkili istek yapabilir, veri çalar.', fix: 'Origin’i allowlist’le; ACAO:* + credentials birlikte kullanma.' },
|
|
178
178
|
exposure: { t: 'Hassas Dosya İfşası', cwe: 'CWE-538', impact: 'Sır/yapılandırma sızması (.git/.env/yedek).', fix: 'Dosyaları web kökünden kaldır; erişimi engelle; sızan sırları rotate et.' },
|
|
@@ -210,7 +210,7 @@ export function buildReport(scan) {
|
|
|
210
210
|
out.push(`- **${L ? 'Kanıt' : 'Evidence'}:** ${f.evidence}`);
|
|
211
211
|
else if (f.missing)
|
|
212
212
|
out.push(`- **${L ? 'Eksik' : 'Missing'}:** ${(f.missing || []).join(', ')}`);
|
|
213
|
-
if (r) {
|
|
213
|
+
if (r && f.severity !== 'info') { // info bulgularda alarm-etkisi/çözüm gösterme (gürültü)
|
|
214
214
|
out.push(`- **${L ? 'Etki' : 'Impact'}:** ${r.impact}`);
|
|
215
215
|
out.push(`- **${L ? 'Çözüm' : 'Remediation'}:** ${r.fix}`);
|
|
216
216
|
}
|
package/dist/theme.js
CHANGED
package/dist/tools.js
CHANGED
|
@@ -47,6 +47,10 @@ function _cmdTimeout(cmd, explicit) {
|
|
|
47
47
|
let bashCwd;
|
|
48
48
|
export function getBashCwd() { return bashCwd || process.cwd(); }
|
|
49
49
|
export function setBashCwd(dir) { bashCwd = dir; }
|
|
50
|
+
// SecurityScan döngü-kırıcı: model mevcut bulguları "açıklarken" aynı taramayı tekrar tekrar
|
|
51
|
+
// çağırıp döngüye giriyordu. Aynı (tool,target) 2 dk içinde tekrar gelirse YENİDEN tarama yok —
|
|
52
|
+
// önceki sonucu + "yeniden tarama, bulgularla yanıtla" notunu dön.
|
|
53
|
+
const _scanCache = new Map();
|
|
50
54
|
// Göreli dosya yollarını AKTİF workspace'e (bashCwd) çözer; mutlak yol aynen kalır.
|
|
51
55
|
// Böylece model "index.html" gibi göreli yol verse bile dosya bilinen klasöre yazılır.
|
|
52
56
|
export function resolveWs(fp) {
|
|
@@ -733,6 +737,13 @@ async function execOne(call, hooks) {
|
|
|
733
737
|
}
|
|
734
738
|
if (tool === 'scan')
|
|
735
739
|
tool = 'recon'; // "scan" genel tarama → motorun bildiği "recon" (slash ile aynı)
|
|
740
|
+
// DÖNGÜ-KIRICI: aynı tarama 2 dk içinde tekrar → yeniden koşma, önceki sonuç + "yeniden tarama" notu.
|
|
741
|
+
const _ck = tool + '|' + target.toLowerCase();
|
|
742
|
+
const _cached = _scanCache.get(_ck);
|
|
743
|
+
if (_cached && Date.now() - _cached.t < 120000) {
|
|
744
|
+
return { ok: true, args, output: _cached.out
|
|
745
|
+
+ '\n\n[ALREADY-SCANNED] This exact scan just ran — results above. Do NOT scan again. Answer the user from these findings (explain / prioritize / translate / show fixes). Re-scanning is a loop.' };
|
|
746
|
+
}
|
|
736
747
|
try {
|
|
737
748
|
const { runPentest } = await import('./pentest.js');
|
|
738
749
|
const out = await runPentest(cfg(), tool, target, true, () => { });
|
|
@@ -754,6 +765,7 @@ async function execOne(call, hooks) {
|
|
|
754
765
|
+ ` the user to run the deterministic command "/fullscan ${target}" — it chains recon + XSS + SQLi`
|
|
755
766
|
+ ` in one reliable, repeatable pass. Do NOT hand-orchestrate nmap/sqlmap yourself; recommend`
|
|
756
767
|
+ ` /fullscan. Pair it with the authorization reminder (only on owned / written-authorized targets).`;
|
|
768
|
+
_scanCache.set(_ck, { out: txt, t: Date.now() }); // döngü-kırıcı için sakla
|
|
757
769
|
return { ok: true, output: txt, args };
|
|
758
770
|
}
|
|
759
771
|
catch (e) {
|