Malicious Code Detected in hardhat-gas-tracker: Version 1.0.1 Compromised

hardhat-gas-tracker Updated 23 Jul 2026

Summary

22/07/2026
CRITICAL
No i
Critical
Not published

MAL-2026-11020: Malicious code in hardhat-gas-tracker (npm). Affects hardhat-gas-tracker versions 1.0.1. No fix is published. How to fix ↓

Free scan

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.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

hardhat-gas-tracker is an npm package designed to track gas usage in Ethereum smart contracts, providing developers with insights into transaction costs and optimization opportunities. This package is widely used in the Ethereum development community for its utility in managing gas fees effectively. However, version 1.0.1 has been flagged for containing malicious code that compromises its integrity and user security.

Vulnerability Detail

The vulnerability in hardhat-gas-tracker stems from its communication with a domain associated with malicious activities. This connection poses significant risks, including data theft, unauthorized access to sensitive information, and potential exploitation of the user's environment. The malicious nature of the package was identified by the OpenSSF Package Analysis project, which highlighted the dangers of using this compromised version.

How To Fix

This package is malicious. Remove it and rotate any credentials it could have accessed.

npm uninstall hardhat-gas-tracker

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

If you cannot immediately update the package, consider temporarily removing it from your project or replacing it with an alternative gas tracking solution until a secure version is available.

Conclusion

The hardhat-gas-tracker package version 1.0.1 has been identified as malicious due to its communication with harmful domains. It is essential for developers using this package to update to a secure version promptly to protect their applications and data. Utilizing tools like Vulert can further enhance security by monitoring for vulnerabilities in real-time.

See every vulnerability recorded for hardhat-gas-tracker →

Share this vulnerability

FAQ

hardhat-gas-tracker is an npm package used for tracking gas usage in Ethereum smart contracts, helping developers optimize transaction costs.

Version 1.0.1 communicates with a domain linked to malicious activities, posing risks to user data and security.

You can use Vulert's playground at Vulert Scanner to check if your application is affected by this vulnerability without needing to sign up.

Consider removing the package from your project or using an alternative solution until a secure version is available.

Vulert monitors and alerts for open-source vulnerabilities in your software using just the package-lock.json file, providing real-time insights.

How To Fix

This package is malicious. Remove it and rotate any credentials it could have accessed.

npm uninstall hardhat-gas-tracker

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 →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback