Commit Graph

16 Commits

Author SHA1 Message Date
b4098b9558 chore(net): add disconnect reason (#222) 2022-11-17 15:48:50 +01:00
331a2dbe8f fix(net): add None disconnect reason on PoS p2p violation 2022-11-16 12:16:28 -08:00
ee7140f91e refactor(net): add dedicated transaction event channel (#214) 2022-11-16 21:06:53 +01:00
09ba65fa75 feat(net): add NetworkMode to enforce POS rules (#215) 2022-11-16 11:42:58 -08:00
3ffc0da7c8 feat(net): add disconnect reason (#218) 2022-11-16 11:11:34 -08:00
6b336c62fb feat: add blog propagation handlers (#205) 2022-11-15 23:33:03 +01:00
f8fddcdfa4 feat(p2p): integrate txpool in p2p (#208) 2022-11-15 22:27:41 +01:00
b60ced1de1 feat: add missing message handling (#200)
* feat: add missing message handling

* refactor: new block message handling

* feat: add events and commands for transaction handling

* more work in transactions

* chore: silence warnings
2022-11-15 10:34:28 +01:00
f1e6639374 feat(net): authenticate sessions (#178)
* Switch stream type of ActiveSession to EthStream

 * Start `StatusBuilder` for initializing the `Status` message required
   for the handshake
 * Add `Hardfork` for `Status` default forkid
 * Add `MAINNET_GENESIS` constant

* finish `StatusBuilder`

* initialize eth streams in session

 * add status, hello, and fork filter to session manager
 * fix status builder example
 * add status and hello to network config
   * will probably remove

* removing status and hello from networkconfig

* move forkid to primitives

* change imports for forkid

* add hardfork to primitives

* remove hardfork and forkid from eth-wire

* fix remaining eth-wire forkid references

* put mainnet genesis in constants, remove NodeId

* replace NodeId with PeerId

 * the only NodeId remaining is inherited from enr
 * PeerId still needs to be documented
 * also run cargo fmt

* replace loop with iter().any()

* ignore missing docs for hardforks

* use correct PeerId for Discv4::bind example test

* document PeerId as secp256k1 public key

* cargo fmt

* temporarily allow too_many_arguments

 * the authenticate and start_pending_incoming_session methods have many
   arguments, we can reconsider the lint or fix the methods at a later
   point
2022-11-14 12:03:05 -05:00
5ca2cab97f refactor: move RequestError from network to interfaces p2p (#197) 2022-11-13 09:46:38 +01:00
139efee599 feat(net): impl peer management (#194) 2022-11-12 08:41:15 +01:00
c43d752929 feat(net): more request handling (#186)
* feat(net): more request handling

* rm uneccessary checks

* rm box
2022-11-10 21:24:47 +01:00
836ad6aaee feat(net): add request/response message types (#176)
* feat(net): add request/response message types

* chore: rustfmt
2022-11-08 17:52:17 +01:00
1408309b74 feat(net): add active session type (#169)
* refactor(net): unify capability types

* refactor(net): unify capability types

* feat(net): add active session type
2022-11-07 23:15:38 +01:00
5721262740 refactor(net): unify capability types (#168)
* refactor(net): unify capability types

* refactor(net): unify capability types
2022-11-07 18:04:17 +01:00
b7cdfbf4f9 feat(net): network scaffolding (#110)
* feat(net): network scaffolding
2022-11-07 09:27:08 +01:00