[2740] in linux-net channel archive
Re: Show Sl0 IP to normal user
daemon@ATHENA.MIT.EDU (Tigran Aivazian)
Tue Apr 30 12:26:45 1996
Date: Mon, 29 Apr 1996 22:26:42 +0000 (GMT)
From: Tigran Aivazian <tigran@zetnet.co.uk>
To: Nicolas Sayer <Nicolas.Sayer@inria.fr>
cc: Bas Rijniersce <basrijn@hacom.nl>, linux-net@vger.rutgers.edu
In-Reply-To: <199604170731.JAA02201@nsp.inria.fr>
On Wed, 17 Apr 1996, Nicolas Sayer wrote:
> >Is there a program that shows the current (dynamicly assigned) IP for the
> >slip inerface to a normal user. I want to write a script that will be
> >executed by a normal user (my father, I don't want him to log-in as root
> >:))) that will send an E-mail message to me with the current IP adres. This
> >script will be executed after dip has made a Cslip connection to the Net (I
> >will be in Engeland, my parents will be in Holland, and I want to have a
> >telnet chat with them :-)).
> >Both ifconfig and route are root-only :(
> >Do you have any suggestions?
>
> I sugest you use a script with a setuid to root. so that your father can run
> it, but it will be ran is if the root started it. You can even automaticly
> send a mail with your ip with this script. You'll be able to get the ip from
> the output of ifconfig...
> please keep in touch if you need more infos...
>
Hi,
First of all, have you tried creating setuid script? You cant. Not on UNIX,
at least.
Second, you dont need root to run ifconfig.
Regards.
Tigran.