Looking for feedbacks on a Noise Protocol implementation

Hello everyone !

I have been working on this Noise protocol implementation in Rust for a few months (previously on a separate repo) and I would love to have your feedback on its API.

The idea is to check at compile-time that the pattern, role, and ciphersuite are valid, as well as ensuring that all required keys have been provided.

For the keys, I am using const assertions in the build() method as it allows me to provide better error messages than I would get from using a typestate pattern alone.

I'd especially appreciate feedback on whether the API feels idiomatic and whether there are things you would design differently.

Don't hesitate to point out anything you think could be improved !

Repo: GitHub - mathieuemery/nivalis: A compile-time verified Noise Protocol Framework implementation in Rust. · GitHub