limal-ca-mgm
IssuerAlternativeNameExtension.hpp
Go to the documentation of this file.
1 /*---------------------------------------------------------------------\
2 | |
3 | _ _ _ _ __ _ |
4 | | | | | | \_/ | / \ | | |
5 | | | | | | |_| | / /\ \ | | |
6 | | |__ | | | | | | / ____ \ | |__ |
7 | |____||_| |_| |_|/ / \ \|____| |
8 | |
9 | ca-mgm library |
10 | |
11 | (C) SUSE Linux Products GmbH |
12 \----------------------------------------------------------------------/
13 
14  File: IssuerAlternativeNameExtension.hpp
15 
16  Author: <Michael Calmer> <mc@suse.de>
17  Maintainer: <Michael Calmer> <mc@suse.de>
18 
19  Purpose:
20 
21 /-*/
22 #ifndef LIMAL_CA_MGM_ISSUER_ALTERNATIVE_NAME_EXTENSION_HPP
23 #define LIMAL_CA_MGM_ISSUER_ALTERNATIVE_NAME_EXTENSION_HPP
24 
25 #include <limal/ca-mgm/config.h>
29 #include <blocxx/COWIntrusiveReference.hpp>
30 
31 namespace LIMAL_NAMESPACE {
32 
33 namespace CA_MGM_NAMESPACE {
34 
35  class CA;
36  class CAConfig;
37  class IssuerAlternativeNameExtImpl;
38 
40  public:
42 
43  IssuerAlternativeNameExt(bool copyIssuer,
44  const blocxx::List<LiteralValue> &alternativeNameList);
45 
46  IssuerAlternativeNameExt(CAConfig* caConfig, Type type);
47 
49 
50  virtual ~IssuerAlternativeNameExt();
51 
52 #ifndef SWIG
53 
55  operator=(const IssuerAlternativeNameExt& extension);
56 
57 #endif
58 
59  void
60  setCopyIssuer(bool copyIssuer);
61 
62  bool
63  getCopyIssuer() const;
64 
65  void
66  setAlternativeNameList(const blocxx::List<LiteralValue> &alternativeNameList);
67 
68  blocxx::List<LiteralValue>
69  getAlternativeNameList() const;
70 
71  void
72  addIssuerAltName(const LiteralValue& altName);
73 
74  virtual void
75  commit2Config(CA& ca, Type type) const;
76 
77  virtual bool
78  valid() const;
79 
80  virtual blocxx::StringArray
81  verify() const;
82 
83  virtual blocxx::StringArray
84  dump() const;
85 
86  private:
87  blocxx::COWIntrusiveReference<IssuerAlternativeNameExtImpl> m_impl;
88 
89  };
90 
91 }
92 }
93 
94 #endif // LIMAL_CA_MGM_ISSUER_ALTERNATIVE_NAME_EXTENSION_HPP