Kea 2.7.5
|
Parameters pertaining to individual IAs. More...
#include <alloc_engine.h>
Public Member Functions | |
IAContext () | |
Default constructor. | |
void | addHint (const asiolink::IOAddress &prefix, const uint8_t prefix_len=128, const uint32_t preferred=0, const uint32_t valid=0) |
Convenience method adding new hint. | |
void | addHint (const Option6IAAddrPtr &iaaddr) |
Convenience method adding new hint from IAADDR option. | |
void | addHint (const Option6IAPrefixPtr &iaprefix) |
Convenience method adding new hint from IAPREFIX option. | |
void | addNewResource (const asiolink::IOAddress &prefix, const uint8_t prefix_len=128) |
Convenience method adding new prefix or address. | |
bool | isNewResource (const asiolink::IOAddress &prefix, const uint8_t prefix_len=128) const |
Checks if specified address or prefix was new. | |
Public Attributes | |
Lease6Collection | changed_leases_ |
A pointer to any leases that have changed FQDN information. | |
HintContainer | hints_ |
Client's hints. | |
Option6IAPtr | ia_rsp_ |
A pointer to the IA_NA/IA_PD option to be sent in response. | |
uint32_t | iaid_ |
The IAID field from IA_NA or IA_PD that is being processed. | |
ResourceContainer | new_resources_ |
Holds addresses and prefixes allocated for this IA. | |
Lease6Collection | old_leases_ |
A pointer to any old leases that the client had before update but are no longer valid after the update/allocation. | |
Lease6Collection | reused_leases_ |
Set of leases marked for reuse by lease caching. | |
Lease::Type | type_ |
Lease type (IA or PD) | |
Parameters pertaining to individual IAs.
Definition at line 293 of file alloc_engine.h.
isc::dhcp::AllocEngine::ClientContext6::IAContext::IAContext | ( | ) |
Default constructor.
Initializes type_ to Lease::TYPE_NA
and iaid_ to 0.
Definition at line 225 of file alloc_engine.cc.
void isc::dhcp::AllocEngine::ClientContext6::IAContext::addHint | ( | const asiolink::IOAddress & | prefix, |
const uint8_t | prefix_len = 128, | ||
const uint32_t | preferred = 0, | ||
const uint32_t | valid = 0 ) |
Convenience method adding new hint.
prefix | Prefix or address. |
prefix_len | Prefix length. Default is 128 for addresses. |
preferred | Wanted preferred lifetime. Default 0. |
valid | Wanted valid lifetime. Default 0. |
Definition at line 231 of file alloc_engine.cc.
Referenced by isc::dhcp::Dhcpv6Srv::assignIA_NA(), isc::dhcp::Dhcpv6Srv::assignIA_PD(), isc::dhcp::Dhcpv6Srv::extendIA_NA(), and isc::dhcp::Dhcpv6Srv::extendIA_PD().
void isc::dhcp::AllocEngine::ClientContext6::IAContext::addHint | ( | const Option6IAAddrPtr & | iaaddr | ) |
Convenience method adding new hint from IAADDR option.
iaaddr | Pointer to IAADDR. |
BadValue | if iaaddr is null. |
Definition at line 240 of file alloc_engine.cc.
References isc_throw.
void isc::dhcp::AllocEngine::ClientContext6::IAContext::addHint | ( | const Option6IAPrefixPtr & | iaprefix | ) |
Convenience method adding new hint from IAPREFIX option.
iaprefix | Pointer to IAPREFIX. |
BadValue | if iaprefix is null. |
Definition at line 250 of file alloc_engine.cc.
References isc_throw.
void isc::dhcp::AllocEngine::ClientContext6::IAContext::addNewResource | ( | const asiolink::IOAddress & | prefix, |
const uint8_t | prefix_len = 128 ) |
Convenience method adding new prefix or address.
prefix | Prefix or address |
prefix_len | Prefix length. Default is 128 for addresses. |
Definition at line 260 of file alloc_engine.cc.
bool isc::dhcp::AllocEngine::ClientContext6::IAContext::isNewResource | ( | const asiolink::IOAddress & | prefix, |
const uint8_t | prefix_len = 128 ) const |
Checks if specified address or prefix was new.
prefix | Prefix or address |
prefix_len | Prefix length. Default is 128 for addresses. |
Definition at line 267 of file alloc_engine.cc.
Referenced by isc::dhcp::AllocEngine::renewLeases6().
Lease6Collection isc::dhcp::AllocEngine::ClientContext6::IAContext::changed_leases_ |
A pointer to any leases that have changed FQDN information.
This list may contain old versions of the leases that are still valid. In particular, it will contain a lease if the client's FQDN has changed.
Definition at line 323 of file alloc_engine.h.
HintContainer isc::dhcp::AllocEngine::ClientContext6::IAContext::hints_ |
Client's hints.
There will typically be just one address, but the protocol allows more than one address or prefix for each IA container.
Definition at line 306 of file alloc_engine.h.
Referenced by isc::dhcp::Dhcpv6Srv::extendIA_NA(), isc::dhcp::Dhcpv6Srv::extendIA_PD(), and isc::dhcp::AllocEngine::getLifetimes6().
Option6IAPtr isc::dhcp::AllocEngine::ClientContext6::IAContext::ia_rsp_ |
A pointer to the IA_NA/IA_PD option to be sent in response.
Definition at line 335 of file alloc_engine.h.
Referenced by isc::dhcp::Dhcpv6Srv::assignIA_NA(), isc::dhcp::Dhcpv6Srv::assignIA_PD(), isc::dhcp::Dhcpv6Srv::extendIA_NA(), and isc::dhcp::Dhcpv6Srv::extendIA_PD().
uint32_t isc::dhcp::AllocEngine::ClientContext6::IAContext::iaid_ |
The IAID field from IA_NA or IA_PD that is being processed.
Definition at line 297 of file alloc_engine.h.
Referenced by isc::dhcp::AllocEngine::allocateLeases6(), isc::dhcp::Dhcpv6Srv::assignIA_NA(), isc::dhcp::Dhcpv6Srv::assignIA_PD(), isc::dhcp::Dhcpv6Srv::extendIA_NA(), isc::dhcp::Dhcpv6Srv::extendIA_PD(), and isc::dhcp::AllocEngine::renewLeases6().
ResourceContainer isc::dhcp::AllocEngine::ClientContext6::IAContext::new_resources_ |
Holds addresses and prefixes allocated for this IA.
This collection is used to update at most once new leases.
Definition at line 331 of file alloc_engine.h.
Lease6Collection isc::dhcp::AllocEngine::ClientContext6::IAContext::old_leases_ |
A pointer to any old leases that the client had before update but are no longer valid after the update/allocation.
This collection is typically empty, except cases when we are doing address reassignment, e.g. because there is a host reservation that gives this address to someone else, so we had to return the address, and give a new one to this client.
Definition at line 315 of file alloc_engine.h.
Referenced by isc::dhcp::Dhcpv6Srv::extendIA_NA(), isc::dhcp::Dhcpv6Srv::extendIA_PD(), and isc::dhcp::Dhcpv6Srv::releaseLeases().
Lease6Collection isc::dhcp::AllocEngine::ClientContext6::IAContext::reused_leases_ |
Set of leases marked for reuse by lease caching.
Definition at line 326 of file alloc_engine.h.
Referenced by isc::dhcp::Dhcpv6Srv::assignIA_NA().
Lease::Type isc::dhcp::AllocEngine::ClientContext6::IAContext::type_ |
Lease type (IA or PD)
Definition at line 300 of file alloc_engine.h.
Referenced by isc::dhcp::AllocEngine::allocateLeases6(), isc::dhcp::Dhcpv6Srv::assignIA_NA(), isc::dhcp::Dhcpv6Srv::assignIA_PD(), isc::dhcp::Dhcpv6Srv::extendIA_NA(), isc::dhcp::Dhcpv6Srv::extendIA_PD(), and isc::dhcp::AllocEngine::renewLeases6().