mirror of
https://git.libssh.org/projects/libssh.git
synced 2025-07-31 00:03:07 +03:00
CVE-2023-1667:tests: Send a bit more to make sure rekey is completed
This was for some reason failing on CentOS 7 in 0.10 branch so bringing this to the master too. Signed-off-by: Jakub Jelen <jjelen@redhat.com> Reviewed-by: Norbert Pocs <npocs@redhat.com> Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
This commit is contained in:
committed by
Andreas Schneider
parent
d08f1b2377
commit
dc1254d53e
@ -192,10 +192,11 @@ static void torture_rekey_send(void **state)
|
||||
rc = ssh_userauth_publickey_auto(s->ssh.session, NULL, NULL);
|
||||
assert_int_equal(rc, SSH_AUTH_SUCCESS);
|
||||
|
||||
/* send ignore packets of up to 1KB to trigger rekey */
|
||||
/* send ignore packets of up to 1KB to trigger rekey. Send little bit more
|
||||
* to make sure it completes with all different ciphers */
|
||||
memset(data, 0, sizeof(data));
|
||||
memset(data, 'A', 128);
|
||||
for (i = 0; i < 16; i++) {
|
||||
for (i = 0; i < KEX_RETRY; i++) {
|
||||
ssh_send_ignore(s->ssh.session, data);
|
||||
ssh_handle_packets(s->ssh.session, 50);
|
||||
}
|
||||
|
Reference in New Issue
Block a user