mbedtls icon indicating copy to clipboard operation
mbedtls copied to clipboard

Create unit test for an SSL connection

Open gilles-peskine-arm opened this issue 2 years ago • 4 comments

Create a unit test function that runs both a TLS client and a TLS server, performs a handshake, and exchanges some data (one write and one read from each side).

This function should take the following arguments: protocol (DTLS or TLS), version (1.2 or 1.3, also older versions in 2.28), ciphersuite, (Maybe also whether to do client authentication?)

Put this in a new unit test suite test_suite_ssl_connection (the name can be improved), because test_suite_ssl is already too big.

Prerequisite: https://github.com/Mbed-TLS/mbedtls/issues/6173

This is intended as a step towards (mostly) replacing compat.sh -p mbedTLS (see https://github.com/Mbed-TLS/mbedtls/issues/5346). Follow-ups:

  • Parameter enumeration
  • Certificates
  • more?

gilles-peskine-arm avatar Aug 04 '22 22:08 gilles-peskine-arm