mirror of
https://github.com/zeek/zeek.git
synced 2025-10-06 00:28:21 +00:00
Tell OpenSSL that MD5 is not used for security in order to allow bro to work properly on a FIPS system
This commit is contained in:
parent
fa6e7219ff
commit
a72e9a8126
10 changed files with 97 additions and 47 deletions
|
@ -1,7 +1,7 @@
|
|||
// See the file "COPYING" in the main distribution directory for copyright.
|
||||
|
||||
#include <typeinfo>
|
||||
#include <openssl/md5.h>
|
||||
#include <openssl/evp.h>
|
||||
|
||||
#include "Hasher.h"
|
||||
#include "NetVar.h"
|
||||
|
@ -123,13 +123,13 @@ Hasher::digest UHF::hash(const void* x, size_t n) const
|
|||
Hasher::digest rval;
|
||||
} u;
|
||||
|
||||
MD5(reinterpret_cast<const unsigned char*>(x), n, u.d);
|
||||
internal_md5(reinterpret_cast<const unsigned char*>(x), n, u.d);
|
||||
|
||||
const unsigned char* s = reinterpret_cast<const unsigned char*>(&seed);
|
||||
for ( size_t i = 0; i < 16; ++i )
|
||||
u.d[i] ^= s[i % sizeof(seed)];
|
||||
|
||||
MD5(u.d, 16, u.d);
|
||||
internal_md5(u.d, 16, u.d);
|
||||
return u.rval;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue