Skip to content

Commit b80b05d

Browse files
WOnder93stephensmalley
authored andcommitted
tests/module_load: run sh instead of bash
This avoids "bash: /root/.bashrc: Permission denied" messages when running the tests. Signed-off-by: Ondrej Mosnacek <omosnace@redhat.com> Acked-by: Stephen Smalley <stephen.smalley.work@gmail.com>
1 parent 6376643 commit b80b05d

File tree

1 file changed

+2
-2
lines changed
  • tests/module_load

1 file changed

+2
-2
lines changed

tests/module_load/test

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,12 +116,12 @@ SKIP: {
116116
system("echo 'measure func=BPRM_CHECK' > /tmp/test_ima_policy");
117117

118118
$result = system
119-
qq(runcon -t test_policy_allow_policy_load_t bash -c "echo '/tmp/test_ima_policy' > /sys/kernel/security/ima/policy");
119+
qq(runcon -t test_policy_allow_policy_load_t sh -c "echo '/tmp/test_ima_policy' > /sys/kernel/security/ima/policy");
120120
ok( $result eq 0 );
121121

122122
# Deny system { policy_load } - EACCES
123123
$result = system
124-
qq(runcon -t test_policy_deny_policy_load_t bash -c "echo '/tmp/test_ima_policy' > /sys/kernel/security/ima/policy 2>&1");
124+
qq(runcon -t test_policy_deny_policy_load_t sh -c "echo '/tmp/test_ima_policy' > /sys/kernel/security/ima/policy 2>&1");
125125
ok( $result >> 8 eq 1 );
126126

127127
system("rm -f /tmp/test_ima_policy");

0 commit comments

Comments
 (0)