Skip to content

Commit

Permalink
fixup! Sanity tests of inputs to ssl_version_cmp
Browse files Browse the repository at this point in the history
  • Loading branch information
fwh-dc committed Apr 30, 2024
1 parent c6d0b16 commit 8c39ca1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ssl/statem/statem_lib.c
Original file line number Diff line number Diff line change
Expand Up @@ -2153,6 +2153,9 @@ int ssl_choose_server_version(SSL_CONNECTION *s, CLIENTHELLO_MSG *hello,
int disabled = 0;
RAW_EXTENSION *suppversions;

if (client_version <= 0)
return SSL_R_WRONG_SSL_VERSION;

s->client_version = client_version;

switch (server_version) {
Expand Down

0 comments on commit 8c39ca1

Please sign in to comment.