c-SSS  0.2.1
Implementation of Shamir's Secret Sharing in C.
shamir.h
Go to the documentation of this file.
1 #ifndef SHAMIRS_SECRET_SHARING_H
2 #define SHAMIRS_SECRET_SHARING_H
3 
4 #include "strtok.h"
5 
6 #ifdef TEST
7 #include "CuTest.h"
8 #endif
9 
19 void seed_random(void);
21 
23 char * generate_share_strings(char * secret, int n, int t);
24 
26 char * extract_secret_from_share_strings(const char * string);
27 
28 #endif
char * extract_secret_from_share_strings(const char *string)
Given a list of shares (\n separated without leading whitespace), recreate the original secret...
Definition: shamir.c:513
char * generate_share_strings(char *secret, int n, int t)
Given a secret, n, and t, create a list of shares (\n separated).
Definition: shamir.c:466
void seed_random(void)
Seed the random number generator. MUST BE CALLED before using the library (unless on arc4random() sys...
Definition: shamir.c:86