{"id":"GHSA-cjg2-2fjg-fph4","summary":"Integer underflow in Frontier","details":"### Impact\n\nA bug in Frontier's MODEXP precompile implementation can cause an integer underflow in certain conditions. This will cause a node crash for debug builds. For release builds (and production WebAssembly binaries), the impact is limited as it can only cause a normal EVM out-of-gas. It is recommended that you apply the patch as soon as possible.\n\nIf you do not use MODEXP precompile in your runtime, then you are not impacted.\n\n### Patches\n\nPatches are applied in PR #549.\n\n### Workarounds\n\nNone.\n\n### References\n\nPatch PR: #549\n\n### Credits\n\nThanks to SR-Labs for discovering the security vulnerability, and thanks to PureStake team for the patches.\n\n### For more information\n\nIf you have any questions or comments about this advisory:\n* Open an issue in the [Frontier repo](https://github.com/paritytech/frontier)\n","aliases":["CVE-2022-21685"],"modified":"2024-10-24T21:50:43Z","published":"2022-01-14T21:03:36Z","database_specific":{"cwe_ids":["CWE-191"],"severity":"MODERATE","github_reviewed":true,"github_reviewed_at":"2022-01-14T19:58:51Z","nvd_published_at":"2022-01-14T17:15:00Z"},"references":[{"type":"WEB","url":"https://github.com/paritytech/frontier/security/advisories/GHSA-cjg2-2fjg-fph4"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-21685"},{"type":"WEB","url":"https://github.com/paritytech/frontier/pull/549"},{"type":"WEB","url":"https://github.com/paritytech/frontier/commit/8a93fdc6c9f4eb1d2f2a11b7ff1d12d70bf5a664"},{"type":"PACKAGE","url":"https://github.com/paritytech/frontier"}],"affected":[{"package":{"name":"pallet-evm-precompile-modexp","ecosystem":"crates.io","purl":"pkg:cargo/pallet-evm-precompile-modexp"},"ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"last_affected":"1.0.0"}]}],"database_specific":{"source":"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2022/01/GHSA-cjg2-2fjg-fph4/GHSA-cjg2-2fjg-fph4.json"}}],"schema_version":"1.9.0"}