[Pkg-shadow-devel] Bug#269573: {add|remove}-shell should be recoded in C

Nicolas François nicolas.francois@centraliens.net
Sat, 16 Apr 2005 11:47:03 +0200


On Sat, Apr 16, 2005 at 11:18:40AM +0200, Christian Perrier wrote:
> Quoting Alexander Gattin (arg@online.com.ua):
> 
> 
> > Or I don't understand something obvious? Seems that
> > bash wouldn't be removed inbetween `#! /bin/sh -e` ;)
> > and `/usr/sbin/remove-shell /bin/bash`
> > 
> > P.S. I can try removing bash at Monday (at work).
> > Will get much fun, I think. :) But some shell should be
> > present on system -- maybe _real Korn shell_ then? ;)
> 
> This should be done in a chroot jail. This was the bug submitter
> rationale.

I agree with Alexander analysis.

bash should not have a postrm script.

I could reproduce the submitter bug even with a woody, whose postrm
script doesn't call remove-shell.

However, if I move the content of postrm into prerm (and remove postrm), I
can purge bash without any problem.

It looks like a bash bug to me.
(Also, I'm not really interested in coding {add,remove}-shhel in C, so I
will find whatever excuse not to do it ;)

-- 
Nekral