Date: Sun, 07 Sep 1997 16:06:32 +0100 From: Brian Somers <brian@awfulhak.org> To: Snob Art Genre <benedict@echonyc.com> Cc: Brian Somers <brian@awfulhak.org>, freebsd-stable@FreeBSD.ORG Subject: Re: Don Croyle: make world failing at ppp install (again) Message-ID: <199709071506.QAA23147@awfulhak.demon.co.uk> In-Reply-To: Your message of "Sun, 07 Sep 1997 10:48:43 EDT." <Pine.GSO.3.96.970907104511.25918A-100000@echonyc.com>
next in thread | previous in thread | raw e-mail | index | archive | help
This is a multipart MIME message. --==_Exmh_-7650644120 Content-Type: text/plain; charset=us-ascii > How about a compile-time option with BIG WARNING FLAGS so that ppp can be > run in client mode by non-superusers? > > Here's my situation: I don't run ppp in server mode, so the only member of > group network is my own account. And my machine isn't networked at the > moment (and when it is I could change the compilation option back). Same scenario as me, but ppp isn't the only thing that annoys me in this way. I circumvent all this with a small ``root'' program. It's like sudo without a password that checks for a given user id. When you don't have permission to do something, just prefix the whole thing with ``root''. > Ben > > "You have your mind on computers, it seems." > -- Brian <brian@awfulhak.org>, <brian@freebsd.org> <http://www.awfulhak.org> Don't _EVER_ lose your sense of humour.... --==_Exmh_-7650644120 Content-Type: application/octet-stream ; name="Makefile" Content-Description: Makefile Content-Disposition: attachment; filename="Makefile" # # Written by brian@awfulhak.org. This software's free. # # $Id: Makefile,v 1.4 1997/06/17 14:19:01 brian Exp $ # all: root GOD=brian root: Makefile cc -O -DGOD=\"$(GOD)\" -o root root.c chown root root chmod 4555 root --==_Exmh_-7650644120 Content-Type: application/octet-stream; name="root.c" Content-Description: root.c Content-Disposition: attachment; filename="root.c" /* * Written by brian@awfulhak.org. This software's free. * * $Id: root.c,v 1.3 1997/06/17 00:48:54 brian Exp $ */ #include <stdlib.h> #include <unistd.h> #include <stdio.h> int main(int argc, char **argv) { if (strcmp(getlogin(), GOD )) { fprintf(stderr, "Go away - you're not allowed to be God !\n"); return 1; } if (setuid(0)) { fprintf(stderr, "Can't become God :(\n"); return 2; } if (argc < 2) { char *sh; sh = getenv("SHELL"); if (!sh) sh = "/bin/sh"; execlp(sh, sh, NULL); } else execvp(argv[1], argv+1); perror("exec failed"); return 3; } --==_Exmh_-7650644120--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199709071506.QAA23147>