Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
goatgoose committed Oct 17, 2023
1 parent c3b120b commit b66a361
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions tests/unit/s2n_protocol_version_getter_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,8 @@ int main(int argc, char **argv)

/* Ensure that a supported versions extension wasn't received. */
bool supported_versions_received = false;
EXPECT_SUCCESS(s2n_client_hello_has_extension(&server->client_hello, S2N_EXTENSION_SUPPORTED_VERSIONS, &supported_versions_received));
EXPECT_SUCCESS(s2n_client_hello_has_extension(&server->client_hello, S2N_EXTENSION_SUPPORTED_VERSIONS,
&supported_versions_received));
EXPECT_FALSE(supported_versions_received);

/* With no supported versions extension, the maximum version the client can support is
Expand Down Expand Up @@ -239,10 +240,10 @@ int main(int argc, char **argv)

EXPECT_OK(s2n_negotiate_test_server_and_client_until_message(server, client, SERVER_CERT));

EXPECT_EQUAL(s2n_connection_get_server_protocol_version(server), server_version);
EXPECT_EQUAL(s2n_connection_get_client_protocol_version(server), s2n_get_highest_fully_supported_tls_version());
EXPECT_EQUAL(s2n_connection_get_client_hello_version(server), S2N_TLS12);
EXPECT_EQUAL(s2n_connection_get_actual_protocol_version(server), server_version);
EXPECT_EQUAL(s2n_connection_get_server_protocol_version(client), server_version);
EXPECT_EQUAL(s2n_connection_get_client_protocol_version(client), s2n_get_highest_fully_supported_tls_version());
EXPECT_EQUAL(s2n_connection_get_client_hello_version(client), S2N_TLS12);
EXPECT_EQUAL(s2n_connection_get_actual_protocol_version(client), server_version);
}

/* Test get_client_protocol_version fallback behavior on TLS 1.2 servers */
Expand Down

0 comments on commit b66a361

Please sign in to comment.