FIX: IPsec TNL mode func
[csit.git] / resources / libraries / robot / crypto / ipsec.robot
index 5064646..5c0fc86 100644 (file)
 | | ... | \| GigabitEthernet0/8/0 \| ${encr_alg} \| sixteenbytes_key \
 | | ... | \| ${auth_alg} \| twentybytessecretkey \| ${1000} \| ${1001} \
 | | ... | \| 192.168.4.4 \| 192.168.3.3 \| 192.168.100.3 \| 192.168.100.2 \|
+| | ...
 | | [Arguments] | ${node} | ${interface} | ${crypto_alg} | ${crypto_key}
 | | ... | ${integ_alg} | ${integ_key} | ${l_spi} | ${r_spi} | ${l_ip}
 | | ... | ${r_ip} | ${l_tunnel}=${None} | ${r_tunnel}=${None}
+| | ... | ${is_ipv6}=${FALSE}
+| | ...
 | | Set Test Variable | ${l_sa_id} | ${10}
 | | Set Test Variable | ${r_sa_id} | ${20}
 | | ${spd_id}= | Set Variable | ${1}
 | | VPP IPsec Add SPD | ${node} | ${spd_id}
 | | VPP IPsec SPD Add If | ${node} | ${spd_id} | ${interface}
 | | ${action}= | Policy Action Bypass
-| | VPP IPsec SPD Add Entry | ${node} | ${spd_id} | ${p_hi} | ${action}
-| | ... | inbound=${TRUE} | proto=${ESP_PROTO}
-| | VPP IPsec SPD Add Entry | ${node} | ${spd_id} | ${p_hi} | ${action}
-| | ... | inbound=${FALSE} | proto=${ESP_PROTO}
+| | VPP IPsec Policy Add | ${node} | ${spd_id} | ${p_hi} | ${action}
+| | ... | inbound=${TRUE} | proto=${ESP_PROTO} | is_ipv6=${is_ipv6}
+| | ... | laddr_range=${tg_tun_ip} | raddr_range=${dut_tun_ip}
+| | VPP IPsec Policy Add | ${node} | ${spd_id} | ${p_hi} | ${action}
+| | ... | inbound=${FALSE} | proto=${ESP_PROTO} | is_ipv6=${is_ipv6}
+| | ... | laddr_range=${dut_tun_ip} | raddr_range=${tg_tun_ip}
 | | ${action}= | Policy Action Protect
-| | VPP IPsec SPD Add Entry | ${node} | ${spd_id} | ${p_lo} | ${action}
+| | VPP IPsec Policy Add | ${node} | ${spd_id} | ${p_lo} | ${action}
 | | ... | sa_id=${r_sa_id} | laddr_range=${l_ip}
 | | ... | raddr_range=${r_ip} | inbound=${TRUE}
-| | VPP IPsec SPD Add Entry | ${node} | ${spd_id} | ${p_lo} | ${action}
+| | VPP IPsec Policy Add | ${node} | ${spd_id} | ${p_lo} | ${action}
 | | ... | sa_id=${l_sa_id} | laddr_range=${l_ip}
 | | ... | raddr_range=${r_ip} | inbound=${FALSE}
 
-| Update IPSec SA keys
-| | [Documentation] | Update IPsec SA keys on VPP node.
-| | ...
-| | ... | *Arguments:*
-| | ... | - node - VPP node to update SA keys. Type: dictionary
-| | ... | - l_sa_id - Local SA ID. Type: string
-| | ... | - r_sa_id - Remote SA ID. Type: string
-| | ... | - crypto_key - Encryption key. Type: string
-| | ... | - integ_key - Integrity key. Type: string
-| | ...
-| | ... | *Example:*
-| | ... | \| Update IPSec SA keys \| ${nodes['DUT1']} \
-| | ... | \| 10 \| 20 \| sixteenbytes_key \| twentybytessecretkey \|
-| | [Arguments] | ${node} | ${l_sa_id} | ${r_sa_id} | ${crypto_key}
-| | ... | ${integ_key}
-| | VPP IPsec SA Set Key | ${dut_node} | ${l_sa_id} | ${crypto_key}
-| | ... | ${integ_key}
-| | VPP IPsec SA Set Key | ${dut_node} | ${r_sa_id} | ${crypto_key}
-| | ... | ${integ_key}
-
 | Send IPsec Packet and verify ESP encapsulation in received packet
 | | [Documentation] | Send IPsec packet from TG to DUT. Receive IPsec packet\
 | | ... | from DUT on TG and verify ESP encapsulation.
 | | ... | ${args} --dst_tun ${r_tunnel}
 | | Run Traffic Script On Node | ipsec.py | ${node} | ${args}
 
-| Set up IPv4 IPSec functional test
-| | [Documentation]
-| | ... | Set up IPv4 IPSec functional test.
-| | ...
-| | Set up functional test
-| | Configure topology for IPv4 IPsec testing
-
-| Set up IPv6 IPSec functional test
-| | [Documentation]
-| | ... | Set up IPv6 IPSec functional test.
-| | ...
-| | Set up functional test
-| | Configure topology for IPv6 IPsec testing
-
-| Tear down IPSec functional test
-| | [Documentation]
-| | ... | Tear down IPSec functional test.
-| | ...
-| | ... | *Example:*
-| | ...
-| | ... | \| Tear down IPSec functional test \| ${dut_node} \|
-| | ...
-| | [Arguments] | ${dut_node}
-| | ...
-| | VPP IPsec Show | ${dut_node}
-| | Tear down functional test
-
 | Set up IPSec SW device functional test
 | | [Documentation]
 | | ... | Set up IPSec SW device functional test for required IP version.
 | | | ... | ${sw_dev_count}
 | | | Run keyword | ${dut}.Add DPDK SW Cryptodev | aesni_gcm | ${socket_id}
 | | | ... | ${sw_dev_count}
-| | Apply startup configuration on all VPP DUTs | restart_vpp=${FALSE}
-| | Set up functional test
+| | Write startup configuration on all VPP DUTs
+| | Set up VPP device test
 | | Run Keyword | Configure topology for ${ip_version} IPsec testing
 
 | Tear down IPSec SW device functional test
 | | ...
 | | ${duts}= | Get Matches | ${nodes} | DUT*
 | | :FOR | ${dut} | IN | @{duts}
-| | | VPP IPsec Show | ${nodes['${dut}']}
 | | | Run keyword | ${dut}.Restore Config
-| | Tear down functional test
+| | Tear down VPP device test