blake2b512.h File Reference

BLAKE2b-512 hash function. More...

#include "core/crypto.h"
#include "hash/blake2b.h"

Go to the source code of this file.


#define BLAKE2B512_BLOCK_SIZE   128
#define BLAKE2B512_DIGEST_SIZE   64
#define BLAKE2B512_OID   blake2b512Oid
#define BLAKE2B512_HASH_ALGO   (&blake2b512HashAlgo)


typedef Blake2bContext Blake2b512Context
 BLAKE2b-512 algorithm context. More...


error_t blake2b512Compute (const void *data, size_t length, uint8_t *digest)
 Digest a message using BLAKE2b-512. More...
void blake2b512Init (Blake2b512Context *context)
 Initialize BLAKE2b-512 hash computation. More...
void blake2b512Update (Blake2b512Context *context, const void *data, size_t length)
 Update BLAKE2b-512 hash computation. More...
void blake2b512Final (Blake2b512Context *context, uint8_t *digest)
 Finish BLAKE2b-512 hash computation. More...


const uint8_t blake2b512Oid [11]
const HashAlgo blake2b512HashAlgo

Detailed Description

BLAKE2b-512 hash function.


Copyright (C) 2010-2018 Oryx Embedded SARL. All rights reserved.

This file is part of CycloneCrypto Open.

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.

Oryx Embedded SARL (

Definition in file blake2b512.h.

Macro Definition Documentation


#define BLAKE2B512_BLOCK_SIZE   128

Definition at line 37 of file blake2b512.h.


#define BLAKE2B512_DIGEST_SIZE   64

Definition at line 39 of file blake2b512.h.


#define BLAKE2B512_HASH_ALGO   (&blake2b512HashAlgo)

Definition at line 43 of file blake2b512.h.


#define BLAKE2B512_OID   blake2b512Oid

Definition at line 41 of file blake2b512.h.

Typedef Documentation

◆ Blake2b512Context

BLAKE2b-512 algorithm context.

Definition at line 55 of file blake2b512.h.

Function Documentation

◆ blake2b512Compute()

error_t blake2b512Compute ( const void *  data,
size_t  length,
uint8_t *  digest 

Digest a message using BLAKE2b-512.

[in]dataPointer to the message being hashed
[in]lengthLength of the message
[out]digestPointer to the calculated digest
Error code

Definition at line 66 of file blake2b512.c.

◆ blake2b512Final()

void blake2b512Final ( Blake2b512Context context,
uint8_t *  digest 

Finish BLAKE2b-512 hash computation.

[in]contextPointer to the BLAKE2b context
[out]digestCalculated digest (optional parameter)

Definition at line 105 of file blake2b512.c.

◆ blake2b512Init()

void blake2b512Init ( Blake2b512Context context)

Initialize BLAKE2b-512 hash computation.

[in]contextPointer to the BLAKE2b context to initialize

Definition at line 78 of file blake2b512.c.

◆ blake2b512Update()

void blake2b512Update ( Blake2b512Context context,
const void *  data,
size_t  length 

Update BLAKE2b-512 hash computation.

[in]contextPointer to the BLAKE2b context
[in]dataPointer to the buffer being hashed
[in]lengthLength of the buffer

Definition at line 92 of file blake2b512.c.

Variable Documentation

◆ blake2b512HashAlgo

const HashAlgo blake2b512HashAlgo

Definition at line 43 of file blake2b512.c.

◆ blake2b512Oid

const uint8_t blake2b512Oid[11]

Definition at line 40 of file blake2b512.c.