Botan  1.11.15
Public Member Functions
Botan::OCSP::Request Class Reference

#include <ocsp.h>

List of all members.

Public Member Functions

std::string base64_encode () const
std::vector< byteBER_encode () const
const X509_Certificateissuer () const
 Request (const X509_Certificate &issuer_cert, const X509_Certificate &subject_cert)
const X509_Certificatesubject () const

Detailed Description

Definition at line 20 of file ocsp.h.


Constructor & Destructor Documentation

Botan::OCSP::Request::Request ( const X509_Certificate issuer_cert,
const X509_Certificate subject_cert 
) [inline]

Definition at line 23 of file ocsp.h.

                                                    :
         m_issuer(issuer_cert),
         m_subject(subject_cert)
         {}

Member Function Documentation

std::string Botan::OCSP::Request::base64_encode ( ) const

Definition at line 120 of file ocsp.cpp.

References BER_encode().

std::vector< byte > Botan::OCSP::Request::BER_encode ( ) const

Definition at line 102 of file ocsp.cpp.

References Botan::DER_Encoder::encode(), Botan::DER_Encoder::end_cons(), Botan::DER_Encoder::end_explicit(), Botan::DER_Encoder::get_contents_unlocked(), Botan::SEQUENCE, Botan::DER_Encoder::start_cons(), and Botan::DER_Encoder::start_explicit().

Referenced by base64_encode(), and Botan::OCSP::online_check().

   {
   CertID certid(m_issuer, m_subject);

   return DER_Encoder().start_cons(SEQUENCE)
        .start_cons(SEQUENCE)
          .start_explicit(0)
            .encode(static_cast<size_t>(0)) // version #
          .end_explicit()
            .start_cons(SEQUENCE)
              .start_cons(SEQUENCE)
                .encode(certid)
              .end_cons()
            .end_cons()
          .end_cons()
      .end_cons().get_contents_unlocked();
   }

Definition at line 33 of file ocsp.h.

{ return m_issuer; }

Definition at line 35 of file ocsp.h.

{ return m_subject; }

The documentation for this class was generated from the following files: