Re: calling "su" after "chroot"
From: Chris Lowth (please@no.spam)
Date: 03/09/03
- Next message: Nico Kadel-Garcia: "Re: WebDAV vs. FTP"
- Previous message: David: "Re: Macromedia Warns Of Flash Security Flaw"
- In reply to: panda: "calling "su" after "chroot""
- Next in thread: Nico Kadel-Garcia: "Re: calling "su" after "chroot""
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
From: Chris Lowth <please@no.spam> Date: Sun, 09 Mar 2003 17:20:07 +0000
panda wrote:
> Dear ALL,
>
> I've called "chroot" to limit the root directory. When i then call
> "su - user1", the system said the user id "user1" is not found. However,
> the user is really in the system. In addition, I've already copied the
> /etc/passwd file to the current user's /etc directory.
>
> Any idea? Thanks.
>
> panda
You need rather more than /etc/passwd. Running "strace" on the su program
shows that (on my system anyway), the following files are used..
/etc/passwd, /etc/shadow, /etc/group
/etc/pam.d/*
/etc/nsswitch.conf /etc/localtime
Plus the shell program (bash), the libraries it uses.
To get the list do (as root) ..
strace -o /tmp/out -f su -l user1
Then exit the su'd shell and grep for "/" in /tmp/out
Chris
-- These ramblings are not sanctioned by my employer, mother or kids. My views are my own. My real address is: chris at lowth dot sea oh em +------------------------------------------------+ | visit: http://protector.sourceforge.net | | for OpenSource (free) virus protection | +------------------------------------------------+
- Next message: Nico Kadel-Garcia: "Re: WebDAV vs. FTP"
- Previous message: David: "Re: Macromedia Warns Of Flash Security Flaw"
- In reply to: panda: "calling "su" after "chroot""
- Next in thread: Nico Kadel-Garcia: "Re: calling "su" after "chroot""
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Relevant Pages
|