Botan 2.13.0 Crypto and TLS for C++11

- Main Page
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Static Public Member Functions | List of all members
Botan::Cert_Extension::Certificate_Policies Class Referencefinal

`#include <x509_ext.h>`

Inheritance diagram for Botan::Cert_Extension::Certificate_Policies:

## Public Member Functions
| Certificate_Policies ()=default
| Certificate_Policies (const std::vector< OID > &o)
Certificate_Policies * | copy () const override
std::vector< OID > | get_oids () const
const std::vector< OID > & | get_policy_oids () const
OID | oid_of () const override
void | validate (const X509_Certificate &subject, const X509_Certificate &issuer, const std::vector< std::shared_ptr< const X509_Certificate >> &cert_path, std::vector< std::set< Certificate_Status_Code >> &cert_status, size_t pos) override

## Static Public Member Functions
static OID | static_oid ()

## Detailed Description

Certificate Policies Extension

Definition at line 534 of file x509_ext.h.

## Constructor & Destructor Documentation

Botan::Cert_Extension::Certificate_Policies::Certificate_Policies | ( |  | ) |
| default

Botan::Cert_Extension::Certificate_Policies::Certificate_Policies | ( | const std::vector< OID > & | o | ) |
| inline explicit

Definition at line 541 of file x509_ext.h.

541 : m_oids(o) {}

## Member Function Documentation

Certificate_Policies* Botan::Cert_Extension::Certificate_Policies::copy | ( |  | ) | const
| inline override virtual

Make a copy of this extension

Returns
  copy of this

Implements Botan::Certificate_Extension.

Definition at line 537 of file x509_ext.h.

538 { return new Certificate_Policies(m_oids); }
Botan::Cert_Extension::Certificate_Policies::Certificate_Policies
Certificate_Policies()=default

std::vector<OID> Botan::Cert_Extension::Certificate_Policies::get_oids | ( |  | ) | const
| inline

Definition at line 544 of file x509_ext.h.

544 { return m_oids; }

const std::vector<OID>& Botan::Cert_Extension::Certificate_Policies::get_policy_oids | ( |  | ) | const
| inline

Definition at line 546 of file x509_ext.h.

546 { return m_oids; }

OID Botan::Cert_Extension::Certificate_Policies::oid_of | ( |  | ) | const
| inline override virtual

Returns
  OID representing this extension

Implements Botan::Certificate_Extension.

Definition at line 549 of file x509_ext.h.

549 { return static_oid(); }
Botan::Cert_Extension::Certificate_Policies::static_oid
static OID static_oid()
Definition: x509_ext.h:548

static OID Botan::Cert_Extension::Certificate_Policies::static_oid | ( |  | ) |
| inline static

Definition at line 548 of file x509_ext.h.

548 { return OID("2.5.29.32"); }

void Botan::Cert_Extension::Certificate_Policies::validate | ( | const X509_Certificate & | subject,
|  | const X509_Certificate & | issuer,
|  | const std::vector< std::shared_ptr< const X509_Certificate >> & | cert_path,
|  | std::vector< std::set< Certificate_Status_Code >> & | cert_status,
|  | size_t | pos
| ) |  |
| override virtual

Reimplemented from Botan::Certificate_Extension.

Definition at line 792 of file x509_ext.cpp.

References Botan::DUPLICATE_CERT_POLICY.

798 {
799 std::set<OID> oid_set(m_oids.begin(), m_oids.end());
800 if(oid_set.size() != m_oids.size())
801 {
802 cert_status.at(pos).insert(Certificate_Status_Code::DUPLICATE_CERT_POLICY);
803 }
804 }
Botan::Certificate_Status_Code::DUPLICATE_CERT_POLICY

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

- src/lib/x509/x509_ext.h
- src/lib/x509/x509_ext.cpp