CVE-2023-34458: mx-chain-go's relayed transactions always increment nonce
7.1
CVSS Score
3.1
Basic Information
CVE ID
GHSA ID
EPSS Score
0.81308%
CWE
Published
7/13/2023
Updated
11/4/2023
KEV Status
No
Technology
Go
Technical Details
CVSS Vector
CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:L/A:H
| Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
|---|---|---|---|
| github.com/multiversx/mx-chain-go | go | < 1.4.17 | 1.4.17 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stemmed from the nonce increment logic in relayed transaction handling. The key vulnerable function was removeValueAndConsumedFeeFromUser which contained userAcnt.IncreaseNonce(1) without error checks. The commit diff shows this was modified to use shouldIncreaseNonce which adds error type checks. The processUserTx function was also involved as it triggered this logic. Pre-patch versions lacked the RelayedNonceFixEnableEpoch flag checks and error analysis demonstrated in the fixed code.