Martin Michlmayr <[EMAIL PROTECTED]> writes:

> I'd rather end up in $HOME than in / whene the current working dir
> doesn't exist in the chroot:

This sounds reasonable.  However, I would like to consider the
implications, particularly for security.  This would mean doing the
following:

1. Try $PWD
2. Try $HOME
3. Try passwd pw_dir
4. Use /

While this might make sense for login shells, I'm unhappy doing this
for normal commands.  Consider

  $ schroot -c chroot -- rm -f foo

Depending on where you are in the filesystem, this might run in the
current directory (if bind mounted or otherwise available inside the
chroot), the home directory, or the root directory.  Because of the
danger here, I want it to be as deterministic as is reasonably
possible.


Does anyone have any other opinions or advice?

How do other tools handle this?


Regards,
Roger

-- 
Roger Leigh
                Printing on GNU/Linux?  http://gutenprint.sourceforge.net/
                Debian GNU/Linux        http://www.debian.org/
                GPG Public Key: 0x25BFB848.  Please sign and encrypt your mail.

Attachment: pgpiWA3Lmj8eX.pgp
Description: PGP signature

Reply via email to