Independent IPsec/IKE Tasks
Table of Contents >> IPsec/IKE Programmer's Reference
Independent IPsec Task
IPsec processing can be run in its own separate task. This is advantageous as it moves timeconsuming cryptographic computations out of the Treck Receive Task affording other network services access to incoming data at a higher rate.
The IPsec Task can be run in blocking or non-blocking mode, supporting the use of an Operating System or a Super Loop / Executive as described in the following sections.
To enable use of the IPsec Task, define TM_USE_IPSEC_TASK in <trsystem.h>.
The IPsec Task requires its own queue. As such, the queue size must be specified. This limits new incoming packets when the queue is full. To configure the size of this queue, define the following macro in <trsystem.h> with the appropriate size as require by system memory contraints and processing requirements:
#define TM_IPSEC_TASK_MAX_QUEUE_SIZE 16384
To execute the IPsec task call tfUserIpsecExecute().
Independent IKE Task
IKE processing can be run in its own separate task. This is advantageous as it moves time-consuming cryptographic computations out of the Treck Receive Task affording other network services access to incoming data at a higher rate.
The IKE Task can be run in blocking or non-blocking mode, supporting the use of an Operating System or a Super Loop / Executive as described in the following sections.
To enable use of the IKE Task, define TM_USE_IKE_TASK in <trsystem.h>.
To execute the IKE task call tfIkeUserExecute().
To shutdown the IKE task call tfIkeTaskShutdown().
IPsec Handoff Task
When using the Independent IPsec Task, another independent task can be created to handle post-IPsec packet processing. This is advantageous as it moves non-crypto processing out of the IPsec task allowing the crypto engine to be fed data more quickly.
To enable usage of the IPsec handoff task, define TM_USE_IPSEC_HANDOFF_TASK in <trsystem.h>.
To specify the queue size of the IPsec Handoff Task use TM_IPSEC_HANDOFF_TASK_MAX_QUEUE_SIZE.
#define TM_IPSEC_HANDOFF_TASK_MAX_QUEUE_SIZE 16384
This task can be run in blocking or non-blocking mode supporting the use of an Operating System or a Super Loop / Executive as described in the following sections. To execute the IPsec Handoff Task call tfUserIpsecHandoffExecute().