This is convenient as there are often multiple classes associated with a given scope.
Client classification is done in isc::dhcp::Dhcpv6Srv::classifyPacket. First, the old
-"built-in" (see @ref dhcpv6ClassifierSimple) classification is called (see @ref
-isc::dhcp::Dhcpv6Srv::classifyByVendor). Then the code iterates over all class definitions
+"built-in" (see @ref dhcpv6ClassifierSimple) classification is called (see private
+isc::dhcp::Dhcpv6Srv::classifyByVendor()). Then the code iterates over all class definitions
and for each class definition it calls isc::dhcp::evaluate, which is implemented in libeval
(see @ref libeval). If the evaluation is successful, the class name is added to the packet
(by calling isc::dhcp::pkt::addClass).
///
/// @note This is done in two phases: first the content of the
/// vendor-class-identifier options are used as classes, by
- /// calling @ref classifyByVendor(). Second, the classification match
+ /// calling (private) classifyByVendor. Second, the classification match
/// expressions are evaluated. The resulting classes will be stored
/// in the packet (see @ref isc::dhcp::Pkt6::classes_ and
/// @ref isc::dhcp::Pkt6::inClass).
For details see documentation and code of the following handlers:
- @ref isc::lease_cmds::LeaseCmdsImpl::leaseAddHandler (lease4-add, lease6-add)
+- @ref isc::lease_cmds::LeaseCmdsImpl::lease6BulkApplyHandler(lease6-bulk-apply)
- @ref isc::lease_cmds::LeaseCmdsImpl::leaseGetHandler (lease4-get, lease6-get)
+- @ref isc::lease_cmds::LeaseCmdsImpl::leaseGetAllHandler(lease4-get-all, lease6-get-all)
+- @ref isc::lease_cmds::LeaseCmdsImpl::leaseGetPageHandler(lease4-get-page, lease6-get-page)
+- @ref isc::lease_cmds::LeaseCmdsImpl::leaseGetByHwAddressHandler(lease4-get-by-hw-address)
+- @ref isc::lease_cmds::LeaseCmdsImpl::leaseGetByClientIdHandler(lease4-get-by-client-id)
+- @ref isc::lease_cmds::LeaseCmdsImpl::leaseGetByDuidHandler(lease6-get-by-duid)
+- @ref isc::lease_cmds::LeaseCmdsImpl::leaseGetByHostnameHandler(lease4-get-by-hostname, lease6-get-by-hostname)
- @ref isc::lease_cmds::LeaseCmdsImpl::lease4DelHandler (lease4-del)
- @ref isc::lease_cmds::LeaseCmdsImpl::lease6DelHandler (lease6-del)
- @ref isc::lease_cmds::LeaseCmdsImpl::lease4UpdateHandler (lease4-update)
- @ref isc::lease_cmds::LeaseCmdsImpl::lease6UpdateHandler (lease6-update)
- @ref isc::lease_cmds::LeaseCmdsImpl::lease4WipeHandler (lease4-wipe)
- @ref isc::lease_cmds::LeaseCmdsImpl::lease6WipeHandler (lease6-wipe)
-- @ref isc::lease_cmds::LeaseCmdsImpl::lease4WriteHandler (lease4-write)
-- @ref isc::lease_cmds::LeaseCmdsImpl::lease6WriteHandler (lease6-write)
+- @ref isc::lease_cmds::LeaseCmdsImpl::lease4ResendDdnsHandler(lease4-resend-ddns)
+- @ref isc::lease_cmds::LeaseCmdsImpl::lease6ResendDdnsHandler(lease6-resend-ddns)
+- @ref isc::lease_cmds::LeaseCmdsImpl::leaseWriteHandler (lease4-write, lease6-write)
@section lease_cmdsDesigns Lease Commands Design choices
/// @param vars Environment variables for the program to be executed.
/// @param inherit_env whether the spawned process will inherit the
/// environment before adding 'vars' on top.
+ /// @param sync enables syncrhonous mode (spawning thread waits on
+ /// child to cmplete if true)
ProcessSpawnImpl(IOServicePtr io_service,
const std::string& executable,
const ProcessArgs& args,
/// This method returns the text status. If you need to get the arguments provided,
/// please use @ref parseAnswer.
///
-/// @param status_code This value will be set to the return code contained in
+/// @param rcode This value will be set to the return code contained in
/// the message
/// @param msg The message to parse
/// @return The optional argument in the message (or null)
/// @brief Detects network interfaces.
///
- /// If the @ref detect_callback_ returns true, the specific system calls are
+ /// If the detect callback returns true, the specific system calls are
/// executed, otherwise the @ref detectIfaces will return immediately.
///
/// @param update_only Only add interfaces that do not exist and update
/// @brief Detect callback used to perform actions before system dependent
/// function calls.
///
- /// If the @ref detect_callback_ returns true, the specific system calls are
+ /// If this call back returns true, the specific system calls are
/// executed, otherwise the @ref detectIfaces will return immediately.
DetectCallback detect_callback_;
/// Vendor Class option is controlled by the @c u (universe) parameter passed
/// to the constructor.
///
-/// @Currently, the enterprise id field is set to a value of the first
+/// Currently, the enterprise id field is set to a value of the first
/// enterprise id occurrence in the parsed option. This assumes that
/// all tuples in the same option are for the same vendor.
class OptionVendorClass : public Option {
void
-Pkt::addPktEvent(const std::string& label, const ptime& timestamp) {
+Pkt::addPktEvent(const std::string& label, const boost::posix_time::ptime& timestamp) {
events_.push_back(PktEvent(label, timestamp));
}
isc::Exception(file, line, what) { };
};
-
/// @brief Defines the types of DNS updates that can be requested.
enum NameChangeType {
CHG_ADD,
/// @brief Function which converts string to ConflictResolutionMode enum values.
///
-/// @param fmt_str text to convert to an enum.
+/// @param mode_str text to convert to an enum.
/// Valid string values: "check-with-dhcid", "no-check-with-dhcid",
/// "check-exists-with-dhcid", "no-check-without-dhcid"
///
/// @brief Function which converts ConflictResolutionMode enums to text labels.
///
-/// @param format enum value to convert to label
+/// @param mode ConflictResolutionMode enum value to convert to string.
///
/// @return std:string containing the text label if the value is valid, or
/// "unknown" if not.
/// If the packet belongs to the class, the class is added to the packet.
///
/// @param pkt The packet checked if it belongs to the class.
+ /// @param expr_ptr Expression the class will use to determine membership
virtual void test(PktPtr pkt, const ExpressionPtr& expr_ptr);
/// @brief Unparse a configuration object
/// If the packet belongs to the class, the class is added to the packet.
///
/// @param pkt The packet checked if it belongs to the class.
+ /// @param expr_ptr Expression the class will use to determine membership
virtual void test(PktPtr pkt, const ExpressionPtr& expr_ptr) override;
/// @brief Unparse a configuration object
/// @param filename boot-file-name value for this class (optional)
/// @param valid valid-lifetime triplet (optional)
/// @param preferred preferred-lifetime triplet (optional)
+ /// @param is_template true if class is a template class. Defaults to false.
+ /// @param offer_lft the offer lifetime assigned to the class (may be empty if not defined)
///
/// @throw DuplicateClientClassDef if class already exists within the
/// dictionary. See @ref dhcp::ClientClassDef::ClientClassDef() for
/// @brief Sets new ib-ddns-conflict-resolution-mode
///
- /// @param ddns_use_conflict_resolution New value to use.
+ /// @param ddns_conflict_resolution_mode New value to use.
void setDdnsConflictResolutionMode(const util::Optional<std::string>& ddns_conflict_resolution_mode) {
ddns_conflict_resolution_mode_ = ddns_conflict_resolution_mode;
}
/// @param subnets_list pointer to a list of IPv6 subnets
/// @param encapsulate_options a boolean parameter indicating if the
/// parsed options should be encapsulated with suboptions.
+
/// @throw DhcpConfigError if CfgMgr rejects the subnet (e.g. subnet-id is a duplicate)
size_t parse(SrvConfigPtr cfg, data::ConstElementPtr subnets_list,
bool encapsulate_options = true);
///
/// @param [out] subnets Container where parsed subnets will be stored.
/// @param subnets_list pointer to a list of IPv6 subnets
+ /// @param encapsulate_options a boolean parameter indicating if the
+ /// parsed options should be encapsulated with suboptions.
+ ///
/// @return Number of subnets created.
size_t parse(Subnet6Collection& subnets,
data::ConstElementPtr subnets_list,
///
/// @param parameters A data structure relating keywords and values
/// concerned with the database.
+ /// @param cb The dbReconnect callback.
+ /// @param timer_name The DB reconnect timer name.
///
/// @throw isc::db::ScehamInitializationFailed if the initialization fails
static void
///
/// @param parameters A data structure relating keywords and values
/// concerned with the database.
+ /// @param cb The dbReconnect callback.
+ /// @param timer_name The DB reconnect timer name.
///
/// @throw isc::db::ScehamInitializationFailed if the initialization fails
static void
/// if the given expression is true. This works around the lack of
/// GTEST_SKIP prior to googletest 1.10.
///
-/// @note This macro cannot be used in ::testing::Test::SetUp()
+/// @note This macro cannot be used in testing::Test::SetUp()
/// to skip tests (unless running with googletest 1.10 or later).
/// It must be used directly within the body of each unit test.
///
public:
/// @brief Constructor. Unloads any previously loaded libraries.
///
- /// @param lib_so_name_ full pathname to the library so file under test
+ /// @param lib_so_name full pathname to the library so file under test
LibLoadTest(const std::string lib_so_name = "no-lib-specified")
: lib_so_name_(lib_so_name) {
unloadLibraries();
/// @brief Verifies that an invalid daemon cannot load the library.
///
- /// @param libname full path to the library's SO. Typically this
- /// value is defined in the Makefile (e.g. -DLIBDHCP_BOOTP_SO=...)
/// @param daemon_name name of the daemon that should try to load the library
/// @param family Protocol family of the loading daemon, either
/// AF_INET or AF_INET6. Defaults to AF_INET.
class BaseNEncoder {
public:
- /// @Brief Constructor
+ /// @brief Constructor
///
/// @param algorithm name of the algorithm, used for logging
/// @param digit_set set of digits (i.e. alphabet) used for encoding
size_t max_pad,
bool case_sensitive);
- /// @Brief Destructor
+ /// @brief Destructor
virtual ~BaseNEncoder() = default;
/// @brief Encodes binary data using the encoder's algorithm
///
/// @param bits binary value to translate
/// @return char containing the digit corresponding to the binary value
- /// @isc_throw BadValue if the bits value is out of range
+ /// @throw BadValue if the bits value is out of range
char bitsToDigit(uint8_t bits);
/// @brief Translate a digit into the appropriate algorithm bit value