xref: /freebsd/tests/sys/netipsec/tunnel/aesni_aes_gcm_128.sh (revision d0b2dbfa0ecf2bbc9709efc5e20baf8e4b44bbbf)
1
2. $(atf_get_srcdir)/utils.subr
3
4atf_test_case "v4" "cleanup"
5v4_head()
6{
7	atf_set descr 'IPSec inet4 tunnel using aes-gcm-128 and AESNI'
8	atf_set require.user root
9}
10
11v4_body()
12{
13	# load AESNI module if not already
14	kldstat -q -n aesni || kldload aesni
15
16	ist_test 4 aes-gcm-16 "12345678901234567890"
17}
18
19v4_cleanup()
20{
21	ist_cleanup
22}
23
24atf_test_case "v6" "cleanup"
25v6_head()
26{
27	atf_set descr 'IPSec inet6 tunnel using aes-gcm-128 and AESNI'
28	atf_set require.user root
29}
30
31v6_body()
32{
33	# load AESNI module if not already
34	kldstat -q -n aesni || kldload aesni
35
36	ist_test 6 aes-gcm-16 "12345678901234567890"
37}
38
39v6_cleanup()
40{
41	ist_cleanup
42}
43
44atf_init_test_cases()
45{
46	atf_add_test_case "v4"
47	atf_add_test_case "v6"
48}
49