Malicious Code Detected in @posthog/url-normalizer-plugin: Security Alert
Summary
MAL-2025-190897: Malicious code in @posthog/url-normalizer-plugin (npm). Affects @posthog/url-normalizer-plugin versions 0.0.8. No fix is published. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
The @posthog/url-normalizer-plugin is an npm package designed to normalize URLs for analytics purposes. It is utilized by developers to ensure consistency in URL formats, which aids in accurate data tracking and reporting. However, this package has been compromised, leading to the introduction of malicious code that poses significant security risks to applications relying on it.
Vulnerability Detail
The vulnerability stems from the discovery of malicious code within the @posthog/url-normalizer-plugin package, specifically version 0.0.8. This malicious code could potentially allow attackers to execute harmful actions within the context of applications that utilize this package. The origin of this vulnerability has been traced back to a report by Amazon Inspector, which flagged the package for containing harmful elements that could compromise user data and application integrity.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall @posthog/url-normalizer-plugin
If it arrived as a transitive dependency, remove the package that pulled it in, then reinstall.
Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →
Workaround
As a temporary workaround, consider removing the @posthog/url-normalizer-plugin from your project until a secure version is released. You can do this by running: npm uninstall @posthog/url-normalizer-plugin. This will prevent any potential exploitation of the malicious code while you await a fix.
Conclusion
The @posthog/url-normalizer-plugin has been flagged for containing malicious code, posing a serious risk to applications that utilize it. It is essential to update or remove the package to safeguard your application from potential threats. Continuous monitoring using tools like Vulert can help maintain the security of your software.
See every vulnerability recorded for @posthog/url-normalizer-plugin →
FAQ
The malicious code could allow unauthorized access or manipulation of application data, posing a significant security threat.
You can use Vulert, which monitors and alerts for open-source vulnerabilities in real-time. Visit Vulert Scanner to check if your application is affected.
If immediate updates are not possible, consider removing the package as a temporary measure to mitigate risks.
Yes, using tools like Vulert allows you to monitor your project's dependencies for vulnerabilities without needing to access the code directly.
Detailed information can be found in the vulnerability report provided by Amazon Inspector, which outlines the specifics of the malicious code.