Shallow copy bug in geth
Moderate severity
GitHub Reviewed
Published
Nov 24, 2020
in
ethereum/go-ethereum
•
Updated Oct 3, 2023
Package
Affected versions
>= 1.9.7, < 1.9.17
Patched versions
1.9.17
Description
Reviewed
May 21, 2021
Published to the GitHub Advisory Database
Jun 29, 2021
Last updated
Oct 3, 2023
Impact
This is a Consensus vulnerability, which can be used to cause a chain-split where vulnerable nodes reject the canonical chain.
Geth’s pre-compiled
dataCopy
(at0x00...04
) contract did a shallow copy on invocation. An attacker could deploy a contract thatX
to an EVM memory regionR
,0x00..04
withR
as an argument,R
toY
,RETURNDATACOPY
opcode.When this contract is invoked, a consensus-compliant node would push
X
on the EVM stack, whereas Geth would pushY
.Specific Go Packages Affected
github.com/ethereum/go-ethereum/core/vm
For more information
If you have any questions or comments about this advisory:
References