blob: 86a3d06bf151d23092f8b016977acf193646de10 [file] [log] [blame]
Paul Bakker5121ce52009-01-03 21:22:43 +00001/**
Simon Butcher5b331b92016-01-03 16:14:14 +00002 * \file sha1.h
Paul Bakkere0ccd0a2009-01-04 16:27:10 +00003 *
Rose Zadik82741422018-03-27 12:49:48 +01004 * \brief This file contains SHA-1 definitions and functions.
5 *
Darryl Green11999bb2018-03-13 15:22:58 +00006 * The Secure Hash Algorithm 1 (SHA-1) cryptographic hash function is defined in
Rose Zadik82741422018-03-27 12:49:48 +01007 * <em>FIPS 180-4: Secure Hash Standard (SHS)</em>.
Hanno Beckerbbca8c52017-09-25 14:53:51 +01008 *
9 * \warning SHA-1 is considered a weak message digest and its use constitutes
10 * a security risk. We recommend considering stronger message
11 * digests instead.
Darryl Greena40a1012018-01-05 15:33:17 +000012 */
13/*
Bence Szépkúti1e148272020-08-07 13:07:28 +020014 * Copyright The Mbed TLS Contributors
Manuel Pégourié-Gonnard37ff1402015-09-04 14:21:07 +020015 * SPDX-License-Identifier: Apache-2.0
16 *
17 * Licensed under the Apache License, Version 2.0 (the "License"); you may
18 * not use this file except in compliance with the License.
19 * You may obtain a copy of the License at
20 *
21 * http://www.apache.org/licenses/LICENSE-2.0
22 *
23 * Unless required by applicable law or agreed to in writing, software
24 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
25 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
26 * See the License for the specific language governing permissions and
27 * limitations under the License.
Paul Bakker5121ce52009-01-03 21:22:43 +000028 */
Manuel Pégourié-Gonnard2cf5a7c2015-04-08 12:49:31 +020029#ifndef MBEDTLS_SHA1_H
30#define MBEDTLS_SHA1_H
Paul Bakker5121ce52009-01-03 21:22:43 +000031
Manuel Pégourié-Gonnard2cf5a7c2015-04-08 12:49:31 +020032#if !defined(MBEDTLS_CONFIG_FILE)
Jaeden Ameroc49fbbf2019-07-04 20:01:14 +010033#include "mbedtls/config.h"
Manuel Pégourié-Gonnardcef4ad22014-04-29 12:39:06 +020034#else
Manuel Pégourié-Gonnard2cf5a7c2015-04-08 12:49:31 +020035#include MBEDTLS_CONFIG_FILE
Manuel Pégourié-Gonnardcef4ad22014-04-29 12:39:06 +020036#endif
Paul Bakker90995b52013-06-24 19:20:35 +020037
Rich Evans00ab4702015-02-06 13:43:58 +000038#include <stddef.h>
Manuel Pégourié-Gonnardab229102015-04-15 11:53:16 +020039#include <stdint.h>
Paul Bakker5c2364c2012-10-01 14:41:15 +000040
Ron Eldor9924bdc2018-10-04 10:59:13 +030041/* MBEDTLS_ERR_SHA1_HW_ACCEL_FAILED is deprecated and should not be used. */
Gilles Peskinea381fe82018-01-23 18:16:11 +010042#define MBEDTLS_ERR_SHA1_HW_ACCEL_FAILED -0x0035 /**< SHA-1 hardware accelerator failed */
Andrzej Kurekc470b6b2019-01-31 08:20:20 -050043#define MBEDTLS_ERR_SHA1_BAD_INPUT_DATA -0x0073 /**< SHA-1 input data was malformed. */
Gilles Peskinea381fe82018-01-23 18:16:11 +010044
Paul Bakker407a0da2013-06-27 14:29:21 +020045#ifdef __cplusplus
46extern "C" {
47#endif
48
Ron Eldorb2aacec2017-05-18 16:53:08 +030049#if !defined(MBEDTLS_SHA1_ALT)
50// Regular implementation
51//
52
Paul Bakker5121ce52009-01-03 21:22:43 +000053/**
Rose Zadik44833d92018-01-26 08:41:09 +000054 * \brief The SHA-1 context structure.
Hanno Beckerbbca8c52017-09-25 14:53:51 +010055 *
56 * \warning SHA-1 is considered a weak message digest and its use
57 * constitutes a security risk. We recommend considering
58 * stronger message digests instead.
59 *
Paul Bakker5121ce52009-01-03 21:22:43 +000060 */
Dawid Drozd428cc522018-07-24 10:02:47 +020061typedef struct mbedtls_sha1_context
Paul Bakker5121ce52009-01-03 21:22:43 +000062{
Rose Zadik44833d92018-01-26 08:41:09 +000063 uint32_t total[2]; /*!< The number of Bytes processed. */
64 uint32_t state[5]; /*!< The intermediate digest state. */
65 unsigned char buffer[64]; /*!< The data block being processed. */
Paul Bakker5121ce52009-01-03 21:22:43 +000066}
Manuel Pégourié-Gonnard2cf5a7c2015-04-08 12:49:31 +020067mbedtls_sha1_context;
Paul Bakker5121ce52009-01-03 21:22:43 +000068
Ron Eldorb2aacec2017-05-18 16:53:08 +030069#else /* MBEDTLS_SHA1_ALT */
70#include "sha1_alt.h"
71#endif /* MBEDTLS_SHA1_ALT */
72
Paul Bakker5121ce52009-01-03 21:22:43 +000073/**
Rose Zadik44833d92018-01-26 08:41:09 +000074 * \brief This function initializes a SHA-1 context.
Paul Bakker5b4af392014-06-26 12:09:34 +020075 *
Hanno Beckerbbca8c52017-09-25 14:53:51 +010076 * \warning SHA-1 is considered a weak message digest and its use
77 * constitutes a security risk. We recommend considering
78 * stronger message digests instead.
79 *
Rose Zadik82741422018-03-27 12:49:48 +010080 * \param ctx The SHA-1 context to initialize.
Andrzej Kurekc470b6b2019-01-31 08:20:20 -050081 * This must not be \c NULL.
Rose Zadik82741422018-03-27 12:49:48 +010082 *
Paul Bakker5b4af392014-06-26 12:09:34 +020083 */
Manuel Pégourié-Gonnard2cf5a7c2015-04-08 12:49:31 +020084void mbedtls_sha1_init( mbedtls_sha1_context *ctx );
Paul Bakker5b4af392014-06-26 12:09:34 +020085
86/**
Rose Zadik44833d92018-01-26 08:41:09 +000087 * \brief This function clears a SHA-1 context.
Paul Bakker5b4af392014-06-26 12:09:34 +020088 *
Hanno Beckerbbca8c52017-09-25 14:53:51 +010089 * \warning SHA-1 is considered a weak message digest and its use
90 * constitutes a security risk. We recommend considering
91 * stronger message digests instead.
92 *
Andrzej Kurekc470b6b2019-01-31 08:20:20 -050093 * \param ctx The SHA-1 context to clear. This may be \c NULL,
94 * in which case this function does nothing. If it is
95 * not \c NULL, it must point to an initialized
96 * SHA-1 context.
Rose Zadik82741422018-03-27 12:49:48 +010097 *
Paul Bakker5b4af392014-06-26 12:09:34 +020098 */
Manuel Pégourié-Gonnard2cf5a7c2015-04-08 12:49:31 +020099void mbedtls_sha1_free( mbedtls_sha1_context *ctx );
Paul Bakker5b4af392014-06-26 12:09:34 +0200100
101/**
Rose Zadik44833d92018-01-26 08:41:09 +0000102 * \brief This function clones the state of a SHA-1 context.
Manuel Pégourié-Gonnard16d412f2015-07-06 15:26:26 +0200103 *
Hanno Beckerbbca8c52017-09-25 14:53:51 +0100104 * \warning SHA-1 is considered a weak message digest and its use
105 * constitutes a security risk. We recommend considering
106 * stronger message digests instead.
107 *
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500108 * \param dst The SHA-1 context to clone to. This must be initialized.
109 * \param src The SHA-1 context to clone from. This must be initialized.
Rose Zadik82741422018-03-27 12:49:48 +0100110 *
Manuel Pégourié-Gonnard16d412f2015-07-06 15:26:26 +0200111 */
112void mbedtls_sha1_clone( mbedtls_sha1_context *dst,
113 const mbedtls_sha1_context *src );
114
115/**
Rose Zadik44833d92018-01-26 08:41:09 +0000116 * \brief This function starts a SHA-1 checksum calculation.
Paul Bakker5121ce52009-01-03 21:22:43 +0000117 *
Hanno Beckerbbca8c52017-09-25 14:53:51 +0100118 * \warning SHA-1 is considered a weak message digest and its use
119 * constitutes a security risk. We recommend considering
120 * stronger message digests instead.
121 *
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500122 * \param ctx The SHA-1 context to initialize. This must be initialized.
Rose Zadik82741422018-03-27 12:49:48 +0100123 *
124 * \return \c 0 on success.
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500125 * \return A negative error code on failure.
Rose Zadik82741422018-03-27 12:49:48 +0100126 *
Paul Bakker5121ce52009-01-03 21:22:43 +0000127 */
Gilles Peskine9e4f77c2018-01-22 11:48:08 +0100128int mbedtls_sha1_starts_ret( mbedtls_sha1_context *ctx );
Paul Bakker5121ce52009-01-03 21:22:43 +0000129
130/**
Rose Zadik44833d92018-01-26 08:41:09 +0000131 * \brief This function feeds an input buffer into an ongoing SHA-1
132 * checksum calculation.
Paul Bakker5121ce52009-01-03 21:22:43 +0000133 *
Hanno Beckerbbca8c52017-09-25 14:53:51 +0100134 * \warning SHA-1 is considered a weak message digest and its use
135 * constitutes a security risk. We recommend considering
136 * stronger message digests instead.
137 *
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500138 * \param ctx The SHA-1 context. This must be initialized
139 * and have a hash operation started.
Rose Zadik82741422018-03-27 12:49:48 +0100140 * \param input The buffer holding the input data.
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500141 * This must be a readable buffer of length \p ilen Bytes.
142 * \param ilen The length of the input data \p input in Bytes.
Rose Zadik82741422018-03-27 12:49:48 +0100143 *
144 * \return \c 0 on success.
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500145 * \return A negative error code on failure.
Paul Bakker5121ce52009-01-03 21:22:43 +0000146 */
Gilles Peskine9e4f77c2018-01-22 11:48:08 +0100147int mbedtls_sha1_update_ret( mbedtls_sha1_context *ctx,
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100148 const unsigned char *input,
149 size_t ilen );
Paul Bakker5121ce52009-01-03 21:22:43 +0000150
151/**
Rose Zadik44833d92018-01-26 08:41:09 +0000152 * \brief This function finishes the SHA-1 operation, and writes
153 * the result to the output buffer.
Paul Bakker5121ce52009-01-03 21:22:43 +0000154 *
Hanno Beckerbbca8c52017-09-25 14:53:51 +0100155 * \warning SHA-1 is considered a weak message digest and its use
156 * constitutes a security risk. We recommend considering
157 * stronger message digests instead.
158 *
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500159 * \param ctx The SHA-1 context to use. This must be initialized and
160 * have a hash operation started.
161 * \param output The SHA-1 checksum result. This must be a writable
162 * buffer of length \c 20 Bytes.
Rose Zadik82741422018-03-27 12:49:48 +0100163 *
164 * \return \c 0 on success.
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500165 * \return A negative error code on failure.
Paul Bakker5121ce52009-01-03 21:22:43 +0000166 */
Gilles Peskine9e4f77c2018-01-22 11:48:08 +0100167int mbedtls_sha1_finish_ret( mbedtls_sha1_context *ctx,
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100168 unsigned char output[20] );
Paul Bakker5121ce52009-01-03 21:22:43 +0000169
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100170/**
Rose Zadik82741422018-03-27 12:49:48 +0100171 * \brief SHA-1 process data block (internal use only).
Hanno Beckerbbca8c52017-09-25 14:53:51 +0100172 *
173 * \warning SHA-1 is considered a weak message digest and its use
174 * constitutes a security risk. We recommend considering
175 * stronger message digests instead.
176 *
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500177 * \param ctx The SHA-1 context to use. This must be initialized.
178 * \param data The data block being processed. This must be a
179 * readable buffer of length \c 64 Bytes.
Rose Zadik82741422018-03-27 12:49:48 +0100180 *
181 * \return \c 0 on success.
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500182 * \return A negative error code on failure.
Rose Zadik82741422018-03-27 12:49:48 +0100183 *
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100184 */
Andres Amaya Garciacccfe082017-06-28 10:36:39 +0100185int mbedtls_internal_sha1_process( mbedtls_sha1_context *ctx,
186 const unsigned char data[64] );
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100187
188#if !defined(MBEDTLS_DEPRECATED_REMOVED)
189#if defined(MBEDTLS_DEPRECATED_WARNING)
190#define MBEDTLS_DEPRECATED __attribute__((deprecated))
191#else
192#define MBEDTLS_DEPRECATED
193#endif
194/**
Rose Zadik82741422018-03-27 12:49:48 +0100195 * \brief This function starts a SHA-1 checksum calculation.
Hanno Beckerbbca8c52017-09-25 14:53:51 +0100196 *
197 * \warning SHA-1 is considered a weak message digest and its use
198 * constitutes a security risk. We recommend considering
199 * stronger message digests instead.
200 *
Rose Zadik82741422018-03-27 12:49:48 +0100201 * \deprecated Superseded by mbedtls_sha1_starts_ret() in 2.7.0.
202 *
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500203 * \param ctx The SHA-1 context to initialize. This must be initialized.
Rose Zadik82741422018-03-27 12:49:48 +0100204 *
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100205 */
Jaeden Amero041039f2018-02-19 15:28:08 +0000206MBEDTLS_DEPRECATED void mbedtls_sha1_starts( mbedtls_sha1_context *ctx );
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100207
208/**
Rose Zadik82741422018-03-27 12:49:48 +0100209 * \brief This function feeds an input buffer into an ongoing SHA-1
210 * checksum calculation.
Hanno Beckerbbca8c52017-09-25 14:53:51 +0100211 *
212 * \warning SHA-1 is considered a weak message digest and its use
213 * constitutes a security risk. We recommend considering
214 * stronger message digests instead.
215 *
Rose Zadik82741422018-03-27 12:49:48 +0100216 * \deprecated Superseded by mbedtls_sha1_update_ret() in 2.7.0.
217 *
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500218 * \param ctx The SHA-1 context. This must be initialized and
219 * have a hash operation started.
Rose Zadik82741422018-03-27 12:49:48 +0100220 * \param input The buffer holding the input data.
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500221 * This must be a readable buffer of length \p ilen Bytes.
222 * \param ilen The length of the input data \p input in Bytes.
Rose Zadik82741422018-03-27 12:49:48 +0100223 *
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100224 */
Jaeden Amero041039f2018-02-19 15:28:08 +0000225MBEDTLS_DEPRECATED void mbedtls_sha1_update( mbedtls_sha1_context *ctx,
226 const unsigned char *input,
227 size_t ilen );
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100228
229/**
Rose Zadik82741422018-03-27 12:49:48 +0100230 * \brief This function finishes the SHA-1 operation, and writes
231 * the result to the output buffer.
Hanno Beckerbbca8c52017-09-25 14:53:51 +0100232 *
233 * \warning SHA-1 is considered a weak message digest and its use
234 * constitutes a security risk. We recommend considering
235 * stronger message digests instead.
236 *
Rose Zadik82741422018-03-27 12:49:48 +0100237 * \deprecated Superseded by mbedtls_sha1_finish_ret() in 2.7.0.
238 *
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500239 * \param ctx The SHA-1 context. This must be initialized and
240 * have a hash operation started.
Rose Zadik82741422018-03-27 12:49:48 +0100241 * \param output The SHA-1 checksum result.
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500242 * This must be a writable buffer of length \c 20 Bytes.
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100243 */
Jaeden Amero041039f2018-02-19 15:28:08 +0000244MBEDTLS_DEPRECATED void mbedtls_sha1_finish( mbedtls_sha1_context *ctx,
245 unsigned char output[20] );
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100246
247/**
Rose Zadik82741422018-03-27 12:49:48 +0100248 * \brief SHA-1 process data block (internal use only).
Hanno Beckerbbca8c52017-09-25 14:53:51 +0100249 *
250 * \warning SHA-1 is considered a weak message digest and its use
251 * constitutes a security risk. We recommend considering
252 * stronger message digests instead.
253 *
Rose Zadik82741422018-03-27 12:49:48 +0100254 * \deprecated Superseded by mbedtls_internal_sha1_process() in 2.7.0.
255 *
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500256 * \param ctx The SHA-1 context. This must be initialized.
Rose Zadik82741422018-03-27 12:49:48 +0100257 * \param data The data block being processed.
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500258 * This must be a readable buffer of length \c 64 bytes.
Rose Zadik82741422018-03-27 12:49:48 +0100259 *
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100260 */
Jaeden Amero041039f2018-02-19 15:28:08 +0000261MBEDTLS_DEPRECATED void mbedtls_sha1_process( mbedtls_sha1_context *ctx,
262 const unsigned char data[64] );
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100263
264#undef MBEDTLS_DEPRECATED
265#endif /* !MBEDTLS_DEPRECATED_REMOVED */
Paul Bakker90995b52013-06-24 19:20:35 +0200266
Paul Bakker5121ce52009-01-03 21:22:43 +0000267/**
Rose Zadik44833d92018-01-26 08:41:09 +0000268 * \brief This function calculates the SHA-1 checksum of a buffer.
Paul Bakker5121ce52009-01-03 21:22:43 +0000269 *
Rose Zadik44833d92018-01-26 08:41:09 +0000270 * The function allocates the context, performs the
271 * calculation, and frees the context.
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100272 *
Rose Zadik44833d92018-01-26 08:41:09 +0000273 * The SHA-1 result is calculated as
274 * output = SHA-1(input buffer).
275 *
Rose Zadik82741422018-03-27 12:49:48 +0100276 * \warning SHA-1 is considered a weak message digest and its use
277 * constitutes a security risk. We recommend considering
278 * stronger message digests instead.
279 *
Rose Zadik44833d92018-01-26 08:41:09 +0000280 * \param input The buffer holding the input data.
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500281 * This must be a readable buffer of length \p ilen Bytes.
282 * \param ilen The length of the input data \p input in Bytes.
Rose Zadik44833d92018-01-26 08:41:09 +0000283 * \param output The SHA-1 checksum result.
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500284 * This must be a writable buffer of length \c 20 Bytes.
Rose Zadik44833d92018-01-26 08:41:09 +0000285 *
Rose Zadik82741422018-03-27 12:49:48 +0100286 * \return \c 0 on success.
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500287 * \return A negative error code on failure.
Hanno Beckerbbca8c52017-09-25 14:53:51 +0100288 *
Paul Bakker5121ce52009-01-03 21:22:43 +0000289 */
Gilles Peskine9e4f77c2018-01-22 11:48:08 +0100290int mbedtls_sha1_ret( const unsigned char *input,
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100291 size_t ilen,
292 unsigned char output[20] );
293
294#if !defined(MBEDTLS_DEPRECATED_REMOVED)
295#if defined(MBEDTLS_DEPRECATED_WARNING)
296#define MBEDTLS_DEPRECATED __attribute__((deprecated))
297#else
298#define MBEDTLS_DEPRECATED
299#endif
300/**
Gilles Peskine2e1934a2018-04-18 16:05:29 +0200301 * \brief This function calculates the SHA-1 checksum of a buffer.
Rose Zadik82741422018-03-27 12:49:48 +0100302 *
303 * The function allocates the context, performs the
304 * calculation, and frees the context.
305 *
306 * The SHA-1 result is calculated as
307 * output = SHA-1(input buffer).
308 *
309 * \warning SHA-1 is considered a weak message digest and its use
310 * constitutes a security risk. We recommend considering
311 * stronger message digests instead.
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100312 *
Gilles Peskine3e28d702018-01-22 12:18:59 +0100313 * \deprecated Superseded by mbedtls_sha1_ret() in 2.7.0
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100314 *
Rose Zadik44833d92018-01-26 08:41:09 +0000315 * \param input The buffer holding the input data.
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500316 * This must be a readable buffer of length \p ilen Bytes.
317 * \param ilen The length of the input data \p input in Bytes.
318 * \param output The SHA-1 checksum result. This must be a writable
319 * buffer of size \c 20 Bytes.
Hanno Beckerbbca8c52017-09-25 14:53:51 +0100320 *
Paul Bakker5121ce52009-01-03 21:22:43 +0000321 */
Jaeden Amero041039f2018-02-19 15:28:08 +0000322MBEDTLS_DEPRECATED void mbedtls_sha1( const unsigned char *input,
323 size_t ilen,
324 unsigned char output[20] );
Andres Amaya Garcia034ea7e2017-04-28 15:14:50 +0100325
326#undef MBEDTLS_DEPRECATED
327#endif /* !MBEDTLS_DEPRECATED_REMOVED */
Paul Bakker5121ce52009-01-03 21:22:43 +0000328
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500329#if defined(MBEDTLS_SELF_TEST)
330
Paul Bakker5121ce52009-01-03 21:22:43 +0000331/**
Rose Zadik44833d92018-01-26 08:41:09 +0000332 * \brief The SHA-1 checkup routine.
Paul Bakker5121ce52009-01-03 21:22:43 +0000333 *
Hanno Beckerbbca8c52017-09-25 14:53:51 +0100334 * \warning SHA-1 is considered a weak message digest and its use
335 * constitutes a security risk. We recommend considering
336 * stronger message digests instead.
337 *
Rose Zadik82741422018-03-27 12:49:48 +0100338 * \return \c 0 on success.
339 * \return \c 1 on failure.
340 *
Paul Bakker5121ce52009-01-03 21:22:43 +0000341 */
Manuel Pégourié-Gonnard2cf5a7c2015-04-08 12:49:31 +0200342int mbedtls_sha1_self_test( int verbose );
Paul Bakker5121ce52009-01-03 21:22:43 +0000343
Andrzej Kurekc470b6b2019-01-31 08:20:20 -0500344#endif /* MBEDTLS_SELF_TEST */
345
Paul Bakker5121ce52009-01-03 21:22:43 +0000346#ifdef __cplusplus
347}
348#endif
349
Manuel Pégourié-Gonnard2cf5a7c2015-04-08 12:49:31 +0200350#endif /* mbedtls_sha1.h */