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

Re: Questions regarding bash and sh.



On Thu, May 21, 2009 at 01:53:08AM +0700, Sthu Deus wrote:

> I have noticed that for some users in /etc/passwd the shell
> environment is set as bash and for some as sh. This has led me to the
> following questions:
> . Why is it so, meaning what is the meaning of it?

System accounts and system scripts have traditionally used the Bourne
shell for compatibility. So, it's either for legacy compatibility, or
because the Debian policy requires it.

> . Do I give more insecure environment to a user setting for him sh
> instead of bash?

Neither shell is really "secure." Even rbash isn't really secure,
although it's certainly better than the default...if you can get it to
work with your scripts. As far as compatibility, though, you could set
things to ksh if you wanted, and it will probably work most of the time.
Most Bourne derivatives are supersets of sh, so requiring sh is mostly
just a compatibility thing.

-- 
"Oh, look: rocks!"
	-- Doctor Who, "Destiny of the Daleks"


Reply to: