Kea 3.1.1
isc::gss_tsig::TKeyExchangeImpl Class Reference
+ Inheritance diagram for isc::gss_tsig::TKeyExchangeImpl:

Public Types

enum  State {
  NONE , STARTED , STOPPED , SUCCESS ,
  FAILURE
}
 The TKEY exchange state. More...
 

Public Member Functions

 TKeyExchangeImpl (const IOServicePtr &io_service, const DnsServerPtr &server, const GssTsigKeyPtr &key, TKeyExchange::Callback *callback, uint32_t timeout, OM_uint32 flags)
 Constructor.
 
virtual ~TKeyExchangeImpl ()
 Destructor.
 
void cancel ()
 This function cancels the started TKEY exchange.
 
void doExchange ()
 This function handles the repeated communication with the DNS server trying to complete the TKEY exchange.
 
isc::asiolink::IOServicePtr getIOService ()
 Gets IO service.
 
virtual void operator() (IOFetch::Result result)
 This internal callback is called when the DNS update message exchange is complete.
 
void setIOService (const isc::asiolink::IOServicePtr &io_service)
 Sets IO service.
 
- Public Member Functions inherited from isc::asiodns::IOFetch::Callback
 Callback ()=default
 Constructor.
 
virtual ~Callback ()=default
 Destructor.
 

Detailed Description

Definition at line 69 of file tkey_exchange.cc.

Member Enumeration Documentation

◆ State

The TKEY exchange state.

Enumerator
NONE 

Initial state: no action has been initiated.

STARTED 

The TKEY exchange has been started.

STOPPED 

The TKEY exchange has been canceled.

SUCCESS 

The TKEY exchange has succeeded.

FAILURE 

The TKEY exchange has failed.

Definition at line 72 of file tkey_exchange.cc.

Constructor & Destructor Documentation

◆ TKeyExchangeImpl()

isc::gss_tsig::TKeyExchangeImpl::TKeyExchangeImpl ( const IOServicePtr & io_service,
const DnsServerPtr & server,
const GssTsigKeyPtr & key,
TKeyExchange::Callback * callback,
uint32_t timeout,
OM_uint32 flags )

Constructor.

Parameters
io_serviceThe IOService which handles IO operations.
serverThe server for which the TKEY exchange is performed.
keyThe TKEY being updated.
callbackPointer to an object implementing TKeyExchange::Callback class. This object will be called when DNS message exchange completes or if an error occurs. NULL value disables callback invocation.
timeoutThe timeout for the IO operations.
flagsThe flags used for the TKEY exchange.
Exceptions
BadValueif io_service is null.
BadValueif key's security context has already been used.

Definition at line 205 of file tkey_exchange.cc.

References isc_throw, and NONE.

◆ ~TKeyExchangeImpl()

isc::gss_tsig::TKeyExchangeImpl::~TKeyExchangeImpl ( )
virtual

Destructor.

Definition at line 221 of file tkey_exchange.cc.

References cancel().

+ Here is the call graph for this function:

Member Function Documentation

◆ cancel()

void isc::gss_tsig::TKeyExchangeImpl::cancel ( )

This function cancels the started TKEY exchange.

Definition at line 454 of file tkey_exchange.cc.

References STOPPED.

Referenced by ~TKeyExchangeImpl().

◆ doExchange()

void isc::gss_tsig::TKeyExchangeImpl::doExchange ( )

This function handles the repeated communication with the DNS server trying to complete the TKEY exchange.

Definition at line 431 of file tkey_exchange.cc.

References isc::gss_tsig::BAD_CLIENT_CREDENTIALS, isc::gss_tsig::TKeyExchange::BAD_CREDENTIALS, isc::gss_tsig::gss_tsig_logger, isc_throw, LOG_ERROR, NONE, STARTED, and isc::Exception::what().

+ Here is the call graph for this function:

◆ getIOService()

isc::asiolink::IOServicePtr isc::gss_tsig::TKeyExchangeImpl::getIOService ( )
inline

Gets IO service.

Returns
IOService object, used for all ASIO operations.

Definition at line 116 of file tkey_exchange.cc.

◆ operator()()

◆ setIOService()

void isc::gss_tsig::TKeyExchangeImpl::setIOService ( const isc::asiolink::IOServicePtr & io_service)
inline

Sets IO service.

Parameters
io_serviceIOService object, used for all ASIO operations.

Definition at line 123 of file tkey_exchange.cc.


The documentation for this class was generated from the following file: