{"id":"CVE-2022-35915","aliases":["EUVD-2022-6503","GHSA-7grf-83vw-6f5x"],"status":"published","title":"Unbounded gas consumption in @openzeppelin/contracts","description":"OpenZeppelin Contracts is a library for secure smart contract development. The target contract of an EIP-165 `supportsInterface` query can cause unbounded gas consumption by returning a lot of data, while it is generally assumed that this operation has a bounded cost. The issue has been fixed in v4.7.2. Users are advised to upgrade. There are no known workarounds for this issue.","severity":{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"medium","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-11","score":0.00799,"percentile":0.56994,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-400","CWE-770"],"published":"2022-08-01T21:05:11Z","modified":"2026-10-28T02:30:30Z","fixes":[{"ecosystem":"npm","package":"@openzeppelin/contracts","fixed_in":["4.7.2"],"sources":["ghsa","osv"]},{"ecosystem":"npm","package":"@openzeppelin/contracts-upgradeable","fixed_in":["4.7.2"],"sources":["ghsa","osv"]}],"affected":[{"source":"ghsa","ecosystem":"npm","package":"@openzeppelin/contracts","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"2.0.0"},{"fixed":"4.7.2"}]}]},{"source":"ghsa","ecosystem":"npm","package":"openzeppelin-solidity","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"2.0.0"},{"last_affected":"4.6.0"}]}]},{"source":"ghsa","ecosystem":"npm","package":"@openzeppelin/contracts-upgradeable","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"3.2.0"},{"fixed":"4.7.2"}]}]},{"source":"ghsa","ecosystem":"npm","package":"openzeppelin-eth","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"2.0.0"},{"last_affected":"2.2.0"}]}]},{"source":"osv","ecosystem":"npm","package":"@openzeppelin/contracts","ranges":[{"type":"SEMVER","events":[{"introduced":"2.0.0"},{"fixed":"4.7.2"}]}]},{"source":"osv","ecosystem":"npm","package":"openzeppelin-solidity","ranges":[{"type":"SEMVER","events":[{"introduced":"2.0.0"},{"last_affected":"4.6.0"}]}]},{"source":"osv","ecosystem":"npm","package":"@openzeppelin/contracts-upgradeable","ranges":[{"type":"SEMVER","events":[{"introduced":"3.2.0"},{"fixed":"4.7.2"}]}]},{"source":"osv","ecosystem":"npm","package":"openzeppelin-eth","ranges":[{"type":"SEMVER","events":[{"introduced":"2.0.0"},{"last_affected":"2.2.0"}]}]}],"products":[{"vendor":"openzeppelin","product":"contracts"},{"vendor":"openzeppelin","product":"contracts_upgradeable"},{"vendor":"openzeppelin","product":"openzeppelin-contracts"},{"vendor":"openzeppelin","product":"openzeppelin-eth"},{"vendor":"openzeppelin","product":"openzeppelin-solidity"}],"references":[{"url":"https://github.com/OpenZeppelin/openzeppelin-contracts/security/advisories/GHSA-7grf-83vw-6f5x","tags":["x_refsource_CONFIRM","x_transferred","Third Party Advisory","advisory","web"]},{"url":"https://github.com/OpenZeppelin/openzeppelin-contracts/pull/3587","tags":["x_refsource_MISC","x_transferred","Patch","Third Party Advisory","fix","web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-35915","tags":["advisory"]},{"url":"https://github.com/OpenZeppelin/openzeppelin-contracts/releases/tag/v4.7.2","tags":["web"]},{"url":"https://github.com/advisories/GHSA-7grf-83vw-6f5x"},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2022/35xxx/CVE-2022-35915.json","tags":["advisory"]},{"url":"https://github.com/OpenZeppelin/openzeppelin-contracts","tags":["package"]}],"sources":{"cve":[{"id":"CVE-2022-35915","title":"Unbounded gas consumption in @openzeppelin/contracts","description":"OpenZeppelin Contracts is a library for secure smart contract development. The target contract of an EIP-165 `supportsInterface` query can cause unbounded gas consumption by returning a lot of data, while it is generally assumed that this operation has a bounded cost. The issue has been fixed in v4.7.2. Users are advised to upgrade. There are no known workarounds for this issue.","status":"published","published":"2022-08-01T21:05:11Z","modified":"2025-04-23T17:54:51.563Z","cvss":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"medium","assessor":"cna"}],"cwes":["CWE-400"],"updated_at":"2026-11-02T14:34:40.275153Z"}],"euvd":[{"id":"EUVD-2022-6503","description":"OpenZeppelin Contracts is a library for secure smart contract development. The target contract of an EIP-165 `supportsInterface` query can cause unbounded gas consumption by returning a lot of data, while it is generally assumed that this operation has a bounded cost. The issue has been fixed in v4.7.2. Users are advised to upgrade. There are no known workarounds for this issue.","status":"published","published":"2022-08-01T21:05:11Z","modified":"2025-04-23T17:54:51Z","cvss":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"medium"}],"updated_at":"2026-11-02T20:52:10.363195Z"}],"ghsa":[{"id":"GHSA-7grf-83vw-6f5x","title":"OpenZeppelin Contracts ERC165Checker unbounded gas consumption","description":"### Impact\n\nThe target contract of an EIP-165 `supportsInterface` query can cause unbounded gas consumption by returning a lot of data, while it is generally assumed that this operation has a bounded cost.\n\n### Patches\n\nThe issue has been fixed in v4.7.2.\n\n### References\n\nhttps://github.com/OpenZeppelin/openzeppelin-contracts/pull/3587\n\n### For more information\n\nIf you have any questions or comments about this advisory, or need assistance deploying a fix, email us at [security@openzeppelin.com](mailto:security@openzeppelin.com).","status":"published","published":"2022-08-14T00:23:34Z","modified":"2023-07-21T21:32:44Z","cvss":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"medium"}],"cwes":["CWE-400","CWE-770"],"updated_at":"2026-11-02T14:36:58.177785Z"}],"nvd":[{"id":"CVE-2022-35915","description":"OpenZeppelin Contracts is a library for secure smart contract development. The target contract of an EIP-165 `supportsInterface` query can cause unbounded gas consumption by returning a lot of data, while it is generally assumed that this operation has a bounded cost. The issue has been fixed in v4.7.2. Users are advised to upgrade. There are no known workarounds for this issue.","status":"published","published":"2022-08-01T21:15:13.687Z","modified":"2026-06-17T04:52:30.757Z","cvss":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"medium","assessor":"secondary"},{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"medium","assessor":"primary"}],"cwes":["CWE-400","CWE-770"],"updated_at":"2026-11-02T14:07:24.39467Z"}],"osv":[{"id":"CVE-2022-35915","title":"Unbounded gas consumption in @openzeppelin/contracts","description":"OpenZeppelin Contracts is a library for secure smart contract development. The target contract of an EIP-165 `supportsInterface` query can cause unbounded gas consumption by returning a lot of data, while it is generally assumed that this operation has a bounded cost. The issue has been fixed in v4.7.2. Users are advised to upgrade. There are no known workarounds for this issue.","status":"published","published":"2022-08-01T21:05:11Z","modified":"2026-10-28T02:30:30.45910211Z","cvss":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"medium"}],"cwes":["CWE-400"],"updated_at":"2026-11-02T15:44:26.195407Z"},{"id":"GHSA-7grf-83vw-6f5x","title":"OpenZeppelin Contracts ERC165Checker unbounded gas consumption","description":"### Impact\n\nThe target contract of an EIP-165 `supportsInterface` query can cause unbounded gas consumption by returning a lot of data, while it is generally assumed that this operation has a bounded cost.\n\n### Patches\n\nThe issue has been fixed in v4.7.2.\n\n### References\n\nhttps://github.com/OpenZeppelin/openzeppelin-contracts/pull/3587\n\n### For more information\n\nIf you have any questions or comments about this advisory, or need assistance deploying a fix, email us at [security@openzeppelin.com](mailto:security@openzeppelin.com).","status":"published","published":"2022-08-14T00:23:34Z","modified":"2023-11-08T04:09:52.370855Z","cvss":[{"version":"3.1","score":5.3,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L","level":"medium"}],"cwes":["CWE-400","CWE-770"],"updated_at":"2026-11-02T15:46:41.002603Z"}]}}
