era-compiler-vyper First Immutable Variable Initialization vulnerability
era-compiler-vyper is the EraVM Vyper compiler for zkSync Era, a layer 2 rollup that uses zero-knowledge proofs to scale Ethereum. Prior to era-compiler-vype version 1.3.10, a bug prevented the initialization of the first immutable variable for Vyper contracts meeting certain criteria. The problem arises when there is a String or Array with more 256-bit words allocated than initialized. It results in the second word’s index unset, that is effectively set to 0, so the first immutable value with the actual 0 index is overwritten in the ImmutableSimulator. Version 1.3.10 fixes this issue by setting all indexes in advance. The problem will go away, but it will get more expensive if the user allocates a lot of uninitialized space, e.g. `String[4096]`. Upgrading and redeploying affected contracts is the only way of working around the issue.
- Products
- Not specified
- Affected versions
- Not specified
- Fixed versions
- Not specified
- CVEs
- CVE-2023-46232
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 3 Nov 2026, 15:57 UTC · Revision 1
Source evidence
era-compiler-vyper First Immutable Variable Initialization vulnerability
core-osv · Original sourcePublished 25 Oct 2023, 21:01 UTC
era-compiler-vyper is the EraVM Vyper compiler for zkSync Era, a layer 2 rollup that uses zero-knowledge proofs to scale Ethereum. Prior to era-compiler-vype version 1.3.10, a bug prevented the initialization of the first immutable variable for Vyper contracts meeting certain criteria. The problem arises when there is a String or Array with more 256-bit words allocated than initialized. It results in the second word’s index unset, that is effectively set to 0, so the first immutable value with the actual 0 index is overwritten in the ImmutableSimulator. Version 1.3.10 fixes this issue by setting all indexes in advance. The problem will go away, but it will get more expensive if the user allocates a lot of uninitialized space, e.g. `String[4096]`. Upgrading and redeploying affected contracts is the only way of working around the issue.
osv:CVE-2023-46232
Complete source record
{
"id": "0c8ecdb8636720b6f8c93c4c448324234debd1e0da895ac8760b58001b9f861c",
"url": "https://osv.dev/vulnerability/CVE-2023-46232",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "era-compiler-vyper First Immutable Variable Initialization vulnerability",
"summary": "era-compiler-vyper is the EraVM Vyper compiler for zkSync Era, a layer 2 rollup that uses zero-knowledge proofs to scale Ethereum. Prior to era-compiler-vype version 1.3.10, a bug prevented the initialization of the first immutable variable for Vyper contracts meeting certain criteria. The problem arises when there is a String or Array with more 256-bit words allocated than initialized. It results in the second word’s index unset, that is effectively set to 0, so the first immutable value with the actual 0 index is overwritten in the ImmutableSimulator. Version 1.3.10 fixes this issue by setting all indexes in advance. The problem will go away, but it will get more expensive if the user allocates a lot of uninitialized space, e.g. `String[4096]`. Upgrading and redeploying affected contracts is the only way of working around the issue.",
"evidence": "osv:CVE-2023-46232",
"products": [],
"severity": "medium",
"structured": {
"id": "CVE-2023-46232",
"aliases": [
"CVE-2023-46232",
"GHSA-h8jv-969m-94r4"
],
"metrics": [
{
"type": "CVSS_V3",
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N"
}
],
"affected": [
{
"ranges": [
{
"repo": "https://github.com/matter-labs/era-compiler-vyper",
"type": "GIT",
"events": [
{
"introduced": "0"
},
{
"fixed": "8be305a1b9c68d0fd47dad3434224ed85944ca25"
}
],
"database_specific": {
"extracted_events": [
{
"range": [
{
"fixed": "8be305a1b9c68d0fd47dad3434224ed85944ca25"
}
],
"source": "REFERENCES_COMMIT"
}
]
}
}
],
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2023-46232.json"
}
}
],
"modified": "2026-10-28T02:30:30.468863333Z",
"provider": "osv",
"references": [
"https://github.com/matter-labs/era-system-contracts/blob/main/contracts/ImmutableSimulator.sol#L37",
"https://github.com/CVEProject/cvelistV5/tree/main/cves/2023/46xxx/CVE-2023-46232.json",
"https://github.com/matter-labs/era-compiler-vyper/security/advisories/GHSA-h8jv-969m-94r4",
"https://nvd.nist.gov/vuln/detail/CVE-2023-46232",
"https://github.com/matter-labs/era-compiler-vyper/commit/8be305a1b9c68d0fd47dad3434224ed85944ca25"
],
"provider_metadata": {
"cwe_ids": [
"CWE-471"
],
"cna_assigner": "GitHub_M",
"unresolved_ranges": [
{
"extracted_events": [
{
"range": [
{
"fixed": "1.3.10"
}
],
"source": "AFFECTED_FIELD",
"strategy": "StringRangeExpression"
}
]
}
],
"osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2023/46xxx/CVE-2023-46232.json"
}
},
"related_cves": [
{
"value": "CVE-2023-46232",
"evidence": "/id"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 497073,
"published_at": "2023-10-25T21:01:51.692+00:00"
}