ecies-geth
Advanced tools
Changelog
1.7.0 (2023-11-05)
Features:
Remove dependency to (vulnerable) live-server
only used for testing purpose;
Breaking change: Messages encrypted with ecies-geth
could not be decrypted using go-ethereum
due to an ecies: invalid message error
. Upon analysis of the source code, a nuanced discrepancy was identified. Specifically, the issue lay in the padding of the shared key: go-ethereum
pads the shared key with zeros when it's less than 32 bytes, a behavior not mirrored in ecies-geth
. Follow the links for specific lines in the sources:
https://github.com/ethereum/go-ethereum/blob/master/crypto/ecies/ecies.go#L134-L136 https://github.com/cyrildever/ecies-geth/blob/master/lib/src/typescript/node.ts#L171
IMPORTANT: This fix introduces a breaking change. Messages encrypted by the older version of this library might not be decryptable after the update, and vice versa. Users will need to be aware of this incompatibility when considering an upgrade.