libdigidocpp
|
#include <DirectoryX509CertStore.h>
Public Member Functions | |
DirectoryX509CertStore () throw (IOException) | |
DirectoryX509CertStore (const std::string &path) throw (IOException) | |
![]() | |
virtual | ~X509CertStore () |
virtual X509_STORE * | getCertStore () const throw (IOException) |
virtual | STACK_OF (X509)*getCerts() const throw (IOException) |
virtual X509 * | getCert (const X509_NAME *subject) const throw (IOException) |
Private Member Functions | |
void | loadCerts (const std::string &path) throw (IOException) |
Additional Inherited Members | |
![]() | |
static void | init (X509CertStore *impl=0) |
static void | destroy () |
static X509CertStore * | getInstance () throw (IOException) |
Implementation of X.509 certificate store, which loads the certificates from the directory provided.
Definition at line 30 of file DirectoryX509CertStore.h.
digidoc::DirectoryX509CertStore::DirectoryX509CertStore | ( | ) | throw (IOException) |
Gets certificate store path from configuration and loads all certificates found in directory and adds these to the certificate store.
IOException | exception is throws if the folder does not exist. |
Definition at line 35 of file DirectoryX509CertStore.cpp.
References digidoc::Conf::getInstance(), and loadCerts().
digidoc::DirectoryX509CertStore::DirectoryX509CertStore | ( | const std::string & | path | ) | throw (IOException) |
Load all certificates found in directory and adds these to the cert store.
path | path to X.509 certificates in PEM format. |
IOException | exception is throws if the folder does not exist. |
Definition at line 46 of file DirectoryX509CertStore.cpp.
|
private |
Load all certificates found in directory and adds these to the cert store.
path | path to X.509 certificates in PEM format. |
IOException | exception is throws if the folder does not exist. |
Definition at line 57 of file DirectoryX509CertStore.cpp.
References digidoc::util::File::directoryExists(), e, digidoc::Exception::getMsg(), INFO, digidoc::util::File::listFiles(), digidoc::X509Cert::loadX509(), THROW_IOEXCEPTION, and WARN.
Referenced by DirectoryX509CertStore().