summaryrefslogtreecommitdiffstats
path: root/usr.bin/rsh
diff options
context:
space:
mode:
authormarkm <markm@FreeBSD.org>1998-10-09 06:47:57 +0000
committermarkm <markm@FreeBSD.org>1998-10-09 06:47:57 +0000
commit7536318c13652f54be77a72423e75e8318a4c866 (patch)
tree2945f595f318fcec6598fb48acffc94db8872181 /usr.bin/rsh
parenta486b8dd50ee11dd8e42be9103b74c714abcf631 (diff)
downloadFreeBSD-src-7536318c13652f54be77a72423e75e8318a4c866.zip
FreeBSD-src-7536318c13652f54be77a72423e75e8318a4c866.tar.gz
Use KJH's auth.conf parser to turn on/off Kerberos in userland.
Diffstat (limited to 'usr.bin/rsh')
-rw-r--r--usr.bin/rsh/Makefile6
-rw-r--r--usr.bin/rsh/rsh.11
-rw-r--r--usr.bin/rsh/rsh.c9
3 files changed, 12 insertions, 4 deletions
diff --git a/usr.bin/rsh/Makefile b/usr.bin/rsh/Makefile
index 264374c..5d545f9 100644
--- a/usr.bin/rsh/Makefile
+++ b/usr.bin/rsh/Makefile
@@ -1,5 +1,5 @@
# @(#)Makefile 8.1 (Berkeley) 7/19/93
-# $Id: Makefile,v 1.7 1998/09/05 00:32:27 jb Exp $
+# $Id: Makefile,v 1.8 1998/09/19 22:42:05 obrien Exp $
PROG= rsh
SRCS= rsh.c
@@ -13,8 +13,8 @@ CFLAGS+=-DKERBEROS -DCRYPT -DHAVE_CONFIG_H \
-I${.CURDIR}/../../crypto/kerberosIV/include \
-I${.CURDIR}/../../crypto/kerberosIV/lib/roken \
-I${.CURDIR}/../../crypto/kerberosIV/appl/bsd
-DPADD= ${LIBKRB} ${LIBDES} ${LIBCRYPT}
-LDADD= -lkrb -ldes -lcrypt
+DPADD= ${LIBUTIL} ${LIBKRB} ${LIBDES} ${LIBCRYPT}
+LDADD= -lutil -lkrb -ldes -lcrypt
DISTRIBUTION= krb
.PATH: ${.CURDIR}/../../crypto/kerberosIV/appl/bsd
.endif
diff --git a/usr.bin/rsh/rsh.1 b/usr.bin/rsh/rsh.1
index ee3ca46..2db4817 100644
--- a/usr.bin/rsh/rsh.1
+++ b/usr.bin/rsh/rsh.1
@@ -132,6 +132,7 @@ to
.Sh FILES
.Bl -tag -width /etc/hosts -compact
.It Pa /etc/hosts
+.It Pa /etc/auth.conf
.El
.Sh SEE ALSO
.Xr rlogin 1 ,
diff --git a/usr.bin/rsh/rsh.c b/usr.bin/rsh/rsh.c
index 2539b2f..7d8385e 100644
--- a/usr.bin/rsh/rsh.c
+++ b/usr.bin/rsh/rsh.c
@@ -42,7 +42,7 @@ static const char copyright[] =
static char sccsid[] = "From: @(#)rsh.c 8.3 (Berkeley) 4/6/94";
#endif
static const char rcsid[] =
- "$Id: rsh.c,v 1.14 1998/02/20 04:50:50 jb Exp $";
+ "$Id: rsh.c,v 1.15 1998/03/23 07:46:23 charnier Exp $";
#endif /* not lint */
#include <sys/types.h>
@@ -57,6 +57,7 @@ static const char rcsid[] =
#include <err.h>
#include <errno.h>
+#include <libutil.h>
#include <pwd.h>
#include <signal.h>
#include <stdio.h>
@@ -102,6 +103,9 @@ main(argc, argv)
uid_t uid;
char *args, *host, *p, *user;
int timeout = 0;
+#ifdef KERBEROS
+ char *k;
+#endif
argoff = asrsh = dflag = nflag = 0;
one = 1;
@@ -207,6 +211,9 @@ main(argc, argv)
sp = NULL;
#ifdef KERBEROS
+ k = auth_getval("auth_list");
+ if (k && !strstr(k, "kerberos"))
+ use_kerberos = 0;
if (use_kerberos) {
sp = getservbyname((doencrypt ? "ekshell" : "kshell"), "tcp");
if (sp == NULL) {
OpenPOWER on IntegriCloud