MCCI TweetNaCl
TweetNaCl library adapted for embedded use
mcci_tweetnacl_hal.h
Go to the documentation of this file.
1
/*
2
3
Module: mcci_tweetnacl_hal.h
4
5
Function:
6
MCCI TweetNaCl HAL APIs.
7
8
Copyright and License:
9
This file copyright (C) 2021 by
10
11
MCCI Corporation
12
3520 Krums Corners Road
13
Ithaca, NY 14850
14
15
See accompanying LICENSE file for copyright and license information.
16
17
Author:
18
fullname, MCCI Corporation March 2021
19
20
*/
21
22
#ifndef _mcci_tweetnacl_hal_h_
23
#define _mcci_tweetnacl_hal_h_
/* prevent multiple includes */
24
25
#pragma once
26
27
#include "
mcci_tweetnacl.h
"
28
29
#ifdef __cplusplus
30
extern
"C"
{
31
#endif
32
33
/****************************************************************************\
34
|
35
| Meta
36
|
37
\****************************************************************************/
38
39
/// \addtogroup low-level-functions Low-level functions
40
/// @{
41
/// \addtogroup mcci-tweetnacl
42
/// @{
43
44
///
45
/// \brief generate stream of random bytes
46
///
47
/// \param[out] pBuffer pointer to buffer to be filled
48
/// \param[in] nBuffer number of bytes in buffer to be filled.
49
///
50
/// \note This must return cryptographically random numbers; don't try to use
51
/// your own RNG unless you've tested extensively.
52
///
53
/// \note If the RNG can't generate a suitable value, the default implementation
54
/// will use \c longjmp() to bail out. This means that this function can't
55
/// be used directly by clients.
56
///
57
58
void
59
mcci_tweetnacl_hal_randombytes
(
60
unsigned
char
*pBuffer,
61
unsigned
long
long
nBuffer
62
);
63
64
65
/****************************************************************************\
66
|
67
| Post-Meta
68
|
69
\****************************************************************************/
70
71
//--- close groups ---
72
/// @}
73
/// @}
74
75
#ifdef __cplusplus
76
}
77
#endif
78
79
#endif
/* _mcci_tweetnacl_hal_h_ */
mcci_tweetnacl_hal_randombytes
void mcci_tweetnacl_hal_randombytes(unsigned char *pBuffer, unsigned long long nBuffer)
generate stream of random bytes
mcci_tweetnacl.h
src
mcci_tweetnacl_hal.h
Generated on Fri Mar 19 2021 19:07:55 for MCCI TweetNaCl by
1.8.18