1 /* 2 * Copyright (C) 2017 Red Hat 3 * 4 * Author: Nikos Mavrogiannopoulos 5 * 6 * This file is part of GnuTLS. 7 * 8 * GnuTLS is free software; you can redistribute it and/or modify it 9 * under the terms of the GNU General Public License as published by 10 * the Free Software Foundation; either version 3 of the License, or 11 * (at your option) any later version. 12 * 13 * GnuTLS is distributed in the hope that it will be useful, but 14 * WITHOUT ANY WARRANTY; without even the implied warranty of 15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 16 * General Public License for more details. 17 * 18 * You should have received a copy of the GNU General Public License 19 * along with GnuTLS; if not, write to the Free Software Foundation, 20 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA 21 */ 22 23 #ifdef HAVE_CONFIG_H 24 #include <config.h> 25 #endif 26 27 #include <stdlib.h> 28 #include <stdio.h> 29 #include <string.h> 30 #include <gnutls/gnutls.h> 31 #include <gnutls/dane.h> 32 #include <assert.h> 33 34 #include "utils.h" 35 doit(void)36void doit(void) 37 { 38 assert(gnutls_certificate_verification_profile_get_id("very weak") == GNUTLS_PROFILE_VERY_WEAK); 39 assert(gnutls_certificate_verification_profile_get_id("low") == GNUTLS_PROFILE_LOW); 40 assert(gnutls_certificate_verification_profile_get_id("legacy") == GNUTLS_PROFILE_LEGACY); 41 assert(gnutls_certificate_verification_profile_get_id("MedIum") == GNUTLS_PROFILE_MEDIUM); 42 assert(gnutls_certificate_verification_profile_get_id("ultra") == GNUTLS_PROFILE_ULTRA); 43 assert(gnutls_certificate_verification_profile_get_id("future") == GNUTLS_PROFILE_FUTURE); 44 assert(gnutls_certificate_verification_profile_get_id("xxx") == GNUTLS_PROFILE_UNKNOWN); 45 } 46