VirtualBox

source: vbox/trunk/src/libs/openssl-3.1.7/providers/implementations/digests/blake2_prov.c@ 107474

Last change on this file since 107474 was 104078, checked in by vboxsync, 14 months ago

openssl-3.1.5: Applied and adjusted our OpenSSL changes to 3.1.4. bugref:10638

File size: 1.3 KB
Line 
1/*
2 * Copyright 2019-2021 The OpenSSL Project Authors. All Rights Reserved.
3 *
4 * Licensed under the Apache License 2.0 (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#include <openssl/crypto.h>
11#include "prov/blake2.h"
12#include "prov/digestcommon.h"
13#include "prov/implementations.h"
14
15int ossl_blake2s256_init(void *ctx)
16{
17 BLAKE2S_PARAM P;
18
19 ossl_blake2s_param_init(&P);
20 return ossl_blake2s_init((BLAKE2S_CTX *)ctx, &P);
21}
22
23int ossl_blake2b512_init(void *ctx)
24{
25 BLAKE2B_PARAM P;
26
27 ossl_blake2b_param_init(&P);
28 return ossl_blake2b_init((BLAKE2B_CTX *)ctx, &P);
29}
30
31/* ossl_blake2s256_functions */
32IMPLEMENT_digest_functions(blake2s256, BLAKE2S_CTX,
33 BLAKE2S_BLOCKBYTES, BLAKE2S_DIGEST_LENGTH, 0,
34 ossl_blake2s256_init, ossl_blake2s_update,
35 ossl_blake2s_final)
36
37/* ossl_blake2b512_functions */
38IMPLEMENT_digest_functions(blake2b512, BLAKE2B_CTX,
39 BLAKE2B_BLOCKBYTES, BLAKE2B_DIGEST_LENGTH, 0,
40 ossl_blake2b512_init, ossl_blake2b_update,
41 ossl_blake2b_final)
Note: See TracBrowser for help on using the repository browser.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette