pub unsafe extern "C" fn otNat64SetIp4Cidr(
aInstance: *mut otInstance,
aCidr: *const otIp4Cidr,
) -> otError
Expand description
Sets the CIDR used when setting the source address of the outgoing translated IPv4 packets.
Is available only when OPENTHREAD_CONFIG_NAT64_TRANSLATOR_ENABLE is enabled.
@note A valid CIDR must have a non-zero prefix length. The actual addresses pool is limited by the size of the mapping pool and the number of addresses available in the CIDR block.
@note This function can be called at any time, but the NAT64 translator will be reset and all existing sessions will be expired when updating the configured CIDR.
@param[in] aInstance A pointer to an OpenThread instance. @param[in] aCidr A pointer to an otIp4Cidr for the IPv4 CIDR block for NAT64.
@retval OT_ERROR_INVALID_ARGS The given CIDR is not a valid IPv4 CIDR for NAT64. @retval OT_ERROR_NONE Successfully set the CIDR for NAT64.
@sa otBorderRouterSend @sa otBorderRouterSetReceiveCallback