OpenCoverage

cryptlib.h

Absolute File Name:/home/opencoverage/opencoverage/guest-scripts/openssl/src/include/internal/cryptlib.h
Source codeSwitch to Preprocessed file
LineSourceCount
1/*-
2 * Copyright 1995-2018 The OpenSSL Project Authors. All Rights Reserved.-
3 *-
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-
8 */-
9-
10#ifndef HEADER_CRYPTLIB_H-
11# define HEADER_CRYPTLIB_H-
12-
13# include <stdlib.h>-
14# include <string.h>-
15-
16# ifdef OPENSSL_USE_APPLINK-
17# undef BIO_FLAGS_UPLINK-
18# define BIO_FLAGS_UPLINK 0x8000-
19# include "ms/uplink.h"-
20# endif-
21-
22# include <openssl/crypto.h>-
23# include <openssl/buffer.h>-
24# include <openssl/bio.h>-
25# include <openssl/err.h>-
26# include "internal/nelem.h"-
27-
28#ifdef NDEBUG-
29# define ossl_assert(x) ((x) != 0)-
30#else-
31__owur static ossl_inline int ossl_assert_int(int expr, const char *exprstr,-
32 const char *file, int line)-
33{-
34 if (!expr)-
35 OPENSSL_die(exprstr, file, line);-
36-
37 return expr;-
38}-
39-
40# define ossl_assert(x) ossl_assert_int((x) != 0, "Assertion failed: "#x, \-
41 __FILE__, __LINE__)-
42-
43#endif-
44-
45typedef struct ex_callback_st EX_CALLBACK;-
46-
47DEFINE_STACK_OF(EX_CALLBACK)
never executed: end of block
never executed: end of block
executed 33216 times by 12 tests: end of block
Executed by:
  • asn1_internal_test
  • chacha_internal_test
  • ctype_internal_test
  • curve448_internal_test
  • libcrypto.so.1.1
  • modes_internal_test
  • poly1305_internal_test
  • rdrand_sanitytest
  • siphash_internal_test
  • sm2_internal_test
  • sm4_internal_test
  • x509_internal_test
never executed: end of block
executed 771167 times by 12 tests: return OPENSSL_sk_num((const OPENSSL_STACK *)sk);
Executed by:
  • asn1_internal_test
  • chacha_internal_test
  • ctype_internal_test
  • curve448_internal_test
  • libcrypto.so.1.1
  • modes_internal_test
  • poly1305_internal_test
  • rdrand_sanitytest
  • siphash_internal_test
  • sm2_internal_test
  • sm4_internal_test
  • x509_internal_test
executed 1012673 times by 1 test: return (EX_CALLBACK *)OPENSSL_sk_value((const OPENSSL_STACK *)sk, idx);
Executed by:
  • libcrypto.so.1.1
never executed: return (struct stack_st_EX_CALLBACK *)OPENSSL_sk_new((OPENSSL_sk_compfunc)compare);
executed 937 times by 1 test: return (struct stack_st_EX_CALLBACK *)OPENSSL_sk_new_null();
Executed by:
  • libcrypto.so.1.1
never executed: return (struct stack_st_EX_CALLBACK *)OPENSSL_sk_new_reserve((OPENSSL_sk_compfunc)compare, n);
never executed: return OPENSSL_sk_reserve((OPENSSL_STACK *)sk, n);
never executed: return (EX_CALLBACK *)OPENSSL_sk_delete((OPENSSL_STACK *)sk, i);
never executed: return (EX_CALLBACK *)OPENSSL_sk_delete_ptr((OPENSSL_STACK *)sk, (const void *)ptr);
executed 3059 times by 1 test: return OPENSSL_sk_push((OPENSSL_STACK *)sk, (const void *)ptr);
Executed by:
  • libcrypto.so.1.1
never executed: return OPENSSL_sk_unshift((OPENSSL_STACK *)sk, (const void *)ptr);
never executed: return (EX_CALLBACK *)OPENSSL_sk_pop((OPENSSL_STACK *)sk);
never executed: return (EX_CALLBACK *)OPENSSL_sk_shift((OPENSSL_STACK *)sk);
never executed: return OPENSSL_sk_insert((OPENSSL_STACK *)sk, (const void *)ptr, idx);
executed 2122 times by 1 test: return (EX_CALLBACK *)OPENSSL_sk_set((OPENSSL_STACK *)sk, idx, (const void *)ptr);
Executed by:
  • libcrypto.so.1.1
never executed: return OPENSSL_sk_find((OPENSSL_STACK *)sk, (const void *)ptr);
never executed: return OPENSSL_sk_find_ex((OPENSSL_STACK *)sk, (const void *)ptr);
never executed: return OPENSSL_sk_is_sorted((const OPENSSL_STACK *)sk);
never executed: return (struct stack_st_EX_CALLBACK *)OPENSSL_sk_dup((const OPENSSL_STACK *)sk);
never executed: return (struct stack_st_EX_CALLBACK *)OPENSSL_sk_deep_copy((const OPENSSL_STACK *)sk, (OPENSSL_sk_copyfunc)copyfunc, (OPENSSL_sk_freefunc)freefunc);
never executed: return (sk_EX_CALLBACK_compfunc)OPENSSL_sk_set_cmp_func((OPENSSL_STACK *)sk, (OPENSSL_sk_compfunc)compare);
0-1012673
48-
49typedef struct app_mem_info_st APP_INFO;-
50-
51typedef struct mem_st MEM;-
52DEFINE_LHASH_OF(MEM);
never executed: end of block
never executed: end of block
never executed: end of block
never executed: end of block
never executed: end of block
never executed: end of block
never executed: return (struct lhash_st_MEM *) OPENSSL_LH_new((OPENSSL_LH_HASHFUNC)hfn, (OPENSSL_LH_COMPFUNC)cfn);
never executed: return (MEM *)OPENSSL_LH_insert((OPENSSL_LHASH *)lh, d);
never executed: return (MEM *)OPENSSL_LH_delete((OPENSSL_LHASH *)lh, d);
never executed: return (MEM *)OPENSSL_LH_retrieve((OPENSSL_LHASH *)lh, d);
never executed: return OPENSSL_LH_error((OPENSSL_LHASH *)lh);
never executed: return OPENSSL_LH_num_items((OPENSSL_LHASH *)lh);
never executed: return OPENSSL_LH_get_down_load((OPENSSL_LHASH *)lh);
0
53-
54# define OPENSSL_CONF "openssl.cnf"-
55-
56# ifndef OPENSSL_SYS_VMS-
57# define X509_CERT_AREA OPENSSLDIR-
58# define X509_CERT_DIR OPENSSLDIR "/certs"-
59# define X509_CERT_FILE OPENSSLDIR "/cert.pem"-
60# define X509_PRIVATE_DIR OPENSSLDIR "/private"-
61# define CTLOG_FILE OPENSSLDIR "/ct_log_list.cnf"-
62# else-
63# define X509_CERT_AREA "OSSL$DATAROOT:[000000]"-
64# define X509_CERT_DIR "OSSL$DATAROOT:[CERTS]"-
65# define X509_CERT_FILE "OSSL$DATAROOT:[000000]cert.pem"-
66# define X509_PRIVATE_DIR "OSSL$DATAROOT:[PRIVATE]"-
67# define CTLOG_FILE "OSSL$DATAROOT:[000000]ct_log_list.cnf"-
68# endif-
69-
70# define X509_CERT_DIR_EVP "SSL_CERT_DIR"-
71# define X509_CERT_FILE_EVP "SSL_CERT_FILE"-
72# define CTLOG_FILE_EVP "CTLOG_FILE"-
73-
74/* size of string representations */-
75# define DECIMAL_SIZE(type) ((sizeof(type)*8+2)/3+1)-
76# define HEX_SIZE(type) (sizeof(type)*2)-
77-
78void OPENSSL_cpuid_setup(void);-
79extern unsigned int OPENSSL_ia32cap_P[];-
80void OPENSSL_showfatal(const char *fmta, ...);-
81void crypto_cleanup_all_ex_data_int(void);-
82int openssl_init_fork_handlers(void);-
83-
84extern CRYPTO_RWLOCK *memdbg_lock;-
85int openssl_strerror_r(int errnum, char *buf, size_t buflen);-
86# if !defined(OPENSSL_NO_STDIO)-
87FILE *openssl_fopen(const char *filename, const char *mode);-
88# else-
89void *openssl_fopen(const char *filename, const char *mode);-
90# endif-
91-
92uint32_t OPENSSL_rdtsc(void);-
93-
94#endif-
Source codeSwitch to Preprocessed file

Generated by Squish Coco 4.2.2