Botan  1.11.15
src/lib/cert/cvc/cvc_req.h
Go to the documentation of this file.
00001 /*
00002 * EAC1_1 CVC Request
00003 * (C) 2008 Falko Strenzke
00004 *     2010 Jack Lloyd
00005 *
00006 * Botan is released under the Simplified BSD License (see license.txt)
00007 */
00008 
00009 #ifndef BOTAN_EAC_CVC_REQ_H__
00010 #define BOTAN_EAC_CVC_REQ_H__
00011 
00012 #include <botan/cvc_gen_cert.h>
00013 
00014 namespace Botan {
00015 
00016 /**
00017 * This class represents TR03110 v1.1 EAC CV Certificate Requests.
00018 */
00019 class BOTAN_DLL EAC1_1_Req : public EAC1_1_gen_CVC<EAC1_1_Req>
00020    {
00021    public:
00022       friend class EAC1_1_ADO;
00023       friend class EAC1_1_obj<EAC1_1_Req>;
00024 
00025       /**
00026       * Compare for equality with other
00027       * @param other compare for equality with this object
00028       */
00029       bool operator==(const EAC1_1_Req& other) const;
00030 
00031       /**
00032       * Construct a CVC request from a data source.
00033       * @param source the data source
00034       */
00035       EAC1_1_Req(DataSource& source);
00036 
00037       /**
00038       * Construct a CVC request from a DER encoded CVC request file.
00039       * @param str the path to the DER encoded file
00040       */
00041       EAC1_1_Req(const std::string& str);
00042 
00043       virtual ~EAC1_1_Req(){}
00044    private:
00045       void force_decode();
00046       EAC1_1_Req() {}
00047    };
00048 
00049 /*
00050 * Comparison Operator
00051 */
00052 inline bool operator!=(EAC1_1_Req const& lhs, EAC1_1_Req const& rhs)
00053    {
00054    return !(lhs == rhs);
00055    }
00056 
00057 }
00058 
00059 #endif