diff --git a/tests/regression/apparmor/changehat_misc.sh b/tests/regression/apparmor/changehat_misc.sh index c305ba942..af6afd9b9 100755 --- a/tests/regression/apparmor/changehat_misc.sh +++ b/tests/regression/apparmor/changehat_misc.sh @@ -64,7 +64,7 @@ echo echo "*** A 'Killed' message from bash is expected for the following test" runchecktest "CHANGEHAT (subprofile->subprofile w/ bad magic)" signal9 $subtest $subtest2 badmagic $file -# 1. ATTEMPT TO CHANGEGAT TO AN INVALUD PROFILE, SHOULD PUT US INTO A NULL +# 1. ATTEMPT TO CHANGEHAT TO AN INVALID PROFILE, SHOULD PUT US INTO A NULL # PROFILE # 2. ATTEMPT TO CHANGEHAT OUT WITH BAD TOKEN settest changehat_fail diff --git a/tests/regression/apparmor/mkprofile.pl b/tests/regression/apparmor/mkprofile.pl index 118dcb014..00e31fc96 100755 --- a/tests/regression/apparmor/mkprofile.pl +++ b/tests/regression/apparmor/mkprofile.pl @@ -5,7 +5,7 @@ # # Gawd, I hate writing perl. It shows, too. # -my $__VERSION__='$Id$'; +my $__VERSION__=$0; use strict; use Getopt::Long; diff --git a/tests/regression/apparmor/pwrite.sh b/tests/regression/apparmor/pwrite.sh index 0c4530fca..a912c1d4c 100755 --- a/tests/regression/apparmor/pwrite.sh +++ b/tests/regression/apparmor/pwrite.sh @@ -27,7 +27,7 @@ badreadperm=w genprofile $file:$okperm -runtestbg "PWRITE with w" pass $file +runtestbg "PREAD/PWRITE with rw" pass $file sleep 2 diff --git a/tests/regression/apparmor/swap.sh b/tests/regression/apparmor/swap.sh index cb77c5696..5ac145743 100755 --- a/tests/regression/apparmor/swap.sh +++ b/tests/regression/apparmor/swap.sh @@ -32,7 +32,7 @@ bin=$pwd swap_file=$tmpdir/swapfile dd if=/dev/zero of=${swap_file} bs=1024 count=512 2> /dev/null -/sbin/mkswap ${swap_file} > /dev/null +/sbin/mkswap -f ${swap_file} > /dev/null # TEST 1. Make sure can enable and disable swap unconfined diff --git a/tests/regression/apparmor/syscall.sh b/tests/regression/apparmor/syscall.sh index bb7eee986..8d98b40a4 100755 --- a/tests/regression/apparmor/syscall.sh +++ b/tests/regression/apparmor/syscall.sh @@ -1,7 +1,7 @@ #! /bin/bash -# $Id$ - +# # Copyright (C) 2002-2005 Novell/SUSE +# Copyright (C) 2010 Canonical, Ltd. # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License as @@ -114,9 +114,9 @@ rm -f $mknod_file runchecktest "MKNOD sock (permissions)" fail s $mknod_file ## -## D. SETHOSTNAME +## C. SYSCTL ## -sh syscall_sysctl.sh +bash syscall_sysctl.sh ## ## D. SETHOSTNAME diff --git a/tests/regression/apparmor/unix_fd_server.c b/tests/regression/apparmor/unix_fd_server.c index 2d99c664d..89abbcd47 100644 --- a/tests/regression/apparmor/unix_fd_server.c +++ b/tests/regression/apparmor/unix_fd_server.c @@ -2,6 +2,7 @@ /* * Copyright (C) 2002-2005 Novell/SUSE + * Copyright (C) 2010 Canonical, Ltd. * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License as @@ -134,6 +135,7 @@ int main (int argc, char * argv[]) { } /* Check for info re: reading the file */ + memset(inbound_buffer, 0, sizeof(inbound_buffer)); if (recv(in_sock, inbound_buffer, 16,0) == -1 ) { fprintf(stderr, "FAIL - recv %s\n", strerror(errno));