* feature: layers of connections
* feature: upgrade layers of connection
* fix: tests
* feature: test of layers upgrade
* refactor: enable disabled upgrader tests
* feature: sha-1 hash
* feature: websocket layer
* fix: read-buffer extending
* feature: decide layers for connection upgrade by provided multiaddress
* refactor: combine regular and websocket echo-client/-server to single one
* refactor: rename peer::Protocol to peer::ProtocolName
* refactor: implement addressToBytes, as replacement addressToHex
* refactor: mark addressToHex as deprecated
* feature: extend ConversionError
* fix: multiaddress manipulations
* feature: dummy protocols for tests
* fix: tests of converters
* fix: collision in DI
* refactor: update outcome macros for tests
* fix: connection upgrader in part of layers
* fix: ws read-writer in case big data fragmented by frames
* experiment: add delay of sending jumbo message, to give a chance for Id-protocol to end his work
* experiment: log difference sent and received data for analyse
* feature: control frames (ping/pong/close)
* fix: sending huge portions of data
* fix: echo sessions
* feature: optional hex dump in dumpBin
* fix: echo client
* update: hunter package manager
* fix: hardcoded request and response in http-to-ws upgraded
* fix: add ws version header
* fix: reduce length of ws-key header
* fix: make ws-header check case-insensitive
* fix: use locale independent predicate for ci-compare
* fix: use boost endian conversion instead endian macros
Signed-off-by: Dmitriy Khaustov aka xDimon <khaustov.dm@gmail.com>
* error codes for connections and streams are part of interfaces
* yamux and build-in ping
* host is explicitly stopped in test
* added expire timer for yamux connection
* fixes in event bus
* feedback on connections close
* cyclic dependencies resolved, connectedness is a function of Host
* bugfixes in yamux creation
* minor format fixes
* post-review corrections
* error codes for connections and streams are part of interfaces
* test corrected
* Update src/connection/error_codes.cpp
Co-authored-by: Igor Egorov <igor@soramitsu.co.jp>
Co-authored-by: Igor Egorov <igor@soramitsu.co.jp>
* new scheduler: WIP
* macro args corrected in outcome.hpp
* little fixes of occasional bulk rename
* more precise use of scheduler threshold
* explanations added to scheduler test
* build fix for macos
* corrections
* feature: improve random generator
* fix: getting listened multiaddress in tcp listener
* fix: reduce logging in secio
* feature: new implementation of kademlia
* feature: validation
* fix: DSA
* feature: CIDv1 encoding
* refactoring: replace deprecated sha256 function by hasher
* fix: multiaddress operations
* feature: make PeerId comparable to using in std::set
* refactoring: addr repo
* feature: rendezvous chat as example of Kademlia using
* feature: unit-test for kademlia parts
* wipe: remove previous implementation of Kademlia
* fix: cmake files
* fix: some warnings
* feature: using timeout for make new stream
* feature: smart using of peer routing
* fix: kademlia message parsing
* refactoring: headers including
* feature: add handle and timeout as argument of Host::connect
* fix: some log messages
* feature: Host::disconnect method
* fix: providing listen-addr in messages of Identify protocol
* refactoring: improve multiaddress manipulations
* refactoring: one way for naming of target for protobuf
* fix: clean up; format
* fix: change level some log
* fix: suppress connection to themselves
* fix: prepare rendezvous chat as example to introduction and provide README
Signed-off-by: Dmitriy Khaustov aka xDimon <khaustov.dm@gmail.com>
* gossip: wire protocol
* gossip: peer set and wire protocol utilities revised
* gossip: msg cache w/expiration
* data structures for gossip: fixes and unittest
* changes due to pr 1 feedback
* one more fix due to PR requests
* one more try against ci
* gossip part 2
* gossip: pr1 reflects pr2
* gossip: pr1 reflects pr2
* Fix/gossip pr 1 (#46)
* Fix build for macos
* Improvements
* deprecated logic removed
* gossip: cleanups and renamings
* gossip: renmings
* gossip serialization method signature changed
* gossip: serialization signature changed
* Gossip pr 1 (#37)
* gossip: wire protocol
* gossip: peer set and wire protocol utilities revised
* gossip: msg cache w/expiration
* data structures for gossip: fixes and unittest
* changes due to pr 1 feedback
* one more fix due to PR requests
* one more try against ci
* gossip: pr1 reflects pr2
* gossip: pr1 reflects pr2
* Fix/gossip pr 1 (#46)
* Fix build for macos
* Improvements
* deprecated logic removed
* gossip: cleanups and renamings
* gossip: renmings
* gossip serialization method signature changed
Co-authored-by: kamilsa <kamilsa16@gmail.com>
* refactorings
* typo fixed
* minor fixes
* +gossip-example
* +gossip-example
* fixes and example
* debug things
* gossip: subscriptions test and bugfixes
* dont forward messages back to their origins
* injectors made parametric (to build examples)
* gossip: fixes
* more fixes in pub-sub
* fixes in gossip example
* sublogger can set new instance name
* message cache fix exp times
* chat example
* logs and traces added for debug purposes
* README.md for gossip examples
* small patch for older stdlibs support
* more logs and traces
* more logs and traces
* new inbound protocol streams are allowed for all connections
* streams issues fixed
* gossip injector fixed
* gossip new example
* boost_program_options in dependencies
* scheduler with config param (strong type for injector)
* tests fixed due to recent changes
* cleanup in yamux and dialer-listener hotfixes
* hotfixes to yamux and dialer
* yamux changes
* parametrized netork and host injectors
* streams regression test
* patched mplex connections/streams so that streams get notified about EOF
Co-authored-by: kamilsa <kamilsa16@gmail.com>
* Fix public key part in echo server example
* Remove unused Plaintext session class
* Rename Plaintext header guards
* Fix illegal comparison in crypto provider impl
* Implement SECIO
* Switch Kademlia to boost::optional instead of std
* Add -insecure option to echo server
* Add MessageReadWriterBigEndian
* Add SECIO cases to host_integration_test
* Add SECIO marshallers tests
Possible Drawbacks
Not possible to perform cross-implementation testing by now (go implementation of libp2p got updated much so c++ implementation needs to be changed too).
P521 curve-based algorithm could be faulty - needs to be tested when cross-implementation testing gets possible.
User's callback could be called twice in case of error inside secureInbound and secureOutbound methods - this could be easily fixed if we count this as an issue.
Signed-off-by: Igor Egorov <igor@soramitsu.co.jp>
* Enable RSA crypto provider
* Make secure use of user's input buffers in crypto providers
* Enable ECDSA crypto provider
* Enable Secp256k1 crypto provider
* Remove all the legacy and redundant code from the crypto provider
* Use boost::optional in Kademlia and apply clang-format
* Refactor keygen test
Signed-off-by: Igor Egorov <igor@soramitsu.co.jp>
* cmake hunter config fix for gtest and gcc-9
* kademlia DHT PoC
* kademlia DHT PoC-trying to fix dead streams
* kad dirs restructure
* kademlia POC v2
* todos and ci fixes
* Implement SHA512 hash algo
* Implement Ed25519 provider as independent from lp2p key structs
* Add Ed25519 dependency to CryptoProvider and net injector
* Add comments to Hash literals about their proper usage
* Use Ed25519Provider in CryptoProvider
Signed-off-by: Igor Egorov <igor@soramitsu.co.jp>