ubuntu-cve-2024-45056
Vulnerability from osv_ubuntu
Published
2024-08-29 17:15
Modified
2024-08-29 17:15
Summary
Details
zksolc is a Solidity compiler for ZKsync. All LLVM versions since 2015 fold (xor (shl 1, x), -1) to (rotl ~1, x) if run with optimizations enabled. Here ~1 is generated as an unsigned 64 bits number (2^64-1). This number is zero-extended to 256 bits on EraVM target while it should have been sign-extended. Thus instead of producing roti 2^256 - 1, x the compiler produces rotl 2^64 - 1, x. Analysis has shown that no contracts were affected by the date of publishing this advisory. This issue has been addressed in version 1.5.3. Users are advised to upgrade and redeploy all contracts. There are no known workarounds for this vulnerability.
Severity
5.9 (Medium)
References
{
"affected": [
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:14.04:LTS",
"name": "llvm-toolchain-3.6"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:3.6-2ubuntu1~trusty1",
"1:3.6-2ubuntu1~trusty2"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:14.04:LTS",
"name": "llvm-toolchain-3.8"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:3.8-2ubuntu3~trusty4",
"1:3.8-2ubuntu3~trusty5"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:14.04:LTS",
"name": "llvm-toolchain-3.9"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:3.9.1-4ubuntu3~14.04.2",
"1:3.9.1-4ubuntu3~14.04.3"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:16.04:LTS",
"name": "llvm-toolchain-3.6"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:3.6.2-1",
"1:3.6.2-3",
"1:3.6.2-3build1",
"1:3.6.2-3ubuntu1",
"1:3.6.2-3ubuntu2"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:16.04:LTS",
"name": "llvm-toolchain-3.8"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:3.8~+rc1-1~exp1ubuntu3",
"1:3.8~+rc2-1~exp1ubuntu2",
"1:3.8-2ubuntu1",
"1:3.8-2ubuntu3",
"1:3.8-2ubuntu4"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:16.04:LTS",
"name": "llvm-toolchain-4.0"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:4.0-1ubuntu1~16.04.1",
"1:4.0-1ubuntu1~16.04.2"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:16.04:LTS",
"name": "llvm-toolchain-5.0"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:5.0-3~16.04.1"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:16.04:LTS",
"name": "llvm-toolchain-6.0"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:6.0-1ubuntu2~16.04.1"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:16.04:LTS",
"name": "llvm-toolchain-3.5"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:3.5.2-2",
"1:3.5.2-3",
"1:3.5.2-3build1",
"1:3.5.2-3build2",
"1:3.5.2-3ubuntu1"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:16.04:LTS",
"name": "llvm-toolchain-3.7"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:3.7-2ubuntu1",
"1:3.7-2ubuntu2",
"1:3.7-4ubuntu1",
"1:3.7.1-1ubuntu1",
"1:3.7.1-1ubuntu2",
"1:3.7.1-1ubuntu3",
"1:3.7.1-1ubuntu4",
"1:3.7.1-2ubuntu1",
"1:3.7.1-2ubuntu2"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:16.04:LTS",
"name": "llvm-toolchain-3.9"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:3.9.1-4ubuntu3~16.04.1",
"1:3.9.1-4ubuntu3~16.04.2"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:16.04:LTS",
"name": "llvm-toolchain-8"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:8-3~ubuntu16.04.1"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:18.04:LTS",
"name": "llvm-toolchain-10"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:10.0.0-4ubuntu1~18.04.1",
"1:10.0.0-4ubuntu1~18.04.2"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:18.04:LTS",
"name": "llvm-toolchain-3.9"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:3.9.1-17ubuntu1",
"1:3.9.1-18ubuntu1",
"1:3.9.1-19ubuntu1"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:18.04:LTS",
"name": "llvm-toolchain-6.0"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:6.0~+rc1-1",
"1:6.0~+rc2-1",
"1:6.0-1ubuntu1",
"1:6.0-1ubuntu2"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:18.04:LTS",
"name": "llvm-toolchain-7"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:7-3~ubuntu0.18.04.1"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:18.04:LTS",
"name": "llvm-toolchain-8"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:8-3~ubuntu18.04.1",
"1:8-3~ubuntu18.04.2"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:18.04:LTS",
"name": "llvm-toolchain-9"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:9-2~ubuntu18.04.1",
"1:9-2~ubuntu18.04.2"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:18.04:LTS",
"name": "llvm-toolchain-3.7"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:3.7.1-5ubuntu3"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:18.04:LTS",
"name": "llvm-toolchain-4.0"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:4.0.1-6",
"1:4.0.1-8",
"1:4.0.1-10"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:Pro:18.04:LTS",
"name": "llvm-toolchain-5.0"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:5.0-3",
"1:5.0-4",
"1:5.0.1-1",
"1:5.0.1-2",
"1:5.0.1-4"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:20.04:LTS",
"name": "llvm-toolchain-10"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:10~++20200121023453+de4b2a7fad6-1~exp1",
"1:10.0.0~+rc1-1~exp1",
"1:10.0.0~+rc2-2~build2",
"1:10.0.0~+rc2-2",
"1:10.0.0~+rc3-1",
"1:10.0.0~+rc3-1build1",
"1:10.0.0~+rc4-1",
"1:10.0.0~+rc5-1ubuntu1",
"1:10.0.0-1ubuntu1",
"1:10.0.0-1ubuntu2",
"1:10.0.0-2ubuntu1",
"1:10.0.0-2ubuntu2",
"1:10.0.0-3",
"1:10.0.0-4ubuntu1"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:20.04:LTS",
"name": "llvm-toolchain-11"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:11.0.0-2~ubuntu20.04.1"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:20.04:LTS",
"name": "llvm-toolchain-12"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:12.0.0-3ubuntu1~20.04.3",
"1:12.0.0-3ubuntu1~20.04.4",
"1:12.0.0-3ubuntu1~20.04.5"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:20.04:LTS",
"name": "llvm-toolchain-6.0"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:6.0.1-11",
"1:6.0.1-11ubuntu1",
"1:6.0.1-12",
"1:6.0.1-14"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:20.04:LTS",
"name": "llvm-toolchain-7"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:7.0.1-9build1",
"1:7.0.1-9ubuntu2",
"1:7.0.1-10",
"1:7.0.1-10build1",
"1:7.0.1-12"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:20.04:LTS",
"name": "llvm-toolchain-8"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:8.0.1-3build1",
"1:8.0.1-4",
"1:8.0.1-4ubuntu3",
"1:8.0.1-7build1",
"1:8.0.1-7ubuntu1",
"1:8.0.1-8ubuntu1",
"1:8.0.1-9"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:20.04:LTS",
"name": "llvm-toolchain-9"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:9-2",
"1:9.0.0-3ubuntu2",
"1:9.0.0-4ubuntu4",
"1:9.0.1~+rc2-1~exp1",
"1:9.0.1~+rc2-1~exp1ubuntu1",
"1:9.0.1-1",
"1:9.0.1-2",
"1:9.0.1-6build1",
"1:9.0.1-8build1",
"1:9.0.1-8ubuntu1",
"1:9.0.1-9ubuntu1",
"1:9.0.1-10",
"1:9.0.1-11",
"1:9.0.1-11ubuntu1",
"1:9.0.1-12"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:22.04:LTS",
"name": "llvm-toolchain-11"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:11.0.1-2ubuntu5",
"1:11.1.0-6"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:22.04:LTS",
"name": "llvm-toolchain-12"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:12.0.1-8build1",
"1:12.0.1-16",
"1:12.0.1-19ubuntu3"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:22.04:LTS",
"name": "llvm-toolchain-13"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:13.0.0-2",
"1:13.0.0-9",
"1:13.0.1-2ubuntu1",
"1:13.0.1-2ubuntu2",
"1:13.0.1-2ubuntu2.1",
"1:13.0.1-2ubuntu2.2"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:22.04:LTS",
"name": "llvm-toolchain-14"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:14.0.0~+rc1-1",
"1:14.0.0~+rc1-1ubuntu4",
"1:14.0.0~+rc4-1ubuntu1",
"1:14.0.0-1ubuntu1",
"1:14.0.0-1ubuntu1.1"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:22.04:LTS",
"name": "llvm-toolchain-15"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:15.0.6-3~ubuntu0.22.04.2",
"1:15.0.7-0ubuntu0.22.04.1",
"1:15.0.7-0ubuntu0.22.04.2",
"1:15.0.7-0ubuntu0.22.04.3"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:24.04:LTS",
"name": "llvm-toolchain-14"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:14.0.6-16",
"1:14.0.6-16build1",
"1:14.0.6-16build2",
"1:14.0.6-19build2",
"1:14.0.6-19build4"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:24.04:LTS",
"name": "llvm-toolchain-15"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:15.0.7-10",
"1:15.0.7-10build1",
"1:15.0.7-10build2",
"1:15.0.7-10ubuntu1",
"1:15.0.7-11",
"1:15.0.7-14build1",
"1:15.0.7-14build3"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:24.04:LTS",
"name": "llvm-toolchain-16"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:16.0.6-15",
"1:16.0.6-18",
"1:16.0.6-19",
"1:16.0.6-19build1",
"1:16.0.6-20",
"1:16.0.6-23ubuntu1",
"1:16.0.6-23ubuntu3",
"1:16.0.6-23ubuntu4"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:24.04:LTS",
"name": "llvm-toolchain-17"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:17.0.2-1~exp1ubuntu2.1",
"1:17.0.5-1ubuntu1",
"1:17.0.5-1ubuntu2",
"1:17.0.6-2",
"1:17.0.6-3",
"1:17.0.6-5build1",
"1:17.0.6-9build2",
"1:17.0.6-9build3",
"1:17.0.6-9ubuntu1"
]
},
{
"ecosystem_specific": {
"ubuntu_priority": "medium"
},
"package": {
"ecosystem": "Ubuntu:24.04:LTS",
"name": "llvm-toolchain-18"
},
"ranges": [
{
"events": [
{
"introduced": "0"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"1:18.1.0~rc1-1",
"1:18.1.0~rc2-3",
"1:18.1.0~rc2-4",
"1:18.1.0~++20240126095841+0991d3c7b53d-1~exp1",
"1:18.1.2-1ubuntu2",
"1:18.1.2-1ubuntu3",
"1:18.1.3-1",
"1:18.1.3-1ubuntu1"
]
}
],
"aliases": [],
"details": "zksolc is a Solidity compiler for ZKsync. All LLVM versions since 2015 fold `(xor (shl 1, x), -1)` to `(rotl ~1, x)` if run with optimizations enabled. Here `~1` is generated as an unsigned 64 bits number (`2^64-1`). This number is zero-extended to 256 bits on EraVM target while it should have been sign-extended. Thus instead of producing `roti 2^256 - 1, x` the compiler produces `rotl 2^64 - 1, x`. Analysis has shown that no contracts were affected by the date of publishing this advisory. This issue has been addressed in version 1.5.3. Users are advised to upgrade and redeploy all contracts. There are no known workarounds for this vulnerability.",
"id": "UBUNTU-CVE-2024-45056",
"modified": "2024-08-29T17:15:00Z",
"published": "2024-08-29T17:15:00Z",
"references": [
{
"type": "REPORT",
"url": "https://ubuntu.com/security/CVE-2024-45056"
},
{
"type": "REPORT",
"url": "https://www.cve.org/CVERecord?id=CVE-2024-45056"
},
{
"type": "REPORT",
"url": "https://github.com/matter-labs/era-compiler-solidity/security/advisories/GHSA-fpx7-8vc6-frjj"
},
{
"type": "REPORT",
"url": "https://github.com/llvm/llvm-project/commit/e48237df95b49a36b8ffceb78c8a58f4be1b4344"
}
],
"related": [
"CVE-2024-45056"
],
"schema_version": "1.6.3",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N",
"type": "CVSS_V3"
}
],
"withdrawn": "2025-06-23T15:59:04Z"
}
Loading…
Loading…
Experimental. This forecast is provided for visualization only and may change without notice. Do not use it for operational decisions.
Forecast uses a logistic model when the trend is rising, or an exponential decay model when the trend is falling. Fitted via linearized least squares.
Sightings
| Author | Source | Type | Date | Other |
|---|
Nomenclature
- Seen: The vulnerability was mentioned, discussed, or observed by the user.
- Confirmed: The vulnerability has been validated from an analyst's perspective.
- Published Proof of Concept: A public proof of concept is available for this vulnerability.
- Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
- Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
- Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
- Not confirmed: The user expressed doubt about the validity of the vulnerability.
- Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.
Loading…
Loading…