mirror of
https://git.freebsd.org/ports.git
synced 2025-06-06 13:20:32 -04:00
New port: su2.
An enhanced su, allows user to su with own password, etc. Reviewed by: max Submitted by: John-Mark Gurney <gurney_j@efn.org>
This commit is contained in:
parent
a050ea337c
commit
cfc860b374
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=5037
7 changed files with 122 additions and 0 deletions
18
sysutils/su2/Makefile
Normal file
18
sysutils/su2/Makefile
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
# New ports collection makefile for: su2
|
||||||
|
# Version required: 1.3
|
||||||
|
# Date created: 12 Sep 1996
|
||||||
|
# Whom: gurney_j@efn.org
|
||||||
|
#
|
||||||
|
# $Id$
|
||||||
|
#
|
||||||
|
|
||||||
|
DISTNAME= su2-1.3
|
||||||
|
CATEGORIES= sysutils
|
||||||
|
MASTER_SITES= ftp://ftp.ccs.neu.edu/pub/sysadmin/
|
||||||
|
|
||||||
|
MAINTAINER= gurney_j@efn.org
|
||||||
|
|
||||||
|
NO_CDROM= "Don't sell for profit"
|
||||||
|
MAN1= su2.1
|
||||||
|
|
||||||
|
.include <bsd.port.mk>
|
1
sysutils/su2/distinfo
Normal file
1
sysutils/su2/distinfo
Normal file
|
@ -0,0 +1 @@
|
||||||
|
MD5 (su2-1.3.tar.gz) = 5cdecd54e0a7ecb0469e3881ed245518
|
41
sysutils/su2/files/patch-aa
Normal file
41
sysutils/su2/files/patch-aa
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
--- Makefile.orig Thu Dec 19 20:41:49 1996
|
||||||
|
+++ Makefile Thu Dec 19 20:47:14 1996
|
||||||
|
@@ -8,16 +8,17 @@
|
||||||
|
# /etc/super-users and /usr/adm/sulog that are defined
|
||||||
|
# separately.
|
||||||
|
#
|
||||||
|
-DEST=/usr/local
|
||||||
|
+PREFIX?=/usr/local
|
||||||
|
+DEST=${PREFIX}
|
||||||
|
BINDIR=$(DEST)/bin
|
||||||
|
-MANDIR=$(DEST)/man
|
||||||
|
+MANDIR=$(DEST)/man/man1
|
||||||
|
|
||||||
|
# OPTIONS:
|
||||||
|
# There are a number of DEFINES that can be used to configure su2. Please
|
||||||
|
# see the source to su2.c for a full listing of all of the available options.
|
||||||
|
|
||||||
|
# Standard
|
||||||
|
-OPTIONS=-DFULLPATH
|
||||||
|
+OPTIONS=-DSU2LOGFILE="\"/var/log/su2.log\"" -DBROKENCUSERID
|
||||||
|
|
||||||
|
# m88k
|
||||||
|
# OPTIONS=-DFULLPATH -DNOVFORK
|
||||||
|
@@ -31,12 +32,15 @@
|
||||||
|
# Shadow Passwords (Solaris)
|
||||||
|
# OPTIONS=-DFULLPATH -DUSE_SHADOW
|
||||||
|
|
||||||
|
-CFLAGS=-O $(OPTIONS)
|
||||||
|
+CFLAGS+= $(OPTIONS)
|
||||||
|
+LDLIBS=-lcrypt -lcompat
|
||||||
|
|
||||||
|
su2: su2.c
|
||||||
|
|
||||||
|
+all: su2
|
||||||
|
+
|
||||||
|
install: su2
|
||||||
|
- install -c -m 4711 -o root su2 $(BINDIR)/su2
|
||||||
|
+ install -c -s -m 4711 -o root su2 $(BINDIR)/su2
|
||||||
|
install -c su2.man $(MANDIR)/su2.1
|
||||||
|
|
||||||
|
clean:
|
38
sysutils/su2/files/patch-ab
Normal file
38
sysutils/su2/files/patch-ab
Normal file
|
@ -0,0 +1,38 @@
|
||||||
|
--- su2.c.orig Thu Dec 19 20:41:50 1996
|
||||||
|
+++ su2.c Thu Dec 19 20:41:50 1996
|
||||||
|
@@ -113,7 +113,7 @@
|
||||||
|
#ifndef NOSU2RC
|
||||||
|
char *UsersNameFile = ".su2rc";
|
||||||
|
#endif NOSU2RC
|
||||||
|
-char *SULog = "/usr/adm/sulog";
|
||||||
|
+char *SULog = SU2LOGFILE;
|
||||||
|
|
||||||
|
char *UtmpFile = "/etc/utmp";
|
||||||
|
|
||||||
|
@@ -182,13 +182,15 @@
|
||||||
|
|
||||||
|
char *malloc ();
|
||||||
|
|
||||||
|
+#if !(defined(BSD) && (BSD >= 199306))
|
||||||
|
#ifdef OSF
|
||||||
|
int setpwent ();
|
||||||
|
-#else
|
||||||
|
+#elseif !(defined(BSD) && (BSD >= 199306))
|
||||||
|
void setpwent ();
|
||||||
|
#endif
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
-#ifndef sgi
|
||||||
|
+#if !defined(sgi) && !(defined(BSD) && (BSD >= 199306))
|
||||||
|
struct passwd *getpwuid ();
|
||||||
|
struct passwd *getpwnam ();
|
||||||
|
void endpwent ();
|
||||||
|
@@ -570,7 +572,7 @@
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
-#ifndef sgi
|
||||||
|
+#if !(defined(sgi) && (defined(BSD) && (BSD >= 199306)))
|
||||||
|
setpwent ();
|
||||||
|
#endif
|
||||||
|
|
1
sysutils/su2/pkg-comment
Normal file
1
sysutils/su2/pkg-comment
Normal file
|
@ -0,0 +1 @@
|
||||||
|
an enhanced su, allows users to su with own password + more
|
21
sysutils/su2/pkg-descr
Normal file
21
sysutils/su2/pkg-descr
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
From the README:
|
||||||
|
|
||||||
|
su2 is a great program for anyone that has anything to do with
|
||||||
|
system adiministration. su2 gives you the ability to masquerade with
|
||||||
|
the UID of other users. You use own password to switch. Probably the
|
||||||
|
biggest benefit of su2 is that you retain your own customized shell
|
||||||
|
environment.
|
||||||
|
|
||||||
|
For the most part, this program is used by system administrators to
|
||||||
|
become root, but su2 has been written to enable much more flexibility
|
||||||
|
than this. Regular users can put a .su2rc file in their home
|
||||||
|
directory to enable other users to become them. While this may sound
|
||||||
|
odd, it is sometimes useful to allow a number of users to masquerade
|
||||||
|
around with the uid of restricted accounts. One such example of this
|
||||||
|
is a 'www' account which is a common occurance with the proliferation
|
||||||
|
of the web. While the www user's password may be starred out to
|
||||||
|
disable direct logins, root could put a set of usernames into
|
||||||
|
~www/.su2rc to enable these users to 'become' www and do Web
|
||||||
|
adiministration. [This feature can be disabled if you are worried
|
||||||
|
about 'account sharing.']
|
||||||
|
|
2
sysutils/su2/pkg-plist
Normal file
2
sysutils/su2/pkg-plist
Normal file
|
@ -0,0 +1,2 @@
|
||||||
|
bin/su2
|
||||||
|
man/man1/su2.1.gz
|
Loading…
Add table
Reference in a new issue