]>
git.ipfire.org Git - thirdparty/openssl.git/blob - test/cipher_overhead_test.c
6bf74a5a7606f1df701c5de90f372ff5473b8d92
2 * Copyright 2016 The OpenSSL Project Authors. All Rights Reserved.
4 * Licensed under the OpenSSL license (the "License"). You may not use
5 * this file except in compliance with the License. You can obtain a copy
6 * in the file LICENSE in the source distribution or at
7 * https://www.openssl.org/source/license.html
15 # pragma names as_is,shortened
18 #include "../ssl/ssl_locl.h"
21 # pragma names restore
24 static int cipher_overhead(void)
26 int ret
= 1, i
, n
= ssl3_num_ciphers();
27 const SSL_CIPHER
*ciph
;
28 size_t mac
, in
, blk
, ex
;
30 for (i
= 0; i
< n
; i
++) {
31 ciph
= ssl3_get_cipher(i
);
34 if (!TEST_true(ssl_cipher_get_overhead(ciph
, &mac
, &in
, &blk
, &ex
))) {
35 TEST_info("Failed getting %s", ciph
->name
);
38 TEST_info("Cipher %s: %zu %zu %zu %zu",
39 ciph
->name
, mac
, in
, blk
, ex
);
45 void register_tests(void)
47 ADD_TEST(cipher_overhead
);