  }
  
  
-@@ -438,10 +566,17 @@ int nopoll_conn_tls_send (noPollConn * conn, char * buffer, int buffer_size)
+@@ -438,10 +565,17 @@ int nopoll_conn_tls_send (noPollConn * conn, char * buffer, int buffer_size)
  	int         res;
  	nopoll_bool needs_retry;
  	int         tries = 0;

 	if (! nopoll_conn_is_ok (conn)) {
 		printf ("ERROR: Expected to find proper client connection status, but found error..\n");
 		return nopoll_false;
@@ -2075,9 +2241,9 @@ nopoll_bool test_23 (void) {
 	/* disable verification */
 	opts = nopoll_conn_opts_new ();
 	nopoll_conn_opts_ssl_peer_verify (opts, nopoll_false);
-
+    nopoll_conn_opts_ssl_host_verify (opts, nopoll_false);
 	/* call to create a connection */
-	conn = nopoll_conn_tls_new (ctx, opts, "localhost", "1235", NULL, NULL, NULL, NULL);
+	conn = nopoll_conn_tls_new (ctx, opts, "localhost", "1235", NULL, NULL, NULL, NULL,NULL,NULL,NULL,0);
 	if (! nopoll_conn_is_ok (conn)) {
 		printf ("ERROR: Expected to find proper client connection status, but found error..\n");
 		return nopoll_false;
@@ -2093,7 +2259,8 @@ nopoll_bool test_23 (void) {
 	/* call to create a connection second connection */
 	opts = nopoll_conn_opts_new ();
 	nopoll_conn_opts_ssl_peer_verify (opts, nopoll_false);
-	conn = nopoll_conn_tls_new (ctx, opts, "localhost", "1235", NULL, NULL, NULL, NULL);
+	nopoll_conn_opts_ssl_host_verify (opts, nopoll_false);
+	conn = nopoll_conn_tls_new (ctx, opts, "localhost", "1235", NULL, NULL, NULL, NULL,NULL,NULL,NULL,0);
 	if (! nopoll_conn_is_ok (conn)) {
 		printf ("ERROR: Expected to find proper client connection status, but found error..\n");
 		return nopoll_false;
@@ -2129,9 +2296,10 @@ nopoll_bool test_24 (void) {
 	/* configure cookie */
 	opts = nopoll_conn_opts_new ();
 	nopoll_conn_opts_set_cookie (opts, "theme=light; sessionToken=abc123");
-
+    nopoll_conn_opts_ssl_host_verify (opts, nopoll_false);
+    
 	/* create connection */
-	conn = nopoll_conn_new_opts (ctx, opts, "localhost", "1234", NULL, NULL, NULL, NULL);
+	conn = nopoll_conn_new_opts (ctx, opts, "localhost", "1234", NULL, NULL, NULL, NULL,NULL,NULL,NULL,0);
 	if (! nopoll_conn_is_ok (conn)) {
 		printf ("ERROR: Expected to find proper client connection status, but found error..\n");
 		return nopoll_false;
@@ -2184,9 +2352,9 @@ nopoll_bool test_25_check_cookie (noPollCtx * ctx, const char * cookie) {
 
 	/* set a cookie bigger than 1044 */
 	nopoll_conn_opts_set_cookie (opts, cookie);
-
+    nopoll_conn_opts_ssl_host_verify (opts, nopoll_false);
 	/* create connection */
-	conn = nopoll_conn_new_opts (ctx, opts, "localhost", "1234", NULL, NULL, NULL, NULL);
+	conn = nopoll_conn_new_opts (ctx, opts, "localhost", "1234", NULL, NULL, NULL, NULL,NULL,NULL,NULL,0);
 	if (! nopoll_conn_is_ok (conn)) {
 		printf ("ERROR: Expected to find proper client connection status, but found error..\n");
 		return nopoll_false;
@@ -2237,7 +2405,7 @@ nopoll_bool test_26 (void) {
 	ctx = create_ctx ();
 
 	/* create connection */

 	/* get the nonce */
 	if (! nopoll_nonce (nonce, 16)) {
 		nopoll_log (conn->ctx, NOPOLL_LEVEL_CRITICAL, "Failed to get nonce, unable to produce Sec-WebSocket-Key.");
@@ -287,9 +400,15 @@ char * __nopoll_conn_get_client_init (noPollConn * conn, noPollConnOpts * opts)
 	/* create accept and store */
 	conn->handshake = nopoll_new (noPollHandShake, 1);
 	conn->handshake->expected_accept = nopoll_strdup (key);
