openethereum/rpc/src/v1
Niklas Adolfsson 6e7d8f90b5 [light] Validate account balance before importing transactions (#9417)
* `light::verify_transaction` basic tx validation

* update wasm tests

* Provide `cached_nonce` in `parity_next_nonce` RPC

* nits

* Improve error handeling

Two separate errors for distinguishing between `account not found` and
`insufficient balance`. However, when `next_nonce()` is called and the
account is not found then provide `local_best_next_nonce`!

* Ensure only one n/w request is performed

Refactored to code again:
* Removed `fn cached_next_nonce`
* Removed extra n/w request in `sign` to check balance
* Refactored `fill_optional_field` to request nonce and check account balance

* nits

* grumbles needless clone

* Prevent integer overflow with saturating add & mul

* Call `sign_transaction()` directly from `sign()`

Because the change in `fill_optional_fields` always fill the nonce it is
now possible to call `sign_transaction` directly instead of creating a
`ProspectiveSigner` "object".
2018-09-11 19:20:59 +02:00
..
helpers [light] Validate account balance before importing transactions (#9417) 2018-09-11 19:20:59 +02:00
impls Only check warp syncing for eth_getWorks (#9484) 2018-09-11 01:53:42 +08:00
tests Update state tests execution model (#9440) 2018-09-10 22:38:30 +02:00
traits Bad blocks RPC + reporting (#9433) 2018-09-08 04:04:28 +02:00
types Better logging when mining own transactions. (#9363) 2018-08-17 16:01:32 +01:00
extractors.rs Remove all dapp permissions related settings (#9120) 2018-08-07 20:52:23 +08:00
informant.rs Update license header and scripts (#8666) 2018-06-04 10:19:50 +02:00
metadata.rs Remove all dapp permissions related settings (#9120) 2018-08-07 20:52:23 +08:00
mod.rs Bad blocks RPC + reporting (#9433) 2018-09-08 04:04:28 +02:00