[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <17087.1272011944@redhat.com>
Date: Fri, 23 Apr 2010 09:39:04 +0100
From: David Howells <dhowells@...hat.com>
To: Toshiyuki Okajima <toshi.okajima@...fujitsu.com>
Cc: dhowells@...hat.com, keyrings@...ux-nfs.org, security@...nel.org,
linux-security-module@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 0/1][BUG][IMPORTANT] KEYRINGS: find_keyring_by_name() can gain the freed keyring
Toshiyuki Okajima <toshi.okajima@...fujitsu.com> wrote:
> #!/bin/sh
>
> LOOP=100000
> USER=dummy_user
> # add
> /bin/su -c "exit;" $USER || { /usr/sbin/adduser -m $USER; add=1; }
>
> for ((i=0; i<LOOP; i++))
> do
> /bin/su -c "echo '$i' > /dev/null" $USER
> done
>
> # del
> (( add == 1 )) && /usr/sbin/userdel -r $USER
> exit
Doing:
for ((i=0; i<100000; i++)); do keyctl session wibble /bin/true || break; done
ought to work too.
David
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists