Malicious Code Vulnerability in @posthog/maxmind-plugin: Security Risk Identified
Summary
MAL-2025-190885: Malicious code in @posthog/maxmind-plugin (npm). Affects @posthog/maxmind-plugin versions 0.1.6. 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/maxmind-plugin is an npm package designed to integrate MaxMind's GeoIP services with PostHog, a product analytics platform. This plugin allows developers to enrich their analytics data with geographical information based on IP addresses. However, it has been identified to contain malicious code, posing significant security risks to applications that utilize it.
Vulnerability Detail
The vulnerability originates from the inclusion of malicious code within the @posthog/maxmind-plugin package. This code can potentially compromise the integrity of applications that depend on this plugin, leading to unauthorized access, data breaches, or other malicious activities. The specific version affected is 0.1.6, and it has been flagged by Amazon Inspector as a security threat.
How To Fix
This package is malicious. Remove it and rotate any credentials it could have accessed.
npm uninstall @posthog/maxmind-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 measure, you can remove the @posthog/maxmind-plugin from your project until a secure version is released. This can be done using the following command: npm uninstall @posthog/maxmind-plugin. Consider using alternative packages that provide similar functionality without the associated risks.
Conclusion
The @posthog/maxmind-plugin has been identified to contain malicious code, posing a significant risk to applications that utilize it. It is crucial for developers to update or remove the package to mitigate potential security threats. Utilizing tools like Vulert can help monitor and alert for such vulnerabilities in real-time.
See every vulnerability recorded for @posthog/maxmind-plugin →
FAQ
The malicious code is designed to exploit vulnerabilities in applications that use the plugin, potentially leading to unauthorized access or data breaches.
You can use Vulert, a tool that monitors and alerts for open-source vulnerabilities. By analyzing your package-lock.json file, it can identify if your application is affected. You can also check using the Vulert playground without any signup.
If an immediate update is not possible, consider removing the package from your project and using alternative solutions until a secure version is available.
Currently, version 0.1.6 of @posthog/maxmind-plugin is known to contain malicious code. Always check the official repository for the latest secure versions.
The vulnerability was reported by Amazon Inspector, which identified the malicious code in the package.