]> WPIA git - cassiopeia.git/blob - src/crypto/simpleOpensslSigner.h
cln: Move code around, cleanup structure
[cassiopeia.git] / src / crypto / simpleOpensslSigner.h
1 #pragma once
2
3 #include <openssl/ssl.h>
4
5 #include "db/database.h"
6 #include "crypto/sslUtil.h"
7 #include "crypto/signer.h"
8
9 class SimpleOpensslSigner : public Signer {
10 private:
11     static std::shared_ptr<int> lib_ref;
12     std::pair<std::shared_ptr<BIGNUM>, std::string> nextSerial( Profile& prof );
13 public:
14     SimpleOpensslSigner();
15     ~SimpleOpensslSigner();
16     std::shared_ptr<SignedCertificate> sign( std::shared_ptr<TBSCertificate> cert );
17     std::shared_ptr<X509_CRL> revoke( std::shared_ptr<CAConfig> ca, std::string serial );
18 };