go-pulse/accounts
Thomas Bocek 89c6c5bb85 accounts/abi: Negative numbers not properly converted in ABI encoding
When converting a negative number e.g., -2, the resulting ABI encoding
should look as follows:
fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe.
However, since the check of the type is for an uint instead of an
int, it results in the following ABI encoding:
0101010101010101010101010101010101010101010101010101010101010102. The
Ethereum ABI
(https://github.com/ethereum/wiki/wiki/Ethereum-Contract-ABI) says,
that signed integers are stored in two's complement which should be
of the form ffffff.... and not 01010101..... for e.g. -1. Thus, I
removed the type check in numbers.go as well as the function S256
as I don't think they are correct. Or maybe I'm missing something?
2016-06-06 14:27:15 +02:00
..
abi accounts/abi: Negative numbers not properly converted in ABI encoding 2016-06-06 14:27:15 +02:00
testdata
account_manager.go eth: add new RPC method (personal.) SignAndSendTransaction 2016-05-20 15:54:18 +02:00
accounts_test.go eth: add new RPC method (personal.) SignAndSendTransaction 2016-05-20 15:54:18 +02:00
addrcache_test.go
addrcache.go
key_store_passphrase_test.go
key_store_passphrase.go
key_store_plain.go
key_store_test.go
key.go
presale.go
watch_fallback.go
watch.go