Bitter APT – Active IOCs
June 4, 2025CVE-2025-5495 – NETGEAR WNR614 Firmware Vulnerability
June 4, 2025Bitter APT – Active IOCs
June 4, 2025CVE-2025-5495 – NETGEAR WNR614 Firmware Vulnerability
June 4, 2025Severity
High
Analysis Summary
A new security study has uncovered a serious vulnerability that affects more than 1,700 open-source GitHub projects. This vulnerability is known as a "path traversal" flaw (CWE-22). It occurs when developers use user input in file paths without checking or cleaning it properly. The issue is mostly found in Node.js applications that serve static files (like images or documents) over HTTP using a pattern like path.join() combined with data from the URL.
Attackers can exploit this flaw by inserting directory traversal sequences such as ../ in the URL, allowing them to access sensitive files outside the allowed folders, like system files or confidential data. This puts the confidentiality and security of applications and user data at risk.
What’s concerning is how this insecure coding pattern has spread so widely. It first showed up around 2010 and became popular through GitHub Gists, Stack Overflow answers, blog posts, and even coding tutorials. Many developers reused the same code, assuming it was safe because standard tools like browsers automatically normalize URLs, hiding the actual risk during testing.
Researchers created an automated tool to scan GitHub for this flaw. It checked whether the vulnerable code could actually be exploited, assessed how severe it was (using CVSS scores), and even used GPT-4 to suggest patches. They then reported these flaws to project maintainers. So far, 14% of the vulnerabilities have been fixed. Interestingly, well-known projects were more likely to fix the problem than lesser-known ones.
Another major concern is that many AI models used for code generation have "learned" this bad coding habit. When asked to create static file servers, 95% of the AI-generated code samples included the same vulnerability, and even when told to make them “secure,” 70% were still flawed. This shows that insecure code is spreading not just through people but through AI as well.
The study highlights how dangerous it can be when insecure code gets reused without understanding the risks. It also shows the need for stronger code reviews, automated security tools, and teaching developers to write safer code from the start.
Impact
- Data Exfiltration
- Sensitive Data Theft
- Gain Access
Remediation
- Sanitize user input to remove directory traversal patterns like "../".
- Validate and normalize file paths before accessing the file system.
- Avoid directly using user-supplied input in path.join or similar functions.
- Restrict file access to a specific directory using allowlists.
- Regularly update project dependencies and monitor security advisories.
- Use static code analysis tools to detect insecure code patterns.
- Educate developers about secure coding practices.
- Manually review AI-generated code for security issues.
- Apply security patches and fixes as soon as they are available.
- Implement automated security testing in the development pipeline.