Merge pull request #304 from mrdeep1/no-ca-gnutls-3-6

Support for clients with no PKI or PSK defined for GnuTLS > 3.6 and coaps
This commit is contained in:
obgm authored and GitHub committed 2019-03-01 13:20:52 +01:00
commit db24e760e0
1 file changed
+5
+5
View File
@@ -709,6 +709,11 @@ setup_pki_credentials(gnutls_certificate_credentials_t *pki_credentials,
"gnutls_certificate_set_x509_trust_dir");
#endif
}
if (!(g_context->psk_pki_enabled & IS_PKI)) {
/* No PKI defined at all - still need a trust set up for 3.6.0 or later */
G_CHECK(gnutls_certificate_set_x509_system_trust(*pki_credentials),
"gnutls_certificate_set_x509_system_trust");
}
/* Verify Peer */
if (setup_data->verify_peer_cert) {