7#ifndef CTRL_AGENT_CFG_MGR_H
8#define CTRL_AGENT_CFG_MGR_H
15#include <boost/pointer_cast.hpp>
22class CtrlAgentCfgContext;
70 const std::string& service);
107 http_headers_ = headers;
114 return (http_headers_);
123 auth_config_ = auth_config;
132 return (auth_config_);
147 return (trust_anchor_);
183 cert_required_ = required;
191 return (cert_required_);
198 return (hooks_config_);
205 return (hooks_config_);
235 std::map<std::string, isc::data::ConstElementPtr> ctrl_sockets_;
238 std::string http_host_;
248 std::string trust_anchor_;
251 std::string cert_file_;
254 std::string key_file_;
285 return (boost::dynamic_pointer_cast<CtrlAgentCfgContext>(
getContext()));
Control Agent Configuration Context.
isc::hooks::HooksConfig & getHooksConfig()
Returns non-const reference to configured hooks libraries.
void setTrustAnchor(const std::string &ca)
Sets trust-anchor parameter.
void setControlSocketInfo(const isc::data::ConstElementPtr &control_socket, const std::string &service)
Sets information about the control socket.
virtual isc::data::ElementPtr toElement() const
Unparse a configuration object.
void setCertFile(const std::string &cert)
Sets cert-file parameter.
std::string getTrustAnchor() const
Returns trust-anchor parameter.
void setKeyFile(const std::string &key)
Sets key-file parameter.
const isc::http::HttpAuthConfigPtr & getAuthConfig() const
Returns HTTP authentication configuration.
void setAuthConfig(const isc::http::HttpAuthConfigPtr &auth_config)
Sets HTTP authentication configuration.
bool getCertRequired() const
Returns cert-required parameter.
void setHttpHeaders(const isc::http::CfgHttpHeaders &headers)
Sets http-headers parameter.
void setHttpHost(const std::string &host)
Sets http-host parameter.
CtrlAgentCfgContext()
Default constructor.
void setHttpPort(const uint16_t port)
Sets http port.
isc::data::ConstElementPtr getControlSocketInfo(const std::string &service) const
Returns information about control socket.
std::string getCertFile() const
Returns cert-file parameter.
std::string getHttpHost() const
Returns http-host parameter.
std::string getKeyFile() const
Returns key-file parameter.
const isc::http::CfgHttpHeaders & getHttpHeaders() const
Returns http-headers parameter.
std::string getControlSocketInfoSummary() const
Returns socket configuration summary in a textual format.
uint16_t getHttpPort() const
Returns the TCP post the HTTP server will listen on.
void setCertRequired(bool required)
Sets cert-required parameter.
const isc::hooks::HooksConfig & getHooksConfig() const
Returns const reference to configured hooks libraries.
virtual process::ConfigPtr clone()
Creates a clone of this context object.
Ctrl Agent Configuration Manager.
std::list< std::list< std::string > > jsonPathsToRedact() const final override
Return a list of all paths that contain passwords or secrets.
CtrlAgentCfgMgr()
Constructor.
virtual process::ConfigPtr createNewContext() override
Creates a new, blank CtrlAgentCfgContext context.
virtual isc::data::ConstElementPtr parse(isc::data::ConstElementPtr config, bool check_only) override
Parses configuration of the Control Agent.
CtrlAgentCfgContextPtr getCtrlAgentCfgContext()
Convenience method that returns the Control Agent configuration context.
virtual std::string getConfigSummary(const uint32_t selection) override
Returns configuration summary in the textual format.
virtual ~CtrlAgentCfgMgr()
Destructor.
Wrapper class that holds hooks libraries configuration.
Base class for all configurations.
ConfigPtr & getContext()
Fetches the configuration context.
boost::shared_ptr< CtrlAgentCfgContext > CtrlAgentCfgContextPtr
Pointer to a configuration context.
boost::shared_ptr< CtrlAgentCfgMgr > CtrlAgentCfgMgrPtr
Defines a shared pointer to CtrlAgentCfgMgr.
boost::shared_ptr< const Element > ConstElementPtr
boost::shared_ptr< Element > ElementPtr
boost::shared_ptr< HttpAuthConfig > HttpAuthConfigPtr
Type of shared pointers to HTTP authentication configuration.
std::vector< CfgHttpHeader > CfgHttpHeaders
Collection of config HTTP headers.
boost::shared_ptr< ConfigBase > ConfigPtr
Non-const pointer to the ConfigBase.
Defines the logger used by the top-level component of kea-lfc.