IntersectMBO / IntersectMBO/ouroboros-network
Relax handshake negotiation
- Dominant language
- Haskell
- Stars
- 296
- Forks
- 104
- Avg merge
- 2d 10h
- Merged PRs (30d)
- 4
Description
When negotiating versions we should ignore versions for which version data
cannot be decoded. We do that only in [`codecHandshake`] which decodes bytes
to `cborg` `Term`, but not in [`acceptOrRefuse`] which decodes the `Term`
to a Haskell data type.
The PR should also enhance our test suite to send a mixture of:
* valid version data
* invalid CBOR bytestring of version data
* valid CBOR bytestring, but invalid CBOR encoding of version data
One can easily test this by breaking encoding of one of the version data in
`cardano-ping` library (that's how the issue was discovered).
[`codecHandshake`]: https://input-output-hk.github.io/ouroboros-network/ouroboros-network-framework/Ouroboros-Network-Protocol-Handshake-Codec.html#v:codecHandshake
[`acceptOrRefuse`]: https://input-output-hk.github.io/ouroboros-network/ouroboros-network-framework/Ouroboros-Network-Protocol-Handshake-Client.html#v:acceptOrRefuse
Contributor guide
Assessment
This issue has not been assessed yet.