Re: chroot and setuid binaries
Re: chroot and setuid binaries
- Subject: Re: chroot and setuid binaries
- From: Jay Buffington <email@hidden>
- Date: Tue, 08 Mar 2011 21:06:14 -0800
On Wed, Feb 23, 2011 at 10:03 AM, Axel Luttgens <email@hidden> wrote:
> Moreover, isn't the volume mounted nosuid by default?
This was exactly my problem. Thanks, Axel. The mount command showed
this in it's output:
/dev/disk1s2 on /Volumes/untitled (hfs, local, nodev, nosuid, mounted
by jaybuff)
I was able to mount it without the nosuid option and everything worked:
$ hdiutil attach -owners on -nomount ~/images/mac_os_x-10.5.7.sparseimage
$ sudo mkdir /Volumes/mac_os_x-10.5.7
$ sudo mount -t hfs -o nodev /dev/disk2s2 /Volumes/mac_os_x-10.5.7
$ sudo /sbin/mount -t devfs devfs /Volumes/mac_os_x-10.5.7/dev
$ sudo /sbin/mount -t fdesc -o union stdin /Volumes/mac_os_x-10.5.7/dev/
$ sudo bindfs /Users/jaybuff /Volumes/mac_os_x-10.5.7/Users/jaybuff
$ sudo chroot /Volumes/mac_os_x-10.5.7/ bash
bash-3.2# su - jaybuff
$ ./euid
euid: 0
Thanks!
Jay
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden