MPHELL
4.0.0
include
mphell-entropy.h
Go to the documentation of this file.
1
/*
2
MPHELL-4.0
3
Author(s): The MPHELL team
4
5
(C) Copyright 2015-2018 - Institut Fourier / Univ. Grenoble Alpes (France)
6
7
This file is part of the MPHELL Library.
8
MPHELL is free software: you can redistribute it and/or modify
9
it under the terms of the GNU Lesser General Public License as published by
10
the Free Software Foundation, version 3 of the License.
11
12
MPHELL is distributed in the hope that it will be useful,
13
but WITHOUT ANY WARRANTY; without even the implied warranty of
14
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
GNU Lesser General Public License for more details.
16
17
You should have received a copy of the GNU Lesser General Public License
18
along with MPHELL. If not, see <http://www.gnu.org/licenses/>.
19
*/
20
26
#ifndef ENTROPY_H
27
#define ENTROPY_H
28
29
#include <string.h>
30
#include <math.h>
31
32
#include "
mphell-errors.h
"
33
38
enum
entropy_source
{
39
INTEL
,
40
DEVURANDOM
,
41
DEVRANDOM
,
42
ENTROPY_UNSET
43
};
44
49
typedef
enum
entropy_source
entropy_type
;
50
59
void
60
get_entropy_input
(
mphell_status
ret, uint8_t *data,
61
const
entropy_type
entropy_src,
const
uint16_t length);
62
63
#endif
entropy_source
entropy_source
Define the entropy source.
Definition:
mphell-entropy.h:38
DEVRANDOM
Definition:
mphell-entropy.h:41
mphell-errors.h
Declaration of error functions.
get_entropy_input
void get_entropy_input(mphell_status ret, uint8_t *data, const entropy_type entropy_src, const uint16_t length)
Get length bit of entropy from the entropy source selected.
Definition:
mphell-entropy.c:306
mphell_status
mphell_status_t mphell_status[1]
The status is a couple (flag, information)
Definition:
mphell-errors.h:94
ENTROPY_UNSET
Definition:
mphell-entropy.h:42
entropy_type
enum entropy_source entropy_type
Define the entropy source.
Definition:
mphell-entropy.h:49
DEVURANDOM
Definition:
mphell-entropy.h:40
INTEL
Definition:
mphell-entropy.h:39
Generated by
1.8.15