diff options
author | Nikos Mavrogiannopoulos <nmav@gnutls.org> | 2016-10-22 09:41:45 +0200 |
---|---|---|
committer | Nikos Mavrogiannopoulos <nmav@gnutls.org> | 2016-10-23 20:07:11 +0200 |
commit | f4287236cc686381b0f9f8435cc394ea673b06d1 (patch) | |
tree | f16d9351c5d5873a6033d733adebf15d929af99c /tests/set_x509_key_utf8.c | |
parent | a8c269964c2bd2a9edf9d6fe7b00481290fa9b13 (diff) | |
download | gnutls-tmp-document-api-change.tar.gz |
modified the gnutls_certificate_set_key* changetmp-document-api-change
While the change was fully backwards compatible for applications that were
adding a single certificate, and applications that were checking for negative
errors codes, many applications do not. As this may cause incompatibility issues
with software properly utilizing the previously documented API, the change
is reverted, and applications need to explicitly enable a flag (GNUTLS_CERTIFICATE_API_V2)
in the credentials structure for the set_key functions to return an index.
Diffstat (limited to 'tests/set_x509_key_utf8.c')
-rw-r--r-- | tests/set_x509_key_utf8.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/set_x509_key_utf8.c b/tests/set_x509_key_utf8.c index 496bd57c92..838ec84028 100644 --- a/tests/set_x509_key_utf8.c +++ b/tests/set_x509_key_utf8.c @@ -160,6 +160,8 @@ void doit(void) assert(gnutls_certificate_allocate_credentials(&clicred) >= 0); assert(gnutls_certificate_allocate_credentials(&x509_cred)>=0); + gnutls_certificate_set_flags(x509_cred, GNUTLS_CERTIFICATE_API_V2); + ret = gnutls_certificate_set_x509_trust_mem(clicred, &ca3_cert, GNUTLS_X509_FMT_PEM); if (ret < 0) fail("set_x509_trust_file failed: %s\n", gnutls_strerror(ret)); |