Commit Graph

7 Commits

Author SHA1 Message Date
KonradStaniec 8ef6b13b1b
Add event loop to socket (#475)
- add eventLoop to control all incoming events
- change semantic of write to asynchronously block only when send buffer is full, and not when bytes do not fit into send window
- change handling of receive buffer, to start dropping packets if the reorder buffer and receive buffer are full. Old behaviour was to async block unless there is space which could lead to resource exhaustion attacks
2022-02-24 18:22:44 +01:00
Kim De Mey 2c236f6495
Style fixes according to --styleCheck:usages (#452)
Currently only setting `--styleCheck:hint` as there are some
dependency fixes required and the compiler seems to trip over the
findnode MessageKind, findnode Message field and the findNode
proc. Also over protocol.Protocol usage.
2021-12-20 13:14:50 +01:00
KonradStaniec b4066a5688
Ledbat congestion control (#443)
* Return delay to remote peer

* Initial ledbat window calculation

* Add tests for window grow and decay

* Add delay histograms

* Add calculation of clock drift
2021-12-09 10:52:21 +01:00
KonradStaniec ce296ff76e
Make initial state of socket configurable (#428)
* Make initial state of socket configurable
2021-11-19 11:36:46 +01:00
KonradStaniec d5e5ec9f90
Add possibility to connect with requested conneciton id (#425)
* Improve error handling when initiating connection

* Add api to connect with requested id

* Add callback to allow only specific incoming peers
2021-11-18 10:05:56 +01:00
KonradStaniec b671f6c901
Handling of fin packet (#421)
* Handling of connection finalization by sending and receiving FIN packets
2021-11-09 15:29:59 +01:00
KonradStaniec 7a113ffa48
Add handling of reset packet (#420)
* Add handling of reset packet
2021-11-05 09:41:41 +01:00