blob: 1bf29dfbc6d8850d02bc32a58460f772aea04588 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
/*
* X.509 Certificate Store Searching
* (C) 1999-2007 Jack Lloyd
*
* Distributed under the terms of the Botan license
*/
#ifndef BOTAN_X509_CERT_STORE_SEARCH_H__
#define BOTAN_X509_CERT_STORE_SEARCH_H__
#include <botan/x509stor.h>
#include <botan/bigint.h>
namespace Botan {
namespace X509_Store_Search {
/*
* Search based on the contents of a DN entry
*/
enum DN_Search_Type { SUBSTRING_MATCHING, IGNORE_CASE };
std::function<bool (const X509_Certificate&)>
by_dn(const std::string& dn_entry,
const std::string& to_find,
DN_Search_Type method);
std::function<bool (const X509_Certificate&)>
by_dn(const std::string& dn_entry,
const std::string& to_find,
std::function<bool (std::string, std::string)> method);
/**
* Search for certs by issuer + serial number
*/
std::function<bool (const X509_Certificate&)>
by_issuer_and_serial(const X509_DN& issuer, const MemoryRegion<byte>& serial);
std::function<bool (const X509_Certificate&)>
by_issuer_and_serial(const X509_DN& issuer, const BigInt& serial);
/**
* Search for certs by subject key identifier
*/
std::function<bool (const X509_Certificate&)>
by_skid(const MemoryRegion<byte>& subject_key_id);
}
}
#endif
|