mirror of
https://github.com/zeek/zeek.git
synced 2025-10-09 10:08:20 +00:00
Avoid OpenSSL header dependencies
This commit is contained in:
parent
4eb1b71d1b
commit
c500370563
13 changed files with 370 additions and 204 deletions
|
@ -403,7 +403,7 @@ BitVector::size_type BitVector::FindNext(size_type i) const {
|
|||
uint64_t BitVector::Hash() const {
|
||||
u_char buf[SHA256_DIGEST_LENGTH];
|
||||
uint64_t digest;
|
||||
EVP_MD_CTX* ctx = zeek::detail::hash_init(zeek::detail::Hash_SHA256);
|
||||
auto* ctx = zeek::detail::hash_init(zeek::detail::Hash_SHA256);
|
||||
|
||||
for ( size_type i = 0; i < Blocks(); ++i )
|
||||
zeek::detail::hash_update(ctx, &bits[i], sizeof(bits[i]));
|
||||
|
|
|
@ -14,9 +14,9 @@
|
|||
namespace zeek::probabilistic::detail {
|
||||
|
||||
Hasher::seed_t Hasher::MakeSeed(const void* data, size_t size) {
|
||||
u_char buf[SHA256_DIGEST_LENGTH];
|
||||
u_char buf[ZEEK_SHA256_DIGEST_LENGTH];
|
||||
seed_t tmpseed;
|
||||
EVP_MD_CTX* ctx = zeek::detail::hash_init(zeek::detail::Hash_SHA256);
|
||||
auto* ctx = zeek::detail::hash_init(zeek::detail::Hash_SHA256);
|
||||
|
||||
assert(sizeof(tmpseed) == 16);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue