Jeff Prestes
335760bf06
accounts/abi: Brings out the msg defined at require statement in SC function ( #17328 )
6 years ago
bas-vk
7df52e324c
accounts/abi: add support for unpacking returned bytesN arrays ( #15242 )
6 years ago
weimumu
3ad73443c7
fix slice unpack bug in accounts/abi ( #18321 )
...
* fix slice unpack bug in accounts/abi
6 years ago
tzapu
e79821cabe
accounts/abi: argument type and name were reversed ( #17947 )
...
argument type and name were reversed
6 years ago
Corey Lin
b3be9b7cd8
usbwallet: check returned error when decoding hexstr ( #18056 )
...
* usbwallet: check returned error when decoding hexstr
* Update accounts/usbwallet/ledger.go
Co-Authored-By: CoreyLin <514971757@qq.com>
* usbwallet: check hex decode error
6 years ago
Vedhavyas Singareddi
92639b676a
Add packing for dynamic array and slice types ( #18051 )
...
* added tests for new abi encoding features (#4 )
* added tests from bytes32[][] and string[]
* added offset to other types
* formatting
* Abi/dynamic types (#5 )
* Revert "Abi/dynamic types (#5 )" (#6 )
This reverts commit dabca31d79
.
* Abi/dynamic types (#7 )
* some cleanup
* Apply suggestions from code review
apply suggestions
Co-Authored-By: vedhavyas <vedhavyas.singareddi@gmail.com>
* added better formatting (#8 )
* review chnages
* better comments
6 years ago
Wenbiao Zheng
32d35c9c08
accounts/keystore: delete the redundant keystore in filename ( #17930 )
...
* accounts/keystore: reduce file name length
* accounts/keystore: reduce code line width
6 years ago
Wenbiao Zheng
6ff97bf2e5
accounts: wallet derivation path comment is mistaken ( #17934 )
6 years ago
Evgeny
331fa6d307
accounts/usbwallet: simplify code using -= operator ( #17904 )
6 years ago
Martin Holst Swende
d5c7a6056a
cmd/clef: encrypt the master seed on disk ( #17704 )
...
* cmd/clef: encrypt master seed of clef
Signed-off-by: YaoZengzeng <yaozengzeng@zju.edu.cn>
* keystore: refactor for external use of encryption
* clef: utilize keystore encryption, check flags correctly
* clef: validate master password
* clef: add json wrapping around encrypted master seed
6 years ago
Jeremy Schlatter
5ed3960b9b
accounts/abi/bind: stop using goimports in the binding generator ( #17768 )
6 years ago
Martin Holst Swende
96fd50be10
accounts/abi: fix panic in MethodById lookup. Fixes #17797 ( #17798 )
6 years ago
CDsigma
a5aaab2f22
accounts/abi/bind/backends: fix typo ( #17749 )
6 years ago
gary rong
d6254f827b
all: protect self-mined block during reorg ( #17656 )
6 years ago
Martin Holst Swende
6f004c46d5
accounts/keystore: double-check keystore file after creation ( #17348 )
6 years ago
Martin Holst Swende
16bc8741bf
abi, signer: fix nil dereference in #17633 ( #17653 )
...
* abi,signer: fix nil dereference in #17633
* signer/core: tiny typo fix in test error message
6 years ago
Diep Pham
42bd67bd6f
accounts/abi: fix unpacking of negative int256 ( #17583 )
6 years ago
Wenbiao Zheng
d1aa605f1e
all: remove the duplicate 'the' in annotations ( #17509 )
6 years ago
Sasuke1964
60390878a5
accounts: fixed typo ( #17421 )
6 years ago
Jeff Prestes
212bba47ff
backends: configurable gas limit to allow testing large contracts ( #17358 )
...
* backends: increase gaslimit in order to allow tests of large contracts
* backends: increase gaslimit in order to allow tests of large contracts
* backends: increase gaslimit in order to allow tests of large contracts
6 years ago
Roc Yu
70176cda0e
accounts/keystore: rename skipKeyFile to nonKeyFile to better reveal the function purpose ( #17290 )
6 years ago
Péter Szilágyi
d9575e92fc
crypto/secp256k1: remove external LGPL dependencies ( #17239 )
6 years ago
Roc Yu
040dd5bd5d
accounts/abi: refactor Method#Sig() to use index in range iterator directly ( #17198 )
6 years ago
Roc Yu
323428865f
accounts: add unit tests for URL ( #17182 )
6 years ago
Ralph Caraveo III
5d30be412b
all: switch out defunct set library to different one ( #16873 )
...
* keystore, ethash, eth, miner, rpc, whisperv6: tech debt with now defunct set.
* whisperv5: swap out gopkg.in/fatih/set.v0 with supported set
6 years ago
Péter Szilágyi
e1f1d3085c
accounts, eth, les: blockhash based filtering on all code paths
6 years ago
Wenbiao Zheng
61a5976368
accounts: remove deadcode isSigned ( #16990 )
7 years ago
Husam Ibrahim
28aca90716
accounts/usbwallet: correct comment typo ( #16998 )
7 years ago
Husam Ibrahim
3e57c33147
accounts/usbwallet: correct comment typo ( #17008 )
7 years ago
Wenbiao Zheng
c95e4a80d1
accounts/keystore: assign schema as const instead of var ( #16985 )
7 years ago
Péter Szilágyi
49719e21bc
core, eth: minor txpool event cleanups
7 years ago
rjl493456442
a2e43d28d0
all: collate new transaction events together
7 years ago
Guillaume Ballet
247b5f0369
accounts/abi: allow abi: tags when unpacking structs
...
Go code users can now tag event struct members with `abi:` to specify in what fields the event will be de-serialized.
See PR #16648 for details.
7 years ago
gary rong
7beccb29be
all: get rid of error when creating memory database ( #16716 )
...
* all: get rid of error when create mdb
* core: clean up variables definition
* all: inline mdb definition
7 years ago
Péter Szilágyi
6cf0ab38bd
core/rawdb: separate raw database access to own package ( #16666 )
7 years ago
GagziW
541f299fbb
accounts: changed if-else blocks to conform with golint ( #16654 )
7 years ago
kiel barry
c1ea527573
accounts: golint updates for this or self warning ( #16627 )
7 years ago
thomasmodeneis
ba1030b6b8
build: enable goimports and varcheck linters ( #16446 )
7 years ago
Martin Holst Swende
ec3db0f56c
cmd/clef, signer: initial poc of the standalone signer ( #16154 )
...
* signer: introduce external signer command
* cmd/signer, rpc: Implement new signer. Add info about remote user to Context
* signer: refactored request/response, made use of urfave.cli
* cmd/signer: Use common flags
* cmd/signer: methods to validate calldata against abi
* cmd/signer: work on abi parser
* signer: add mutex around UI
* cmd/signer: add json 4byte directory, remove passwords from api
* cmd/signer: minor changes
* cmd/signer: Use ErrRequestDenied, enable lightkdf
* cmd/signer: implement tests
* cmd/signer: made possible for UI to modify tx parameters
* cmd/signer: refactors, removed channels in ui comms, added UI-api via stdin/out
* cmd/signer: Made lowercase json-definitions, added UI-signer test functionality
* cmd/signer: update documentation
* cmd/signer: fix bugs, improve abi detection, abi argument display
* cmd/signer: minor change in json format
* cmd/signer: rework json communication
* cmd/signer: implement mixcase addresses in API, fix json id bug
* cmd/signer: rename fromaccount, update pythonpoc with new json encoding format
* cmd/signer: make use of new abi interface
* signer: documentation
* signer/main: remove redundant option
* signer: implement audit logging
* signer: create package 'signer', minor changes
* common: add 0x-prefix to mixcaseaddress in json marshalling + validation
* signer, rules, storage: implement rules + ephemeral storage for signer rules
* signer: implement OnApprovedTx, change signing response (API BREAKAGE)
* signer: refactoring + documentation
* signer/rules: implement dispatching to next handler
* signer: docs
* signer/rules: hide json-conversion from users, ensure context is cleaned
* signer: docs
* signer: implement validation rules, change signature of call_info
* signer: fix log flaw with string pointer
* signer: implement custom 4byte databsae that saves submitted signatures
* signer/storage: implement aes-gcm-backed credential storage
* accounts: implement json unmarshalling of url
* signer: fix listresponse, fix gas->uint64
* node: make http/ipc start methods public
* signer: add ipc capability+review concerns
* accounts: correct docstring
* signer: address review concerns
* rpc: go fmt -s
* signer: review concerns+ baptize Clef
* signer,node: move Start-functions to separate file
* signer: formatting
7 years ago
Ricardo Domingos
6ab9f0a19f
accounts/abi: improve test coverage ( #16044 )
7 years ago
Mark
cddb529d70
accounts/abi: normalize method name to a camel-case string ( #15976 )
7 years ago
Javier Peletier
60a999f238
accounts/abi: Modified unpackAtomic to accept struct lvalues
7 years ago
protolambda
0b814d32f8
accounts/abi: Abi binding support for nested arrays, fixes #15648 , including nested array unpack fix ( #15676 )
...
* accounts/abi/bind: support for multi-dim arrays
Also:
- reduce usage of regexes a bit.
- fix minor Java syntax problems
Fixes #15648
* accounts/abi/bind: Add some more documentation
* accounts/abi/bind: Improve code readability
* accounts/abi: bugfix for unpacking nested arrays
The code previously assumed the arrays/slices were always 1 level
deep. While the packing supports nested arrays (!!!).
The current code for unpacking doesn't return the "consumed" length, so
this fix had to work around that by calculating it (i.e. packing and
getting resulting length) after the unpacking of the array element.
It's far from ideal, but unpacking behaviour is fixed now.
* accounts/abi: Fix unpacking of nested arrays
Removed the temporary workaround of packing to calculate size, which was
incorrect for slice-like types anyway.
Full size of nested arrays is used now.
* accounts/abi: deeply nested array unpack test
Test unpacking of an array nested more than one level.
* accounts/abi: Add deeply nested array pack test
Same as the deep nested array unpack test, but the other way around.
* accounts/abi/bind: deeply nested arrays bind test
Test the usage of bindings that were generated
for methods with multi-dimensional (and not
just a single extra dimension, like foo[2][3])
array arguments and returns.
edit: trigger rebuild, CI failed to fetch linter module.
* accounts/abi/bind: improve array binding
wrapArray uses a regex now, and arrayBindingJava is improved.
* accounts/abi: Improve naming of element size func
The full step size for unpacking an array
is now retrieved with "getFullElemSize".
* accounts/abi: support nested nested array args
Previously, the code only considered the outer-size of the array,
ignoring the size of the contents. This was fine for most types,
but nested arrays are packed directly into it, and count towards
the total size. This resulted in arguments following a nested
array to replicate some of the binary contents of the array.
The fix: for arrays, calculate their complete contents size:
count the arg.Type.Elem.Size when Elem is an Array, and
repeat when their child is an array too, etc.
The count is the number of 32 byte elements, similar to how it
previously counted, but nested.
* accounts/abi: Test deep nested arr multi-arguments
Arguments with a deeply nested array should not cause the next arguments
to be read from the wrong position.
7 years ago
Péter Szilágyi
5cf1d35470
eth, les, light: filter on logs only, derive receipts on demand
7 years ago
Martin Holst Swende
61f2279bde
abi: fix missing method on go 1.7/1.8
7 years ago
Martin Holst Swende
bd6ed23899
accounts/abi: harden unpacking against malicious input
7 years ago
Martin Holst Swende
08c5d4dd27
accounts/abi: address review concerns
7 years ago
Martin Holst Swende
f0f594d045
accounts/abi: Deduplicate code in unpacker
7 years ago
Martin Holst Swende
1ede68355d
accounts/abi: add another unpack interface
7 years ago
Fynn
1e72271f57
accounts/abi: use unpackTuple to unpack event arguments
...
Events with just 1 argument fail before this change
7 years ago