mirror of
https://github.com/freebsd/freebsd-src
synced 2024-07-09 04:36:31 +00:00
if_ovpn tests: add aes-128-gcm test case
Sponsored by: Rubicon Communications, LLC ("Netgate")
This commit is contained in:
parent
2c58d0cb3b
commit
832c8a58e1
|
@ -915,17 +915,10 @@ ra_cleanup()
|
|||
ovpn_cleanup
|
||||
}
|
||||
|
||||
|
||||
atf_test_case "chacha" "cleanup"
|
||||
chacha_head()
|
||||
ovpn_algo_body()
|
||||
{
|
||||
atf_set descr 'Test DCO with the chacha algorithm'
|
||||
atf_set require.user root
|
||||
atf_set require.progs openvpn
|
||||
}
|
||||
algo=$1
|
||||
|
||||
chacha_body()
|
||||
{
|
||||
ovpn_init
|
||||
|
||||
l=$(vnet_mkepair)
|
||||
|
@ -943,8 +936,8 @@ chacha_body()
|
|||
dev-type tun
|
||||
proto udp4
|
||||
|
||||
cipher CHACHA20-POLY1305
|
||||
data-ciphers CHACHA20-POLY1305
|
||||
cipher ${algo}
|
||||
data-ciphers ${algo}
|
||||
auth SHA256
|
||||
|
||||
local 192.0.2.1
|
||||
|
@ -967,6 +960,9 @@ chacha_body()
|
|||
|
||||
client
|
||||
|
||||
cipher ${algo}
|
||||
data-ciphers ${algo}
|
||||
|
||||
remote 192.0.2.1
|
||||
auth-user-pass $(atf_get_srcdir)/user.pass
|
||||
|
||||
|
@ -984,11 +980,42 @@ chacha_body()
|
|||
atf_check -s exit:0 -o ignore jexec b ping -c 3 198.51.100.1
|
||||
}
|
||||
|
||||
atf_test_case "chacha" "cleanup"
|
||||
chacha_head()
|
||||
{
|
||||
atf_set descr 'Test DCO with the chacha algorithm'
|
||||
atf_set require.user root
|
||||
atf_set require.progs openvpn
|
||||
}
|
||||
|
||||
chacha_body()
|
||||
{
|
||||
ovpn_algo_body CHACHA20-POLY1305
|
||||
}
|
||||
|
||||
chacha_cleanup()
|
||||
{
|
||||
ovpn_cleanup
|
||||
}
|
||||
|
||||
atf_test_case "gcm_128" "cleanup"
|
||||
gcm_128_head()
|
||||
{
|
||||
atf_set descr 'Test DCO with AES-128-GCM'
|
||||
atf_set require.user root
|
||||
atf_set require.progs openvpn
|
||||
}
|
||||
|
||||
gcm_128_body()
|
||||
{
|
||||
ovpn_algo_body AES-128-GCM
|
||||
}
|
||||
|
||||
gcm_128_cleanup()
|
||||
{
|
||||
ovpn_cleanup
|
||||
}
|
||||
|
||||
atf_init_test_cases()
|
||||
{
|
||||
atf_add_test_case "4in4"
|
||||
|
@ -1002,4 +1029,5 @@ atf_init_test_cases()
|
|||
atf_add_test_case "route_to"
|
||||
atf_add_test_case "ra"
|
||||
atf_add_test_case "chacha"
|
||||
atf_add_test_case "gcm_128"
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user