aboutsummaryrefslogtreecommitdiffstats
path: root/include/x509_crl.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/x509_crl.h')
-rw-r--r--include/x509_crl.h51
1 files changed, 51 insertions, 0 deletions
diff --git a/include/x509_crl.h b/include/x509_crl.h
new file mode 100644
index 000000000..7d8a3e3cb
--- /dev/null
+++ b/include/x509_crl.h
@@ -0,0 +1,51 @@
+/*************************************************
+* X.509 CRL Header File *
+* (C) 1999-2006 The Botan Project *
+*************************************************/
+
+#ifndef BOTAN_X509_CRL_H__
+#define BOTAN_X509_CRL_H__
+
+#include <botan/x509_obj.h>
+#include <botan/crl_ent.h>
+#include <vector>
+
+namespace Botan {
+
+/*************************************************
+* X.509 CRL *
+*************************************************/
+class X509_CRL : public X509_Object
+ {
+ public:
+ struct X509_CRL_Error : public Exception
+ {
+ X509_CRL_Error(const std::string& error) :
+ Exception("X509_CRL: " + error) {}
+ };
+
+ std::vector<CRL_Entry> get_revoked() const;
+
+ X509_DN issuer_dn() const;
+ MemoryVector<byte> authority_key_id() const;
+
+ u32bit crl_number() const;
+ X509_Time this_update() const;
+ X509_Time next_update() const;
+
+ void force_decode();
+
+ X509_CRL(DataSource&);
+ X509_CRL(const std::string&);
+ private:
+ void handle_crl_extension(const Extension&);
+ std::vector<CRL_Entry> revoked;
+ MemoryVector<byte> issuer_key_id;
+ X509_Time start, end;
+ X509_DN issuer;
+ u32bit version, crl_count;
+ };
+
+}
+
+#endif