Conversation
Maybe passing some entropy down explicitly could help with at least the controller side of things? Similar to how we plumb through RNG seeds. We could even make
Seed a new RNG from the old one? Or we could pull in e.g. a PCG RNG explicitly and benefit from their clone impl. |
|
Flagging for viz: I'm taking a look at this now. I'm pretty sure I can eliminate the need for some of the fallibility by switching to PCG where a CSPRNG isn't needed. There's one place (FWICT) where we'll need (Note: I'm not super familiar with QUIC; my understanding from some quick research is that using a PCG instance for randomness is OK in the context of BBR since a CSPRNG isn't needed for randomness in flow/congestion control.) |
|
PCG is overkill, if anything, yeah. |
|
Thanks! I'll try and have a PR up by EOD today. |
There are some pain points here:
SysRngto initialize has become explicitly fallible, which is fair enough but then requires some of our APIs to be fallible as well (or panicking, I suppose?). This affectsEndpoint::new()andBbr::new(); the latter in turn wants to infect theControllerFactory::build()method.StdRngis no longerClonewhich is also fair enough, but right now ourControllertrait has aclone_box()method which we use for path migration (as well as to expose the congestion controller state viaquinn::Connection::congestion_state()).