Re: local denial-of-service with file leases

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



* Trond Myklebust ([email protected]) wrote:
> On Fri, 2005-11-11 at 10:35 -0800, Chris Wright wrote:
> > * Trond Myklebust ([email protected]) wrote:
> > > Bruce has a simpler patch (see attachment). The call to fasync_helper()
> > > in order to free active structures will have already been done in
> > > locks_delete_lock(), so in principle, all we want to do is to skip the
> > > fasync_helper() call in fcntl_setlease().
> > 
> > Yes, that's better, thanks.  Will you make sure it gets to Linus?
> 
> Sure, but I'd like a mail from Avi confirming that this patch too fixes
> his problem, please.

OK, I tested with Avi's test program, and a couple other's I cobbled
together, and they seem to work fine.  But didn't test the samba case
(shouldn't be different...but...).  BTW, the bit below looks like
debugging code.  It's a way for users to spam the kernel log (granted
there is some bit of throttling):

thanks,
-chris
--

Remove time_out_leases() printk that's easily triggered by users.

Signed-off-by: Chris Wright <[email protected]>
---

diff --git a/fs/locks.c b/fs/locks.c
--- a/fs/locks.c
+++ b/fs/locks.c
@@ -1105,7 +1105,6 @@ static void time_out_leases(struct inode
 			before = &fl->fl_next;
 			continue;
 		}
-		printk(KERN_INFO "lease broken - owner pid = %d\n", fl->fl_pid);
 		lease_modify(before, fl->fl_type & ~F_INPROGRESS);
 		if (fl == *before)	/* lease_modify may have freed fl */
 			before = &fl->fl_next;



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux