5 #ifndef CVMFS_WHITELIST_H_
6 #define CVMFS_WHITELIST_H_
8 #include <gtest/gtest_prod.h>
18 class DownloadManager;
22 class SignatureManager;
52 texts[1] =
"failed to download whitelist";
53 texts[2] =
"empty whitelist";
54 texts[3] =
"malformed whitelist";
55 texts[4] =
"repository name mismatch on whitelist";
56 texts[5] =
"expired whitelist";
57 texts[6] =
"invalid whitelist signature";
58 texts[7] =
"failed to download whitelist (pkcs7)";
59 texts[8] =
"empty whitelist (pkcs7)";
60 texts[9] =
"malformed whitelist (pkcs7)";
61 texts[10] =
"invalid whitelist signer (pkcs7)";
62 texts[11] =
"invalid whitelist (pkcs7)";
63 texts[12] =
"failed to verify CA chain";
64 texts[13] =
"certificate not on whitelist";
65 texts[14] =
"certificate blacklisted";
66 texts[15] =
"no text";
81 const std::string &fqrn,
95 void CopyBuffers(
unsigned *plain_size,
unsigned char **plain_buf,
96 unsigned *pkcs7_size,
unsigned char **pkcs7_buf)
const;
112 bool IsBefore(time_t now,
const struct tm &t_whitelist);
115 const unsigned whitelist_size);
134 #endif // CVMFS_WHITELIST_H_
Failures LoadUrl(const std::string &base_url)
unsigned char * pkcs7_buf_
Failures VerifyLoadedCertificate() const
void CopyBuffers(unsigned *plain_size, unsigned char **plain_buf, unsigned *pkcs7_size, unsigned char **pkcs7_buf) const
bool IsBefore(time_t now, const struct tm &t_whitelist)
static const int kFlagVerifyPkcs7
unsigned char * plain_buf_
Failures ParseWhitelist(const unsigned char *whitelist, const unsigned whitelist_size)
FRIEND_TEST(T_Whitelist, ParseWhitelist)
const char * Code2Ascii(const Failures error)
download::DownloadManager * download_manager_
static const int kFlagVerifyRsa
Failures VerifyWhitelist()
const whitelist::Whitelist * whitelist() const
std::string ExportString() const
Whitelist & operator=(const Whitelist &other)
static std::string CreateString(const std::string &fqrn, int validity_days, shash::Algorithms hash_algorithm, signature::SignatureManager *signature_manager)
static const int kFlagVerifyCaChain
Failures LoadMem(const std::string &whitelist)
std::vector< shash::Any > fingerprints_
signature::SignatureManager * signature_manager_