summaryrefslogtreecommitdiffstats
path: root/plugins/sudoers/regress/visudo/test4.sh
blob: 465b91c8808c25fc926c08dacb92e12e571bcd5b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/sh
#
# Test cycle detection and duplicate entries.
# Prior to sudo 1.8.7 this resulted in a false positive.
#

: ${VISUDO=visudo}

$VISUDO -csf - <<EOF
Host_Alias H1 = host1
Host_Alias H2 = H1, host2
Host_Alias H3 = H1, H2
root H3 = ALL
EOF

exit 0