@CHIP-RTOS C Library V2.06 - TCP/IP API
IPsec_Restore_Policy
Restore IP security policy and/or preshared keys from file. int IPsec_Restore_Policy(const char *filename) ;
Parameters
filename
- Path to binary file containing IP
security policy and preshared keys.
Return Value
- Zero on success
On failure non-zero indicates error:
-3 : Policy file exceeded 64 Kbyte size limit
-4 : Work buffer memory allocation failed
-5 : Invalid policy file contents
202 : Policy file open failed
Between 1000 and 1999 :
Policy add operation failed. Subtract 1000 from
this error code and look
here
for resulting error code description.
Between 2000 and 2999:
Preshared key add operation failed. Subtract
2000 from this error code and look
here
for resulting error code description.
Comments
- The IP security must be
started
prior to using this API.
This API allows IP security policy and preshared keys to be
set based on a stored binary file's contents. The file can be created
with the IPsec_Store_Policy()
library function, or other tools conforming to the
specified
format.
The policies from the file are appended to any which are already
in affect. The
IPsec_Clear_Policy()
can be used before this API for a fresh start.
An alternative way to load policy from file is to use the
POLICY_FILE
entry in the CHIP.INI file.
See Also
RTOS API
- This library function invokes a RTOS software interrupt.
Refer to the RTOS API function
IPSEC_VECTORS
for more details.
Supported since or modified in @CHIP-RTOS version-
SC12 | SC13 | SC11 | SC1x3 |
-
n/a | n/a | n/a | V1.07 |
Supported by @CHIP-RTOS C Library since version
This API List
List of C Libraries
@CHIP-RTOS Main Index
End of document
|