fix normal psk no rsa examples

This commit is contained in:
toddouska
2013-03-11 13:19:43 -07:00
parent 895944c04a
commit 285ca36ca2
4 changed files with 48 additions and 13 deletions

View File

@@ -302,6 +302,10 @@ void client_test(void* args)
usePsk = 1;
#endif
#if defined(NO_RSA) && !defined(HAVE_ECC)
usePsk = 1;
#endif
if (usePsk) {
#ifndef NO_PSK
CyaSSL_CTX_set_psk_client_callback(ctx, my_psk_client_cb);
@@ -310,7 +314,7 @@ void client_test(void* args)
#ifdef HAVE_NULL_CIPHER
defaultCipherList = "PSK-NULL-SHA256";
#else
defaultCipherList = "PSK-AES256-CBC-SHA256";
defaultCipherList = "PSK-AES128-CBC-SHA256";
#endif
if (CyaSSL_CTX_set_cipher_list(ctx,defaultCipherList) !=SSL_SUCCESS)
err_sys("client can't set cipher list 2");