Import of pkgsrc-2013Q2

This commit is contained in:
2013-09-26 17:14:40 +02:00
commit 785076ae39
74991 changed files with 4380255 additions and 0 deletions

18
sysutils/su2/DESCR Normal file
View File

@@ -0,0 +1,18 @@
su2 is a great program for anyone that has anything to do with
system administration. 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 user names into
~www/.su2rc to enable these users to 'become' www and do Web
administration. [This feature can be disabled if you are worried
about 'account sharing.']

43
sysutils/su2/Makefile Normal file
View File

@@ -0,0 +1,43 @@
# $NetBSD: Makefile,v 1.16 2013/04/06 21:07:35 rodent Exp $
#
DISTNAME= su2-1.3
CATEGORIES= sysutils security
MASTER_SITES= ftp://ftp.ccs.neu.edu/pub/sysadmin/
MAINTAINER= pkgsrc-users@NetBSD.org
HOMEPAGE= ftp://ftp.ccs.neu.edu/pub/sysadmin/
COMMENT= Enhanced su, users su with own password + more
LICENSE= su2-license
SPECIAL_PERMS+= bin/su2 ${SETUID_ROOT_PERMS}
RESTRICTED= may not be sold for profit
NO_SRC_ON_CDROM= ${RESTRICTED}
NO_BIN_ON_CDROM= ${RESTRICTED}
NO_CONFIGURE= yes
SUBST_CLASSES+= preproc
SUBST_MESSAGE.preproc= Correcting C preprocessor directives.
SUBST_STAGE.preproc= post-patch
SUBST_FILES.preproc= su2.c
SUBST_SED.preproc= -e 's,^\(\# *else\).*,\1,'
SUBST_SED.preproc= -e 's,^\(\# *endif\).*,\1,'
LDLIBS= -lcrypt
.include "../../mk/bsd.prefs.mk"
.if ${OPSYS} == "NetBSD"
LDLIBS+= -lcompat
.endif
MAKE_ENV+= LDLIBS=${LDLIBS:Q}
INSTALLATION_DIRS+= bin ${PKGMANDIR}/man1
post-extract:
${CHMOD} -R og+w ${WRKSRC}
.include "../../mk/bsd.pkg.mk"

3
sysutils/su2/PLIST Normal file
View File

@@ -0,0 +1,3 @@
@comment $NetBSD: PLIST,v 1.1.1.1 2002/06/04 09:56:38 cjep Exp $
bin/su2
man/man1/su2.1

8
sysutils/su2/distinfo Normal file
View File

@@ -0,0 +1,8 @@
$NetBSD: distinfo,v 1.5 2010/01/27 20:15:39 joerg Exp $
SHA1 (su2-1.3.tar.gz) = 0b84a070c0cc95098c0d61566663c89ec2d1189e
RMD160 (su2-1.3.tar.gz) = 2f5424b6af87508b98f19b9ecdfe12a7cf624c58
Size (su2-1.3.tar.gz) = 31067 bytes
SHA1 (patch-aa) = 4f8916be4c25a1ac0abd7a561362d85dcf778fac
SHA1 (patch-ab) = 6a59bf878c2c416d677c4d705f7536ab2350ea94
SHA1 (patch-ac) = 5f0799f9ed62b656fad7bbde776393700e2407c6

View File

@@ -0,0 +1,47 @@
$NetBSD: patch-aa,v 1.3 2010/01/27 20:15:39 joerg Exp $
--- Makefile.orig 2004-04-16 20:59:06.000000000 -0700
+++ Makefile
@@ -8,16 +8,16 @@ CC=gcc
# /etc/super-users and /usr/adm/sulog that are defined
# separately.
#
-DEST=/usr/local
+DEST=${PREFIX}
BINDIR=$(DEST)/bin
-MANDIR=$(DEST)/man
+MANDIR=$(DEST)/${PKGMANDIR}/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\"" -DSUPERUSERS="\"$(PREFIX)/etc/super-users\"" -DBROKENCUSERID
# m88k
# OPTIONS=-DFULLPATH -DNOVFORK
@@ -31,13 +31,18 @@ OPTIONS=-DFULLPATH
# Shadow Passwords (Solaris)
# OPTIONS=-DFULLPATH -DUSE_SHADOW
-CFLAGS=-O $(OPTIONS)
+CFLAGS+= $(OPTIONS)
su2: su2.c
-install: su2
- install -c -m 4711 -o root su2 $(BINDIR)/su2
- install -c su2.man $(MANDIR)/su2.1
+su2.1:
+ sed 's,/etc/super,${PREFIX}/etc/super,g' <su2.man >su2.1
+
+all: su2 su2.1
+
+install: su2 su2.1
+ ${BSD_INSTALL_PROGRAM} su2 ${DESTDIR}$(BINDIR)/su2
+ ${BSD_INSTALL_MAN} su2.1 ${DESTDIR}$(MANDIR)/su2.1
clean:
rm -f su2 *.o *.a

View File

@@ -0,0 +1,30 @@
$NetBSD: patch-ab,v 1.2 2006/03/14 02:53:13 joerg Exp $
--- su2.c.orig 1995-09-07 20:10:11.000000000 +0000
+++ su2.c
@@ -113,9 +113,9 @@ char *SystemNameFile = SUPERUSERS;
#ifndef NOSU2RC
char *UsersNameFile = ".su2rc";
#endif NOSU2RC
-char *SULog = "/usr/adm/sulog";
+char *SULog = SU2LOGFILE;
-char *UtmpFile = "/etc/utmp";
+char *UtmpFile = "/var/run/utmp";
#ifndef PATH
# ifdef BSD
@@ -188,13 +188,6 @@ int setpwent ();
void setpwent ();
#endif
-#ifndef sgi
-struct passwd *getpwuid ();
-struct passwd *getpwnam ();
-void endpwent ();
-int chmod ();
-#endif
-
struct passwd *pw;
char *ttyname ();

View File

@@ -0,0 +1,55 @@
$NetBSD: patch-ac,v 1.1.1.1 2002/06/04 09:56:38 cjep Exp $
--- su2.man.orig Tue Oct 2 22:09:48 2001
+++ su2.man
@@ -84,7 +84,7 @@
.I Su2\^
logs all attempts to
.I su2\^
-in /usr/adm/sulog, including failures. Successful attempts are flagged
+in /var/log/sulog, including failures. Successful attempts are flagged
with "+", failures with "-".
.LP
The file
@@ -110,7 +110,7 @@
.B \-u
is used to specify a user against whom to check authorization and password.
The default value is obtained from
-.I /etc/utmp.
+.I /var/run/utmp.
.TP
.B \-x
when specified will cause
@@ -118,7 +118,7 @@
to exec the shell without first forking a new process. This option should
only be used when the system is out of process slots. When it is used
su2 will neither clean up the
-.I /etc/utmp
+.I /var/run/utmp
entry nor reset the ownership and mode of the current
.IR /dev/tty?? .
Both may be reset with the
@@ -127,12 +127,12 @@
.TP
.B \-s
will change the current
-.I /etc/utmp
+.I /var/run/utmp
entry to reflect the new user name.
.TP
.B \-r
is used to replace the username in
-.I /etc/utmp
+.I /var/run/utmp
and the mode and ownership of
.I /dev/tty??
with that associated with the current process userid.
@@ -178,7 +178,7 @@
$HOME/.su2rc
list of users authorized to change to a specific user.
.TP
-/usr/adm/sulog
+/var/log/su2.log
log of
.I su2
and