Paul Bakker | 5121ce5 | 2009-01-03 21:22:43 +0000 | [diff] [blame] | 1 | /* |
| 2 | * Self-test demonstration program |
| 3 | * |
Manuel Pégourié-Gonnard | 6fb8187 | 2015-07-27 11:11:48 +0200 | [diff] [blame] | 4 | * Copyright (C) 2006-2015, ARM Limited, All Rights Reserved |
Manuel Pégourié-Gonnard | 37ff140 | 2015-09-04 14:21:07 +0200 | [diff] [blame] | 5 | * SPDX-License-Identifier: Apache-2.0 |
| 6 | * |
| 7 | * Licensed under the Apache License, Version 2.0 (the "License"); you may |
| 8 | * not use this file except in compliance with the License. |
| 9 | * You may obtain a copy of the License at |
| 10 | * |
| 11 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 12 | * |
| 13 | * Unless required by applicable law or agreed to in writing, software |
| 14 | * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT |
| 15 | * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 16 | * See the License for the specific language governing permissions and |
| 17 | * limitations under the License. |
Paul Bakker | b96f154 | 2010-07-18 20:36:00 +0000 | [diff] [blame] | 18 | * |
Manuel Pégourié-Gonnard | fe44643 | 2015-03-06 13:17:10 +0000 | [diff] [blame] | 19 | * This file is part of mbed TLS (https://tls.mbed.org) |
Paul Bakker | 5121ce5 | 2009-01-03 21:22:43 +0000 | [diff] [blame] | 20 | */ |
| 21 | |
Manuel Pégourié-Gonnard | 2cf5a7c | 2015-04-08 12:49:31 +0200 | [diff] [blame] | 22 | #if !defined(MBEDTLS_CONFIG_FILE) |
Manuel Pégourié-Gonnard | 7f80997 | 2015-03-09 17:05:11 +0000 | [diff] [blame] | 23 | #include "mbedtls/config.h" |
Manuel Pégourié-Gonnard | cef4ad2 | 2014-04-29 12:39:06 +0200 | [diff] [blame] | 24 | #else |
Manuel Pégourié-Gonnard | 2cf5a7c | 2015-04-08 12:49:31 +0200 | [diff] [blame] | 25 | #include MBEDTLS_CONFIG_FILE |
Manuel Pégourié-Gonnard | cef4ad2 | 2014-04-29 12:39:06 +0200 | [diff] [blame] | 26 | #endif |
Paul Bakker | 5121ce5 | 2009-01-03 21:22:43 +0000 | [diff] [blame] | 27 | |
Manuel Pégourié-Gonnard | 7f80997 | 2015-03-09 17:05:11 +0000 | [diff] [blame] | 28 | #include "mbedtls/entropy.h" |
| 29 | #include "mbedtls/hmac_drbg.h" |
| 30 | #include "mbedtls/ctr_drbg.h" |
| 31 | #include "mbedtls/dhm.h" |
| 32 | #include "mbedtls/gcm.h" |
| 33 | #include "mbedtls/ccm.h" |
| 34 | #include "mbedtls/md2.h" |
| 35 | #include "mbedtls/md4.h" |
| 36 | #include "mbedtls/md5.h" |
| 37 | #include "mbedtls/ripemd160.h" |
| 38 | #include "mbedtls/sha1.h" |
| 39 | #include "mbedtls/sha256.h" |
| 40 | #include "mbedtls/sha512.h" |
| 41 | #include "mbedtls/arc4.h" |
| 42 | #include "mbedtls/des.h" |
| 43 | #include "mbedtls/aes.h" |
| 44 | #include "mbedtls/camellia.h" |
| 45 | #include "mbedtls/base64.h" |
| 46 | #include "mbedtls/bignum.h" |
| 47 | #include "mbedtls/rsa.h" |
| 48 | #include "mbedtls/x509.h" |
| 49 | #include "mbedtls/xtea.h" |
| 50 | #include "mbedtls/pkcs5.h" |
Manuel Pégourié-Gonnard | 7f80997 | 2015-03-09 17:05:11 +0000 | [diff] [blame] | 51 | #include "mbedtls/ecp.h" |
| 52 | #include "mbedtls/timing.h" |
Paul Bakker | 5121ce5 | 2009-01-03 21:22:43 +0000 | [diff] [blame] | 53 | |
Rich Evans | 18b78c7 | 2015-02-11 14:06:19 +0000 | [diff] [blame] | 54 | #include <stdio.h> |
| 55 | #include <string.h> |
| 56 | |
Manuel Pégourié-Gonnard | 2cf5a7c | 2015-04-08 12:49:31 +0200 | [diff] [blame] | 57 | #if defined(MBEDTLS_PLATFORM_C) |
Manuel Pégourié-Gonnard | 7f80997 | 2015-03-09 17:05:11 +0000 | [diff] [blame] | 58 | #include "mbedtls/platform.h" |
Rich Evans | 18b78c7 | 2015-02-11 14:06:19 +0000 | [diff] [blame] | 59 | #else |
| 60 | #include <stdio.h> |
Manuel Pégourié-Gonnard | 2cf5a7c | 2015-04-08 12:49:31 +0200 | [diff] [blame] | 61 | #define mbedtls_printf printf |
Manuel Pégourié-Gonnard | 7b6dcbe | 2015-06-22 10:48:01 +0200 | [diff] [blame] | 62 | #define mbedtls_snprintf snprintf |
Rich Evans | 18b78c7 | 2015-02-11 14:06:19 +0000 | [diff] [blame] | 63 | #endif |
| 64 | |
Manuel Pégourié-Gonnard | 2cf5a7c | 2015-04-08 12:49:31 +0200 | [diff] [blame] | 65 | #if defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C) |
Manuel Pégourié-Gonnard | 7f80997 | 2015-03-09 17:05:11 +0000 | [diff] [blame] | 66 | #include "mbedtls/memory_buffer_alloc.h" |
Paul Bakker | 6e339b5 | 2013-07-03 13:37:05 +0200 | [diff] [blame] | 67 | #endif |
| 68 | |
Manuel Pégourié-Gonnard | 7b6dcbe | 2015-06-22 10:48:01 +0200 | [diff] [blame] | 69 | static int test_snprintf( size_t n, const char ref_buf[10], int ref_ret ) |
| 70 | { |
| 71 | int ret; |
| 72 | char buf[10] = "xxxxxxxxx"; |
Manuel Pégourié-Gonnard | 4b00f08 | 2015-06-26 11:24:32 +0200 | [diff] [blame] | 73 | const char ref[10] = "xxxxxxxxx"; |
Manuel Pégourié-Gonnard | 7b6dcbe | 2015-06-22 10:48:01 +0200 | [diff] [blame] | 74 | |
| 75 | ret = mbedtls_snprintf( buf, n, "%s", "123" ); |
| 76 | if( ret < 0 || (size_t) ret >= n ) |
| 77 | ret = -1; |
| 78 | |
Manuel Pégourié-Gonnard | 4b00f08 | 2015-06-26 11:24:32 +0200 | [diff] [blame] | 79 | if( strncmp( ref_buf, buf, sizeof( buf ) ) != 0 || |
| 80 | ref_ret != ret || |
| 81 | memcmp( buf + n, ref + n, sizeof( buf ) - n ) != 0 ) |
Manuel Pégourié-Gonnard | 7b6dcbe | 2015-06-22 10:48:01 +0200 | [diff] [blame] | 82 | { |
| 83 | return( 1 ); |
| 84 | } |
| 85 | |
| 86 | return( 0 ); |
| 87 | } |
| 88 | |
| 89 | static int run_test_snprintf( void ) |
| 90 | { |
| 91 | return( test_snprintf( 0, "xxxxxxxxx", -1 ) != 0 || |
Manuel Pégourié-Gonnard | 4b00f08 | 2015-06-26 11:24:32 +0200 | [diff] [blame] | 92 | test_snprintf( 1, "", -1 ) != 0 || |
| 93 | test_snprintf( 2, "1", -1 ) != 0 || |
| 94 | test_snprintf( 3, "12", -1 ) != 0 || |
| 95 | test_snprintf( 4, "123", 3 ) != 0 || |
| 96 | test_snprintf( 5, "123", 3 ) != 0 ); |
Manuel Pégourié-Gonnard | 7b6dcbe | 2015-06-22 10:48:01 +0200 | [diff] [blame] | 97 | } |
| 98 | |
Gilles Peskine | 9d7dfb7 | 2017-12-20 20:23:46 +0100 | [diff] [blame] | 99 | #if defined(MBEDTLS_SELF_TEST) |
| 100 | #if defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C) |
| 101 | int mbedtls_memory_buffer_alloc_free_and_self_test( int verbose ) |
| 102 | { |
| 103 | if( verbose != 0 ) |
| 104 | { |
| 105 | #if defined(MBEDTLS_MEMORY_DEBUG) |
| 106 | mbedtls_memory_buffer_alloc_status( ); |
| 107 | #endif |
| 108 | } |
| 109 | mbedtls_memory_buffer_alloc_free( ); |
| 110 | return( mbedtls_memory_buffer_alloc_self_test( verbose ) ); |
| 111 | } |
| 112 | #endif |
| 113 | |
| 114 | typedef struct |
| 115 | { |
| 116 | const char *name; |
| 117 | int ( *function )( int ); |
| 118 | } selftest_t; |
| 119 | |
| 120 | const selftest_t selftests[] = |
| 121 | { |
| 122 | #if defined(MBEDTLS_MD2_C) |
| 123 | {"md2", mbedtls_md2_self_test}, |
| 124 | #endif |
| 125 | #if defined(MBEDTLS_MD4_C) |
| 126 | {"md4", mbedtls_md4_self_test}, |
| 127 | #endif |
| 128 | #if defined(MBEDTLS_MD5_C) |
| 129 | {"md5", mbedtls_md5_self_test}, |
| 130 | #endif |
| 131 | #if defined(MBEDTLS_RIPEMD160_C) |
| 132 | {"ripemd160", mbedtls_ripemd160_self_test}, |
| 133 | #endif |
| 134 | #if defined(MBEDTLS_SHA1_C) |
| 135 | {"sha1", mbedtls_sha1_self_test}, |
| 136 | #endif |
| 137 | #if defined(MBEDTLS_SHA256_C) |
| 138 | {"sha256", mbedtls_sha256_self_test}, |
| 139 | #endif |
| 140 | #if defined(MBEDTLS_SHA512_C) |
| 141 | {"sha512", mbedtls_sha512_self_test}, |
| 142 | #endif |
| 143 | #if defined(MBEDTLS_ARC4_C) |
| 144 | {"arc4", mbedtls_arc4_self_test}, |
| 145 | #endif |
| 146 | #if defined(MBEDTLS_DES_C) |
| 147 | {"des", mbedtls_des_self_test}, |
| 148 | #endif |
| 149 | #if defined(MBEDTLS_AES_C) |
| 150 | {"aes", mbedtls_aes_self_test}, |
| 151 | #endif |
| 152 | #if defined(MBEDTLS_GCM_C) && defined(MBEDTLS_AES_C) |
| 153 | {"gcm", mbedtls_gcm_self_test}, |
| 154 | #endif |
| 155 | #if defined(MBEDTLS_CCM_C) && defined(MBEDTLS_AES_C) |
| 156 | {"ccm", mbedtls_ccm_self_test}, |
| 157 | #endif |
| 158 | #if defined(MBEDTLS_BASE64_C) |
| 159 | {"base64", mbedtls_base64_self_test}, |
| 160 | #endif |
| 161 | #if defined(MBEDTLS_BIGNUM_C) |
| 162 | {"mpi", mbedtls_mpi_self_test}, |
| 163 | #endif |
| 164 | #if defined(MBEDTLS_RSA_C) |
| 165 | {"rsa", mbedtls_rsa_self_test}, |
| 166 | #endif |
| 167 | #if defined(MBEDTLS_X509_USE_C) |
| 168 | {"x509", mbedtls_x509_self_test}, |
| 169 | #endif |
| 170 | #if defined(MBEDTLS_XTEA_C) |
| 171 | {"xtea", mbedtls_xtea_self_test}, |
| 172 | #endif |
| 173 | #if defined(MBEDTLS_CAMELLIA_C) |
| 174 | {"camellia", mbedtls_camellia_self_test}, |
| 175 | #endif |
| 176 | #if defined(MBEDTLS_CTR_DRBG_C) |
| 177 | {"ctr_drbg", mbedtls_ctr_drbg_self_test}, |
| 178 | #endif |
| 179 | #if defined(MBEDTLS_HMAC_DRBG_C) |
| 180 | {"hmac_drbg", mbedtls_hmac_drbg_self_test}, |
| 181 | #endif |
| 182 | #if defined(MBEDTLS_ECP_C) |
| 183 | {"ecp", mbedtls_ecp_self_test}, |
| 184 | #endif |
| 185 | #if defined(MBEDTLS_DHM_C) |
| 186 | {"dhm", mbedtls_dhm_self_test}, |
| 187 | #endif |
| 188 | #if defined(MBEDTLS_ENTROPY_C) |
| 189 | {"entropy", mbedtls_entropy_self_test}, |
| 190 | #endif |
| 191 | #if defined(MBEDTLS_PKCS5_C) |
| 192 | {"pkcs5", mbedtls_pkcs5_self_test}, |
| 193 | #endif |
| 194 | /* Slower test after the faster ones */ |
| 195 | #if defined(MBEDTLS_TIMING_C) |
| 196 | {"timing", mbedtls_timing_self_test}, |
| 197 | #endif |
| 198 | /* Heap test comes last */ |
| 199 | #if defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C) |
| 200 | {"memory_buffer_alloc", mbedtls_memory_buffer_alloc_free_and_self_test}, |
| 201 | #endif |
| 202 | {NULL, NULL} |
| 203 | }; |
| 204 | #endif /* MBEDTLS_SELF_TEST */ |
| 205 | |
Paul Bakker | 5121ce5 | 2009-01-03 21:22:43 +0000 | [diff] [blame] | 206 | int main( int argc, char *argv[] ) |
| 207 | { |
Gilles Peskine | 9d7dfb7 | 2017-12-20 20:23:46 +0100 | [diff] [blame] | 208 | #if defined(MBEDTLS_SELF_TEST) |
| 209 | const selftest_t *test; |
| 210 | #endif /* MBEDTLS_SELF_TEST */ |
Gilles Peskine | a66fb3f | 2017-12-20 18:09:27 +0100 | [diff] [blame^] | 211 | char **argp; |
| 212 | int v = 1; /* v=1 for verbose mode */ |
| 213 | int exclude_mode = 0; |
Gilles Peskine | 9d7dfb7 | 2017-12-20 20:23:46 +0100 | [diff] [blame] | 214 | int suites_tested = 0, suites_failed = 0; |
Gilles Peskine | edede44 | 2017-12-15 15:01:27 +0100 | [diff] [blame] | 215 | #if defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C) && defined(MBEDTLS_SELF_TEST) |
Paul Bakker | 6e339b5 | 2013-07-03 13:37:05 +0200 | [diff] [blame] | 216 | unsigned char buf[1000000]; |
| 217 | #endif |
Manuel Pégourié-Gonnard | d14acbc | 2015-05-29 11:26:37 +0200 | [diff] [blame] | 218 | void *pointer; |
| 219 | |
| 220 | /* |
| 221 | * The C standard doesn't guarantee that all-bits-0 is the representation |
| 222 | * of a NULL pointer. We do however use that in our code for initializing |
| 223 | * structures, which should work on every modern platform. Let's be sure. |
| 224 | */ |
| 225 | memset( &pointer, 0, sizeof( void * ) ); |
| 226 | if( pointer != NULL ) |
| 227 | { |
| 228 | mbedtls_printf( "all-bits-zero is not a NULL pointer\n" ); |
Gilles Peskine | 6d51b63 | 2017-12-20 20:25:03 +0100 | [diff] [blame] | 229 | return( EXIT_FAILURE ); |
Manuel Pégourié-Gonnard | d14acbc | 2015-05-29 11:26:37 +0200 | [diff] [blame] | 230 | } |
Paul Bakker | 5121ce5 | 2009-01-03 21:22:43 +0000 | [diff] [blame] | 231 | |
Manuel Pégourié-Gonnard | 7b6dcbe | 2015-06-22 10:48:01 +0200 | [diff] [blame] | 232 | /* |
| 233 | * Make sure we have a snprintf that correctly zero-terminates |
| 234 | */ |
| 235 | if( run_test_snprintf() != 0 ) |
| 236 | { |
| 237 | mbedtls_printf( "the snprintf implementation is broken\n" ); |
Gilles Peskine | 6d51b63 | 2017-12-20 20:25:03 +0100 | [diff] [blame] | 238 | return( EXIT_FAILURE ); |
Manuel Pégourié-Gonnard | 7b6dcbe | 2015-06-22 10:48:01 +0200 | [diff] [blame] | 239 | } |
| 240 | |
Gilles Peskine | a66fb3f | 2017-12-20 18:09:27 +0100 | [diff] [blame^] | 241 | for( argp = argv + ( argc >= 1 ? 1 : argc ); *argp != NULL; ++argp ) |
Gilles Peskine | edede44 | 2017-12-15 15:01:27 +0100 | [diff] [blame] | 242 | { |
Gilles Peskine | a66fb3f | 2017-12-20 18:09:27 +0100 | [diff] [blame^] | 243 | if( strcmp( *argp, "--quiet" ) == 0 || |
| 244 | strcmp( *argp, "-quiet" ) == 0 || |
| 245 | strcmp( *argp, "-q" ) == 0 ) |
| 246 | { |
| 247 | v = 0; |
| 248 | } |
| 249 | else if( strcmp( *argp, "--exclude" ) == 0 || |
| 250 | strcmp( *argp, "-x" ) == 0 ) |
| 251 | { |
| 252 | exclude_mode = 1; |
| 253 | } |
| 254 | else |
| 255 | break; |
Gilles Peskine | edede44 | 2017-12-15 15:01:27 +0100 | [diff] [blame] | 256 | } |
Gilles Peskine | a66fb3f | 2017-12-20 18:09:27 +0100 | [diff] [blame^] | 257 | |
| 258 | if( v != 0 ) |
Manuel Pégourié-Gonnard | 2cf5a7c | 2015-04-08 12:49:31 +0200 | [diff] [blame] | 259 | mbedtls_printf( "\n" ); |
Paul Bakker | 5121ce5 | 2009-01-03 21:22:43 +0000 | [diff] [blame] | 260 | |
Manuel Pégourié-Gonnard | 2cf5a7c | 2015-04-08 12:49:31 +0200 | [diff] [blame] | 261 | #if defined(MBEDTLS_SELF_TEST) |
Paul Bakker | 135b98e | 2011-05-25 11:13:47 +0000 | [diff] [blame] | 262 | |
Manuel Pégourié-Gonnard | 2cf5a7c | 2015-04-08 12:49:31 +0200 | [diff] [blame] | 263 | #if defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C) |
| 264 | mbedtls_memory_buffer_alloc_init( buf, sizeof(buf) ); |
Paul Bakker | 6e339b5 | 2013-07-03 13:37:05 +0200 | [diff] [blame] | 265 | #endif |
| 266 | |
Gilles Peskine | a66fb3f | 2017-12-20 18:09:27 +0100 | [diff] [blame^] | 267 | if( *argp != NULL && exclude_mode == 0 ) |
Gilles Peskine | 9d7dfb7 | 2017-12-20 20:23:46 +0100 | [diff] [blame] | 268 | { |
Gilles Peskine | edede44 | 2017-12-15 15:01:27 +0100 | [diff] [blame] | 269 | /* Run the specified tests */ |
| 270 | for( ; *argp != NULL; argp++ ) |
Gilles Peskine | 9d7dfb7 | 2017-12-20 20:23:46 +0100 | [diff] [blame] | 271 | { |
Gilles Peskine | edede44 | 2017-12-15 15:01:27 +0100 | [diff] [blame] | 272 | for( test = selftests; test->name != NULL; test++ ) |
| 273 | { |
| 274 | if( !strcmp( *argp, test->name ) ) |
| 275 | { |
| 276 | if( test->function( v ) != 0 ) |
| 277 | { |
| 278 | suites_failed++; |
| 279 | } |
| 280 | suites_tested++; |
| 281 | break; |
| 282 | } |
| 283 | } |
| 284 | if( test->name == NULL ) |
| 285 | { |
| 286 | mbedtls_printf( " Test suite %s not available -> failed\n\n", *argp ); |
| 287 | suites_failed++; |
| 288 | } |
Gilles Peskine | 9d7dfb7 | 2017-12-20 20:23:46 +0100 | [diff] [blame] | 289 | } |
Gilles Peskine | edede44 | 2017-12-15 15:01:27 +0100 | [diff] [blame] | 290 | } |
| 291 | else |
| 292 | { |
Gilles Peskine | a66fb3f | 2017-12-20 18:09:27 +0100 | [diff] [blame^] | 293 | /* Run all the tests except excluded ones */ |
Gilles Peskine | edede44 | 2017-12-15 15:01:27 +0100 | [diff] [blame] | 294 | for( test = selftests; test->name != NULL; test++ ) |
| 295 | { |
Gilles Peskine | a66fb3f | 2017-12-20 18:09:27 +0100 | [diff] [blame^] | 296 | if( exclude_mode ) |
| 297 | { |
| 298 | char **excluded; |
| 299 | for( excluded = argp; *excluded != NULL; ++excluded ) |
| 300 | { |
| 301 | if( !strcmp( *excluded, test->name ) ) |
| 302 | break; |
| 303 | } |
| 304 | if( *excluded ) |
| 305 | { |
| 306 | if( v ) |
| 307 | mbedtls_printf( " Skip: %s\n", test->name ); |
| 308 | continue; |
| 309 | } |
| 310 | } |
Gilles Peskine | edede44 | 2017-12-15 15:01:27 +0100 | [diff] [blame] | 311 | if( test->function( v ) != 0 ) |
| 312 | { |
| 313 | suites_failed++; |
| 314 | } |
| 315 | suites_tested++; |
| 316 | } |
Gilles Peskine | 9d7dfb7 | 2017-12-20 20:23:46 +0100 | [diff] [blame] | 317 | } |
Manuel Pégourié-Gonnard | 470fc93 | 2014-03-27 20:07:08 +0100 | [diff] [blame] | 318 | |
Paul Bakker | 135b98e | 2011-05-25 11:13:47 +0000 | [diff] [blame] | 319 | #else |
Gilles Peskine | a66fb3f | 2017-12-20 18:09:27 +0100 | [diff] [blame^] | 320 | (void) exclude_mode; |
Manuel Pégourié-Gonnard | 2cf5a7c | 2015-04-08 12:49:31 +0200 | [diff] [blame] | 321 | mbedtls_printf( " MBEDTLS_SELF_TEST not defined.\n" ); |
Paul Bakker | 135b98e | 2011-05-25 11:13:47 +0000 | [diff] [blame] | 322 | #endif |
| 323 | |
Paul Bakker | 5121ce5 | 2009-01-03 21:22:43 +0000 | [diff] [blame] | 324 | if( v != 0 ) |
| 325 | { |
Gilles Peskine | 9d7dfb7 | 2017-12-20 20:23:46 +0100 | [diff] [blame] | 326 | mbedtls_printf( " Executed %d test suites\n\n", suites_tested ); |
Paul Bakker | 6e339b5 | 2013-07-03 13:37:05 +0200 | [diff] [blame] | 327 | |
Gilles Peskine | 9d7dfb7 | 2017-12-20 20:23:46 +0100 | [diff] [blame] | 328 | if( suites_failed > 0) |
| 329 | { |
| 330 | mbedtls_printf( " [ %d tests FAILED ]\n\n", suites_failed ); |
| 331 | } |
| 332 | else |
| 333 | { |
| 334 | mbedtls_printf( " [ All tests passed ]\n\n" ); |
| 335 | } |
Paul Bakker | cce9d77 | 2011-11-18 14:26:47 +0000 | [diff] [blame] | 336 | #if defined(_WIN32) |
Manuel Pégourié-Gonnard | 2cf5a7c | 2015-04-08 12:49:31 +0200 | [diff] [blame] | 337 | mbedtls_printf( " Press Enter to exit this program.\n" ); |
Paul Bakker | 5121ce5 | 2009-01-03 21:22:43 +0000 | [diff] [blame] | 338 | fflush( stdout ); getchar(); |
| 339 | #endif |
| 340 | } |
Paul Bakker | 5121ce5 | 2009-01-03 21:22:43 +0000 | [diff] [blame] | 341 | |
Gilles Peskine | 9d7dfb7 | 2017-12-20 20:23:46 +0100 | [diff] [blame] | 342 | if( suites_failed > 0) |
| 343 | return( EXIT_FAILURE ); |
| 344 | |
| 345 | return( EXIT_SUCCESS ); |
Paul Bakker | 5121ce5 | 2009-01-03 21:22:43 +0000 | [diff] [blame] | 346 | } |