CernVM-FS
2.12.0
|
#include <arpa/inet.h>
#include <stdint.h>
#include <cassert>
#include <cctype>
#include <cstdlib>
#include <cstring>
#include <string>
#include "util/export.h"
#include "util/logging.h"
#include "util/prng.h"
#include "util/smalloc.h"
Go to the source code of this file.
Classes | |
struct | shash::HexPtr |
struct | shash::AsciiPtr |
struct | shash::Digest< digest_size_, algorithm_ > |
class | shash::Digest< digest_size_, algorithm_ >::Hex |
struct | shash::Md5 |
struct | shash::Sha1 |
struct | shash::Rmd160 |
struct | shash::Shake128 |
struct | shash::Any |
class | shash::ContextPtr |
Namespaces | |
shash | |
Typedefs | |
typedef char | shash::Suffix |
Enumerations | |
enum | shash::Algorithms { shash::kMd5 = 0, shash::kSha1, shash::kRmd160, shash::kShake128, shash::kAny } |
Functions | |
unsigned | shash::GetContextSize (const Algorithms algorithm) |
void | shash::Init (ContextPtr context) |
void | shash::Update (const unsigned char *buffer, const unsigned buffer_length, ContextPtr context) |
void | shash::Final (ContextPtr context, Any *any_digest) |
bool | shash::HashFile (const std::string &filename, Any *any_digest) |
bool | shash::HashFd (int fd, Any *any_digest) |
void | shash::HashMem (const unsigned char *buffer, const unsigned buffer_size, Any *any_digest) |
void | shash::HashString (const std::string &content, Any *any_digest) |
CVMFS_EXPORT void | shash::Hmac (const std::string &key, const unsigned char *buffer, const unsigned buffer_size, Any *any_digest) |
void | shash::HmacString (const std::string &key, const std::string &content, Any *any_digest) |
std::string | shash::Hmac256 (const std::string &key, const std::string &content, bool raw_output) |
CVMFS_EXPORT std::string | shash::Sha256File (const std::string &filename) |
string | shash::Sha256Mem (const unsigned char *buffer, const unsigned buffer_size) |
CVMFS_EXPORT std::string | shash::Sha256String (const std::string &content) |
CVMFS_EXPORT Algorithms | shash::ParseHashAlgorithm (const std::string &algorithm_option) |
Any | shash::MkFromHexPtr (const HexPtr hex, const char suffix) |
Any | shash::MkFromSuffixedHexPtr (const HexPtr hex) |
Variables | |
const char | shash::kSuffixNone = 0 |
const char | shash::kSuffixCatalog = 'C' |
const char | shash::kSuffixHistory = 'H' |
const char | shash::kSuffixMicroCatalog = 'L' |
const char | shash::kSuffixPartial = 'P' |
const char | shash::kSuffixTemporary = 'T' |
const char | shash::kSuffixCertificate = 'X' |
const char | shash::kSuffixMetainfo = 'M' |
const unsigned | shash::kDigestSizes [] |
const unsigned | shash::kMaxDigestSize = 20 |
const unsigned | shash::kMaxContextSize = 256 |
const unsigned | shash::kAlgorithmIdSizes [] |
const unsigned | shash::kMaxAlgorithmIdentifierSize = 9 |
const unsigned | shash::kBlockSizes [] |