Subject: Re: non-root user executes root shell?
To: None <>
From: Joel Rees <>
List: netbsd-users
Date: 10/03/2004 15:48:39
On 2004.10.3, at 03:33 PM, Water NB wrote:

> I have a shell-script which be used to mount and umount ISO file to a
> directory. And I want a non-root user can execute it. How can I?
> For example:
> #! /bin/sh
> vnconfig -c vnd0 /xxx.iso
> mount cd9660 /dev/vnd0c /mnt

I'm in the sudo camp on that, myself, but someone here said recently 
they write a user runnable mount program in C to do that. But if you 
are interested in sudo:

     man sudo
     man sudoers

If you are interested in writing a program in C, you should be able to 
find the guy who preferred that approach in the archives. I'm pretty 
sure it was in September, but might have been August. He might be able 
to help you.