46 if (status == CalloutHandle::NEXT_STEP_DROP ||
47 status == CalloutHandle::NEXT_STEP_SKIP) {
60 if (subnets->empty()) {
68 if (registered_user) {
79 }
catch (
const std::exception& ex) {
106 if (status == CalloutHandle::NEXT_STEP_DROP ||
107 status == CalloutHandle::NEXT_STEP_SKIP) {
120 if (subnets->empty()) {
128 if (registered_user) {
139 }
catch (
const std::exception& ex) {
boost::shared_ptr< Subnet4 > Subnet4Ptr
A pointer to a Subnet4 object.
#define LOG_ERROR(LOGGER, MESSAGE)
Macro to conveniently test error output and log it.
int subnet6_select(CalloutHandle &handle)
This callout is called at the "subnet6_select" hook.
boost::shared_ptr< User > UserPtr
Defines a smart pointer to a User.
const char * registered_user_label
Text label of registered user pointer in callout context.
Defines the logger used by the user check hooks library.
const isc::log::MessageID USER_CHK_SUBNET6_SELECT_REGISTRY_NULL
boost::multi_index_container< Subnet4Ptr, boost::multi_index::indexed_by< boost::multi_index::ordered_unique< boost::multi_index::tag< SubnetSubnetIdIndexTag >, boost::multi_index::const_mem_fun< Subnet, SubnetID,&Subnet::getID > >, boost::multi_index::ordered_unique< boost::multi_index::tag< SubnetPrefixIndexTag >, boost::multi_index::const_mem_fun< Subnet, std::string,&Subnet::toText > >, boost::multi_index::ordered_non_unique< boost::multi_index::tag< SubnetServerIdIndexTag >, boost::multi_index::const_mem_fun< Network4, asiolink::IOAddress,&Network4::getServerId > >, boost::multi_index::ordered_non_unique< boost::multi_index::tag< SubnetModificationTimeIndexTag >, boost::multi_index::const_mem_fun< data::BaseStampedElement, boost::posix_time::ptime,&data::BaseStampedElement::getModificationTime > > >> Subnet4Collection
A collection of Subnet4 objects.
Per-packet callout handle.
CalloutNextStep
Specifies allowed next steps.
void setArgument(const std::string &name, T value)
Set argument.
isc::log::Logger user_chk_logger("user_chk")
User Check Logger.
boost::multi_index_container< Subnet6Ptr, boost::multi_index::indexed_by< boost::multi_index::ordered_unique< boost::multi_index::tag< SubnetSubnetIdIndexTag >, boost::multi_index::const_mem_fun< Subnet, SubnetID,&Subnet::getID > >, boost::multi_index::ordered_unique< boost::multi_index::tag< SubnetPrefixIndexTag >, boost::multi_index::const_mem_fun< Subnet, std::string,&Subnet::toText > >, boost::multi_index::ordered_non_unique< boost::multi_index::tag< SubnetModificationTimeIndexTag >, boost::multi_index::const_mem_fun< data::BaseStampedElement, boost::posix_time::ptime,&data::BaseStampedElement::getModificationTime > > >> Subnet6Collection
A collection of Subnet6 objects.
int subnet4_select(CalloutHandle &handle)
This callout is called at the "subnet4_select" hook.
void getArgument(const std::string &name, T &value) const
Get argument.
const isc::log::MessageID USER_CHK_SUBNET4_SELECT_REGISTRY_NULL
boost::shared_ptr< Subnet6 > Subnet6Ptr
A pointer to a Subnet6 object.
UserRegistryPtr user_registry
Pointer to the registry instance.
const isc::log::MessageID USER_CHK_SUBNET4_SELECT_ERROR
const isc::log::MessageID USER_CHK_SUBNET6_SELECT_ERROR
void getContext(const std::string &name, T &value) const
Get context.
CalloutNextStep getStatus() const
Returns the next processing step.