mirror of
https://github.com/GrapheneOS/hardened_malloc.git
synced 2025-05-27 18:22:18 -04:00
add generic get_random_bytes function
This commit is contained in:
parent
f115be8392
commit
c7e2cb82f4
2 changed files with 24 additions and 1 deletions
1
random.h
1
random.h
|
@ -15,6 +15,7 @@ struct random_state {
|
|||
};
|
||||
|
||||
void random_state_init(struct random_state *state);
|
||||
void get_random_bytes(struct random_state *state, void *buf, size_t size);
|
||||
u16 get_random_u16(struct random_state *state);
|
||||
u16 get_random_u16_uniform(struct random_state *state, u16 bound);
|
||||
u64 get_random_u64(struct random_state *state);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue