1 //===- FuzzerSHA1.h - Internal header for the SHA1 utils --------*- C++ -* ===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 //===----------------------------------------------------------------------===//
12 #ifndef LLVM_FUZZER_SHA1_H
13 #define LLVM_FUZZER_SHA1_H
15 #include "FuzzerDefs.h"
21 // Private copy of SHA1 implementation.
22 static const int kSHA1NumBytes = 20;
24 // Computes SHA1 hash of 'Len' bytes in 'Data', writes kSHA1NumBytes to 'Out'.
25 void ComputeSHA1(const uint8_t *Data, size_t Len, uint8_t *Out);
27 std::string Sha1ToString(const uint8_t Sha1[kSHA1NumBytes]);
29 std::string Hash(const Unit &U);
33 #endif // LLVM_FUZZER_SHA1_H