Lose duplicated cert in ocsp response
[exim.git] / test / src / client.c
index 63195347fcc6ba8ed56563ee203879a394bda8ed..4e244981752b3c764709a0a627b2b9c78fef0ee7 100644 (file)
@@ -211,18 +211,18 @@ len = SSL_get_tlsext_status_ocsp_resp(s, &p);
 /*BIO_printf(arg, "OCSP response: ");*/
 if (!p)
        {
-       BIO_printf(arg, "no response received\n");
+       BIO_printf(arg, "no OCSP response received\n");
        return 1;
        }
 if(!(rsp = d2i_OCSP_RESPONSE(NULL, &p, len)))
        {
-       BIO_printf(arg, "response parse error\n");
+       BIO_printf(arg, "OCSP response parse error\n");
        BIO_dump_indent(arg, (char *)p, len, 4);
        return 0;
        }
 if(!(bs = OCSP_response_get1_basic(rsp)))
   {
-  BIO_printf(arg, "error parsing response\n");
+  BIO_printf(arg, "error parsing OCSP response\n");
   return 0;
   }
 
@@ -240,12 +240,12 @@ when OCSP_NOVERIFY is set.  The content from the wire
 
 if(OCSP_basic_verify(bs, sk, NULL, OCSP_NOVERIFY) <= 0)
   {
-  BIO_printf(arg, "Response Verify Failure\n");
+  BIO_printf(arg, "OCSP status response verify failure\n");
   ERR_print_errors(arg);
   ret = 0;
   }
 else
-  BIO_printf(arg, "Response verify OK\n");
+  BIO_printf(arg, "OCSP status response: good signature\n");
 
 cert_stack_free(sk);
 return ret;
@@ -297,7 +297,7 @@ if (rc <= 0)
   return 0;
   }
 
-printf("SSL connection using %s\n", SSL_get_cipher (*ssl));
+/* printf("SSL connection using %s\n", SSL_get_cipher (*ssl)); */
 return 1;
 }
 
@@ -802,6 +802,8 @@ nextinput:
              }
            fflush(stdout);
            }
+           else
+             printf("Succeeded in starting TLS (with OCSP)\n");
          #endif
          }
        #endif
@@ -1234,6 +1236,13 @@ if (rc < 0)
   exit(85);
   }
 
+#ifdef TCP_QUICKACK
+  {
+  int off = 0;
+  (void) setsockopt(srv.sock, IPPROTO_TCP, TCP_QUICKACK, US &off, sizeof(off));
+  }
+#endif
+
 printf("connected\n");
 
 
@@ -1334,7 +1343,7 @@ if (tls_on_connect)
     printf("Failed to verify certificate status\n");
 #endif
   else
-    printf("Succeeded in starting TLS\n");
+    printf("Succeeded in starting TLS%s\n", ocsp_stapling ? " (with OCSP)":"");
   }
 #endif