update git ignore and add DH params to server-tls example

pull/15/head^2
kaleb-himes 2015-11-13 13:12:01 -07:00
parent 4bb0402ee4
commit e6b2d046b3
2 changed files with 8 additions and 0 deletions

2
.gitignore vendored
View File

@ -59,6 +59,8 @@ android/wolfssljni-ndk-sample/proguard-project.txt
/tls/server-tls-threaded
/tls/server-tls
/tls/server-tcp
/tls/client-tls-ecdhe
/tls/server-tls-ecdhe
crypto/3des/3des-file-encrypt
crypto/aes/aes-file-encrypt

View File

@ -156,6 +156,12 @@ int main()
return EXIT_FAILURE;
}
/* load DH params */
ret = wolfSSL_CTX_SetTmpDH_file(ctx, "../certs/dh2048.pem" , SSL_FILETYPE_PEM);
if (ret != SSL_SUCCESS) {
fprintf(stderr, "Error setting DH parameters.\n");
return EXIT_FAILURE;
}
/* Initialize the server address struct to zero */
memset((char *)&serverAddr, 0, sizeof(serverAddr));