#include "cast/common/certificate/cast_crl.h"
#include <time.h>
#include <memory>
#include "cast/common/certificate/date_time.h"
#include "cast/common/public/parsed_certificate.h"
#include "cast/common/public/trust_store.h"
#include "platform/base/macros.h"
#include "util/crypto/sha2.h"
#include "util/osp_logging.h"
#include "util/span_util.h"
namespace openscreen::cast {
namespace {
enum CrlVersion { … };
bool VerifyCRL(const proto::Crl& crl,
const proto::TbsCrl& tbs_crl,
const DateTime& time,
TrustStore* trust_store,
DateTime* overall_not_after) { … }
}
CastCRL::CastCRL(const proto::TbsCrl& tbs_crl,
const DateTime& overall_not_after) { … }
CastCRL::~CastCRL() { … }
bool CastCRL::CheckRevocation(
const std::vector<const ParsedCertificate*>& trusted_chain,
const DateTime& time) const { … }
std::unique_ptr<CastCRL> ParseAndVerifyCRL(const std::string& crl_proto,
const DateTime& time,
TrustStore* trust_store) { … }
}