T09 · Insecure Skill Coding Practices
- Location
scripts/scan.js:44- Finding
Unrestricted Fetching of Externally Controlled Article URLs Enables SSRF
- Content
View full analysis
{ const { data } = await axios.get(`https://hacker-news.firebaseio.com/v0/item/${id}.json`); return data; })); return stories .filter(s => s && KEYWORDS.some(k => s.title?.includes(k))) .slice(0, 3) .map(s => ({ source: "Hacker News", title: s.title, link: s.url || `https://news.ycombinator.com/item?id=${s.id}`, raw_summary: "Community discussion" })); } catch (e) { return []; } } ``` ```js for (const item of items) { console.log(`\nReading: ${item.title}...`); const content = await fetchContent(item.link); ``` Equivalent vulnerable behavior in `scripts/monitor.js`: ```js async function fetchContent(url) { try { const { data } = await axios.get(url, { headers: { 'User-Age ...[truncated 2796 chars]- Remediation
View remediation
