|
|
|
@ -27,9 +27,11 @@
|
|
|
|
|
#include <stdint.h>
|
|
|
|
|
#include <stdlib.h>
|
|
|
|
|
#include <string.h>
|
|
|
|
|
#include <sys/time.h>
|
|
|
|
|
|
|
|
|
|
#include <openssl/aes.h>
|
|
|
|
|
#include <openssl/blowfish.h>
|
|
|
|
|
#include <openssl/rand.h>
|
|
|
|
|
|
|
|
|
|
#include <sxt/errno.h>
|
|
|
|
|
#include <sxt/ciphers.h>
|
|
|
|
@ -171,3 +173,13 @@ int lcrypt_init_ciphers(void)
|
|
|
|
|
return r;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/* misc */
|
|
|
|
|
int lcrypt_reseed(void)
|
|
|
|
|
{
|
|
|
|
|
#ifndef WIN32
|
|
|
|
|
struct timeval tv;
|
|
|
|
|
gettimeofday(&tv, NULL);
|
|
|
|
|
RAND_add(&tv, sizeof(struct timeval), 0.0);
|
|
|
|
|
#endif
|
|
|
|
|
return SXT_SUCCESS;
|
|
|
|
|
}
|
|
|
|
|