*BSD News Article 15218


Return to BSD News archive

Path: sserve!newshost.anu.edu.au!munnari.oz.au!news.Hawaii.Edu!ames!agate!dog.ee.lbl.gov!newshub.nosc.mil!crash!fredbox!cyb!loodvrij
From: cyb!loodvrij@fredbox.cts.com
Newsgroups: comp.os.386bsd.development
Subject: Re: SIGKILL and kill
Keywords: SIGNALS SECURITY
Message-ID: <8TuF3B1w165w@cyb.UUCP>
Date: Thu, 22 Apr 93 18:45:18 ADT
References: <1qo3mq$d4b@news.cs.tu-berlin.de>
Organization: The Cacophonous Yodellers' BBS
Lines: 41

klier@cs.tu-berlin.de (Jan Klier) writes:

> I experienced that many users often use the command 'kill -9 pid' to kill
> a process instead of the simple version 'kill pid'. But if the SIGKILL signal
> is used to terminate a process the user will get rid of, the process itself
> has no chance to catch that and cleanup it's own data structure, flushing
> some buffers, updating databases etc.
> Most often the TERM signal will do the same job, users just don't know about
> the difference between KILL and TERM and risk (unconciously) loosing data.
> 
> My idea is now (and I post it here because it could be tested experimentally
> in 386bsd) to modify the kill-programm in order to restrict the SIGKILL signa
> to the superuser.
> This will force users to use the safe TERM-signal when the terminate processe
> and still leaves the door open for really hung situation where a SIGKILL is
> necessary.
> 
> Any comments?

A few.

        1)  As someone who has been a user, I'd have been VERY annoyed at
this.  I know what I'm doing thank you, and unnessecary restrictions like
these get up my nose.

        2)  Users might legitimately need to use SIGKILL if their program is
badly crashed and/or traps SIGTERM et al.

        3)  It ain't just the kill program you'd have to modify.  Kill is a
built-in in some shells.

        4)  It wouldn't stop users writing their own kill programs unless you
made the changes at the kernel level, which is overkill (sic) IMHO.

Lood.


--                                           _______________________________
Bruce J. Keeler (Ye Olde British Weirdo)    | "We are the knights who say:  |
Internet: cyb!loodvrij@fredbox.cts.com      |          COBOL !!!!!"         |
Voice: (907) 337-8193, Place: Anchorage, AK |_______________________________|