Re: Fork Bombing Patch

From: Chris Snook
Date: Mon Aug 20 2007 - 10:42:59 EST


Anand Jahagirdar wrote:
Hi
As Per the Previous Discussion of my Patch,I think insted of using
KERN_CRIT,it is better to lower the priority level to KERN_WARNING.
thats why i used KERN_WARNING.it will warn administrator and its
administrator responsibility to take whatever action he want to take.

anand

Philosophically, I'm okay with the idea of a forkbomb meriting KERN_WARN priority, but we should never have a printk that can be trivially triggered by an unprivileged user that gets anything higher than KERN_INFO. If I'm an attacker, and I want to do bad things without getting logged, the first thing I do is launch a carefully-tuned forkbomb that doesn't bog down the system, just triggers this message as often as the ratelimit will allow. Once /var/log is full, I can do my nastiness. Administrators need to be able to protect against that kind of thing without losing the ability to log KERN_WARN and higher priority messages.

Also, I stand by my assertion that we should only be complaining if the hard limit is also exceeded, since it's totally valid for an application to self-constrain using soft limits. It may be uncommon, but the people who happen to use whatever applications do this will be very unhappy when they update their kernel and /var fills up from this spew.

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