Commit Graph

88 Commits

Author SHA1 Message Date
Hawstein
ade37be25b separate trie from util and make its dependencies into libs:
* bytes
* hashdb
* memorydb
* nibbleslice
* nibblevec
2017-09-15 11:03:53 +08:00
debris
ccd6ad52cc Merge branch 'fo-6418-dont-export-bigint' of github.com:paritytech/parity into util_error_chain 2017-09-05 11:15:39 +02:00
debris
c623e5f232 ethcore-network does not use UtilError 2017-09-05 11:14:28 +02:00
Fredrik
e54784bfeb Merge branch 'master' into fo-6418-dont-export-bigint
# Conflicts:
#	dapps/src/tests/helpers/registrar.rs
#	ethcore/evm/src/interpreter/shared_cache.rs
#	ethcore/light/src/client/header_chain.rs
#	ethcore/light/src/client/mod.rs
#	ethcore/light/src/net/mod.rs
#	ethcore/light/src/on_demand/request.rs
#	ethcore/light/src/on_demand/tests.rs
#	ethcore/light/src/provider.rs
#	ethcore/node_filter/src/lib.rs
#	ethcore/src/block.rs
#	ethcore/src/blockchain/blockchain.rs
#	ethcore/src/client/test_client.rs
#	ethcore/src/engines/authority_round/mod.rs
#	ethcore/src/engines/basic_authority.rs
#	ethcore/src/engines/mod.rs
#	ethcore/src/engines/tendermint/mod.rs
#	ethcore/src/engines/validator_set/contract.rs
#	ethcore/src/engines/validator_set/multi.rs
#	ethcore/src/engines/validator_set/safe_contract.rs
#	ethcore/src/engines/vote_collector.rs
#	ethcore/src/miner/external.rs
#	ethcore/src/miner/miner.rs
#	ethcore/src/miner/service_transaction_checker.rs
#	ethcore/src/miner/work_notify.rs
#	ethcore/src/pod_account.rs
#	ethcore/src/pod_state.rs
#	ethcore/src/snapshot/block.rs
#	ethcore/src/snapshot/consensus/work.rs
#	ethcore/src/snapshot/mod.rs
#	ethcore/src/snapshot/service.rs
#	ethcore/src/spec/spec.rs
#	ethcore/src/state/backend.rs
#	ethcore/src/trace/db.rs
#	ethcore/src/verification/queue/mod.rs
#	ethcore/src/verification/verification.rs
#	parity/informant.rs
#	rpc/src/v1/helpers/dispatch.rs
#	rpc/src/v1/helpers/light_fetch.rs
#	rpc/src/v1/helpers/signing_queue.rs
#	rpc/src/v1/impls/eth.rs
#	rpc/src/v1/impls/eth_filter.rs
#	rpc/src/v1/impls/eth_pubsub.rs
#	rpc/src/v1/impls/light/eth.rs
#	rpc/src/v1/impls/signing.rs
#	rpc/src/v1/tests/helpers/miner_service.rs
#	rpc/src/v1/tests/helpers/snapshot_service.rs
#	rpc/src/v1/tests/helpers/sync_provider.rs
#	rpc/src/v1/tests/mocked/eth.rs
#	stratum/src/lib.rs
#	sync/src/blocks.rs
#	sync/src/chain.rs
#	sync/src/light_sync/mod.rs
#	sync/src/tests/helpers.rs
#	sync/src/tests/snapshot.rs
#	updater/src/updater.rs
#	util/src/lib.rs
#	util/triehash/src/lib.rs
2017-09-04 18:32:55 +02:00
Fredrik
308f36a532 Don't reexport bigint from util 2017-09-04 16:36:49 +02:00
Hawstein
7b8af30590 remove re-export of parking_lot in util (#6435) 2017-09-02 20:09:13 +02:00
debris
ba3b2712a1 fixed grumbles 2017-08-31 12:38:53 +02:00
debris
e120c75d17 Hashable::sha3 -> fn keccak for ethcore-network 2017-08-30 17:14:52 +02:00
Arkadiy Paronyan
d520aa2633 Connection filter (#6359) 2017-08-29 14:38:01 +02:00
debris
455ecf700c updated tiny-keccak to 1.3 2017-08-07 10:06:02 +02:00
debris
88cc4cd17a Merge branch 'master' into split 2017-07-29 23:44:55 +02:00
debris
c4989ddc44 removed util::common 2017-07-29 22:49:10 +02:00
Joseph Mark
b5f1524e78 Refactor --allow-ips to handle custom ip-ranges (#6144)
* Add checks for additional reserved ip addresses

100.64.0.0/10 and 240.0.0.0/4 are both reserved but not currently
filtered.

* Add check for special purpose addresses

192.0.0.0/24 - Used for the IANA IPv4 Special Purpose Address Registry

* Refactor ip_utils (#5872)

* Add checks for all ipv4 special use addresses
* Add comprehensive ipv4 test cases

* Refactor Ipv6 address checks (#5872)

* Refactor AllowIP (#5872)

* Add IpFilter struct to wrap predefined filter (AllowIP) with custom
allow/block filters.
* Refactor parsing of --allow-ips to handle custom filters.
* Move AllowIP/IpFilter from ethsync to ethcore-network where they
are used.

* Revert Cargo.lock

* Tests for custom ip filters (#5872)

* Add "none" as a valid argument for --allow-ips to allow narrow
custom ranges, eg.: --allow-ips="none 10.0.0.0/8"
* Add tests for parsing filter arguments and node endpoints.
* Add ipnetwork crate to dev dependencies for testing.

* Add ipv6 filter tests (#5872)

* Revert parity-ui-precompiled to master

* Fix minor detail in usage.txt (#5872)

* Spaces to tabs

* Rename IpFilter::new() to ::default()

* Small readability improvements

* Test (#5872)

* Revert "Test (#5872)"

This reverts commit 7a8906430a6dad633fe29df3dca57f1630851fa9.
2017-07-28 19:06:39 +02:00
Arkadiy Paronyan
4c32177ef3 Fixed node address detection on incoming connection (#6093) 2017-07-19 15:44:08 +02:00
Robert Habermeier
99075ad22a Initial Whisper implementation (#6009)
* whisper skeleton

* basic message store

* rallying and message logic

* pass host info to network protocol handlers

* choose who starts rally based on node key

* module reshuffling

* mining messages

* prune messages by low PoW until below size target

* associated error type for ethkey generators and `OsRng` generator

* beginnings of RPC

* generic message handler for whisper

* reshuffle code order

* standard payload encoding and decoding

* basic crypto

* minor restructuring of net code

* implement shh_post

* merge?

* implement filters

* rand trait for hash types

* filter RPCs for whisper

* symmetric encryption of payload

* pub-sub

* filter tests

* use only secure random IDs

* attach arbitrary protocols to network

* basic integration of whisper into Parity

* eagerly prune low PoW entries

* broadcast messages with salted topics

* node info RPC

* fix import

* fix leading zeros calculation

* address minor grumbles
2017-07-14 20:40:28 +02:00
arkpar
debbfc117a Bumped version 2017-07-13 15:52:01 +02:00
debris
61d8f90530 updated serde to version 1.0 2017-07-06 11:36:15 +02:00
Guanqun Lu
59488769cf network: make it more explicit about StreamToken and TimerToken (#5939) 2017-06-27 18:24:18 +02:00
Arkadiy Paronyan
4d5280e43c removed panic handlers (#5895) 2017-06-22 19:00:53 +02:00
Arkadiy Paronyan
ad6ea4fa49 Bump mio (#5763)
* Bump mio

* Fixed warnings

* Update mio to crates.
2017-06-05 20:40:40 +02:00
Tomasz Drwięga
3ff72794e5 Create an account for chain=dev (#5612)
* implement From<&'static str> for Secret

* Dev account.

* Fix Secret semantics.
2017-05-19 17:06:36 +02:00
Tomasz Drwięga
d2394d3ac3 Updating paths to repos. (#5330)
* Updating paths to repos.

* Updating rotor and libusb

* Fixing other occurrences
2017-03-29 15:17:27 +02:00
Marek Kotewicz
64c098627e updating dependencies (#5028)
* updated docopt, env_logger, semver and regex crates

* updated parking_lot to 0.4

* fixed compiling on linux

* updated igd to 0.6

* updated jsonrpc

* fixed regex related compiler error on linux
2017-03-28 19:06:08 +02:00
Arkadiy Paronyan
3b54b49b0b Resilient warp sync (#5018) 2017-03-24 18:55:57 +01:00
Marek Kotewicz
044d070667 rlp deserialization refactor, 30% faster (#4901)
* fixed naming of rlp modules

* RlpStream cleanup

* appending short rlp lists (0...55 bytes) is 25% faster

* RlpStream does not use bytes module, nor trait Stream

* removed unused code from rlp module

* compiling ethcore-util with new rlp serialization

* compiling parity with new rlp serialization

* fixed compiling ethcore-light with new rlp serialization

* fixed compiling ethsync with new rlp serialization

* moved rlp benches and rlp tests

* rlp deserialization refactor, 30% faster

* removed redundant comment, print

* fixed compiling parity with new rlp deserialization

* removed redundant double-space

* fixed failing test

* updated rlp docs, removed unused traits

* fixed rlp benchmarks

* replace usage of WriteBytesExt with ByteOrder

* removed unused, commented out code

* fixed merge conflict
2017-03-22 14:41:46 +01:00
Marek Kotewicz
d530cc86f3 splitting part of util into smaller crates (#4956)
* split path module from util

* moved RotatingLogger from util to logger crate

* fix tests

* fix tests

* use only one version of ansi_term crate
2017-03-22 06:23:40 +01:00
Marek Kotewicz
a555686bcd rlp serialization refactor (#4873)
* fixed naming of rlp modules

* RlpStream cleanup

* appending short rlp lists (0...55 bytes) is 25% faster

* RlpStream does not use bytes module, nor trait Stream

* removed unused code from rlp module

* compiling ethcore-util with new rlp serialization

* compiling parity with new rlp serialization

* fixed compiling ethcore-light with new rlp serialization

* fixed compiling ethsync with new rlp serialization

* removed redundant comment, print

* removed redundant double-space

* replace usage of WriteBytesExt with ByteOrder
2017-03-20 19:14:29 +01:00
Marek Kotewicz
3fe3353696 removed redundant FixedHash trait, fixes #4029 (#4866) 2017-03-11 22:58:15 +04:00
Arkadiy Paronyan
ae3f85bd5b v1.7 (#4730) 2017-03-07 17:29:27 +01:00
Arkadiy Paronyan
0aad8a87ae Added pending transaction info to eth_getTransactionByHash (#4570)
* Return condition info for pending transactions

* Fixed warnings
2017-02-20 16:19:43 +01:00
Arkadiy Paronyan
c2540dc215 Check for matching session before deregistering (#4563) 2017-02-17 12:20:25 +01:00
Robert Habermeier
3b9ac7648c with_context on LightSync 2017-02-02 17:02:46 +01:00
Arkadiy Paronyan
43cc4ea13d Fixed deadlock in external_url (#4354) 2017-01-30 17:08:21 +01:00
Gav Wood
8404edb656 Fix whitespace (#4299)
* Fix whitespace.

* Update copyright years/owner.

* Push release only for tags.
2017-01-25 18:51:41 +01:00
Robert Habermeier
3ff9324ec0 LES Peer Info (#4195)
* connected peers function for network service

* get LES peer info in sync API

* new peer info in RPC
2017-01-20 12:41:49 +01:00
Arkadiy Paronyan
8852a05301 Prevent duplicate incoming connections (#4180) 2017-01-17 16:02:29 +01:00
Tomasz Drwięga
21006da125 Get rid of unsafe code in ethkey, propagate incorrect Secret errors. (#4119)
* Implementing secret

* Fixing tests
2017-01-11 12:16:47 +01:00
Arkadiy Paronyan
148ea37687 v1.6 in master (#4113) 2017-01-10 15:41:59 +01:00
Arkadiy Paronyan
d67ceec50c Update registration after every write (#4102) 2017-01-10 12:11:32 +01:00
Robert Habermeier
8125b5690c Port try macro to new ? operator. (#3962)
* initial untry sweep

* restore try in ipc codegen, fix inference

* change a few missed try instances
2016-12-27 12:53:56 +01:00
Paul Peregud
b444d23b3a code example: do start before register_protocol (#3947) 2016-12-22 16:15:26 +01:00
Gav Wood
14e4fefbcf
Fix updater permissions and refactor existing code. 2016-12-16 18:17:15 +01:00
Gav Wood
c0a2d5c8f5 Merge pull request #3796 from ethcore/tx-broadcast
Avoid broadcasting transactions to peers that send them
2016-12-12 04:13:56 +01:00
Gav Wood
94f5501c61
authors & homepage => Parity 2016-12-11 19:43:58 +01:00
Gav Wood
58b72c521d
Rename ethcore -> parity in licenses. 2016-12-11 19:31:31 +01:00
Gav Wood
17cc2be4b5
Rename ethcore -> parity in license. 2016-12-11 19:30:54 +01:00
Tomasz Drwięga
b56f12adc6 Merge branch 'master' into tx-broadcast
Conflicts:
	ethcore/light/src/net/context.rs
	ethcore/light/src/net/tests/mod.rs
2016-12-11 17:31:56 +01:00
Tomasz Drwięga
aaf6da4c00 Returning persistent node id 2016-12-10 16:55:29 +01:00
arkpar
02c788a403 Network connectivity fixes 2016-12-10 14:20:34 +01:00
Robert Habermeier
b772901d77 network: process packets only after connection handler finishes 2016-12-09 21:17:05 +01:00