summaryrefslogtreecommitdiff
path: root/tests/empty_retrieve_function.c
diff options
context:
space:
mode:
authorDaiki Ueno <dueno@redhat.com>2019-03-04 17:17:47 +0100
committerDaiki Ueno <dueno@redhat.com>2019-03-05 15:02:46 +0100
commit2a0164bf28fa2d83a274f290ec9aeaa230fb74d8 (patch)
treecfebee47d1b204d3892de62e919235c85479062b /tests/empty_retrieve_function.c
parent8507645bc6aef19f3755143886995b0a61f894d6 (diff)
downloadgnutls-tmp-cert-req.tar.gz
tls13/certificate: utilize "certificate_required" alerttmp-cert-req
This could make errors more distinguishable when the client sends no certificates or a bad certificate. Signed-off-by: Daiki Ueno <dueno@redhat.com>
Diffstat (limited to 'tests/empty_retrieve_function.c')
-rw-r--r--tests/empty_retrieve_function.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/empty_retrieve_function.c b/tests/empty_retrieve_function.c
index 7ea920494c..c12499bc34 100644
--- a/tests/empty_retrieve_function.c
+++ b/tests/empty_retrieve_function.c
@@ -110,17 +110,17 @@ void doit(void)
gnutls_certificate_allocate_credentials(&clicred);
gnutls_certificate_set_retrieve_function(clicred, cert_cb1);
- _test_cli_serv(x509_cred, clicred, "NORMAL", "NORMAL", "localhost", NULL, NULL, NULL, 0, 1, GNUTLS_E_NO_CERTIFICATE_FOUND, -1);
+ _test_cli_serv(x509_cred, clicred, "NORMAL", "NORMAL", "localhost", NULL, NULL, NULL, 0, 1, GNUTLS_E_CERTIFICATE_REQUIRED, -1);
gnutls_certificate_free_credentials(clicred);
gnutls_certificate_allocate_credentials(&clicred);
gnutls_certificate_set_retrieve_function2(clicred, cert_cb2);
- _test_cli_serv(x509_cred, clicred, "NORMAL", "NORMAL", "localhost", NULL, NULL, NULL, 0, 1, GNUTLS_E_NO_CERTIFICATE_FOUND, -1);
+ _test_cli_serv(x509_cred, clicred, "NORMAL", "NORMAL", "localhost", NULL, NULL, NULL, 0, 1, GNUTLS_E_CERTIFICATE_REQUIRED, -1);
gnutls_certificate_free_credentials(clicred);
gnutls_certificate_allocate_credentials(&clicred);
gnutls_certificate_set_retrieve_function3(clicred, cert_cb3);
- _test_cli_serv(x509_cred, clicred, "NORMAL", "NORMAL", "localhost", NULL, NULL, NULL, 0, 1, GNUTLS_E_NO_CERTIFICATE_FOUND, -1);
+ _test_cli_serv(x509_cred, clicred, "NORMAL", "NORMAL", "localhost", NULL, NULL, NULL, 0, 1, GNUTLS_E_CERTIFICATE_REQUIRED, -1);
gnutls_certificate_free_credentials(clicred);
gnutls_certificate_free_credentials(x509_cred);