Could this be achieved via a mock, if only to validate that a regression won't happen?
Gary On Sat, Jul 20, 2024, 7:09 AM Thomas Wolf <[email protected]> wrote: > On 20.07.24 01:46 , Gary Gregory wrote: > > I don't see a matching unit test in [2] so we are asking for a future > > regression IMO... > > This _is_ tested. Our tests connect to old OpenSSH, not using > this key exchange method, and to new OpenSSH method, where it > is used. > > The problem is that to test this, you'd have to test potentially > many key exchanges. Against an external implementation, i.e., an > OpenSSH container. And with the fix, they all would succeed. So > when do you stop? After 1000? After 2000? > > You _could_ stop once you get a secret that does start with zero. > But to the detect that, you'd have to change existing code just > to make this observable for the test, and you still wouldn't know > after how many key exchanges it would happen. > > So that's why there is no dedicated test for this. It _is_ tested > implicitly in other tests. > > Cheers, > > Thomas > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > >
