From fe7b8b5c8e7bc379e1ffd1d2f1d5decd93770ef5 Mon Sep 17 00:00:00 2001 From: Nate Willams Date: Tue, 20 Jul 1993 22:27:57 +0000 Subject: [PATCH] Libcrypt changes --- usr.bin/su/Makefile | 16 +++++++--------- usr.bin/su/su.c | 4 ---- 2 files changed, 7 insertions(+), 13 deletions(-) diff --git a/usr.bin/su/Makefile b/usr.bin/su/Makefile index 7978916403..278f8ab532 100644 --- a/usr.bin/su/Makefile +++ b/usr.bin/su/Makefile @@ -1,16 +1,14 @@ # @(#)Makefile 5.5 (Berkeley) 5/11/90 -# -# PATCHES MAGIC LEVEL PATCH THAT GOT US HERE -# -------------------- ----- ---------------------- -# CURRENT PATCH LEVEL: 1 50000 -# -------------------- ----- ---------------------- -# -# 10 Oct 92 Rodney W. Grimes Install a real crypt for passwords -# -CFLAGS+=-DDES PROG= su +CFLAGS+=-DDES BINOWN= root BINMODE=4555 +.if exists(/usr/lib/libcrypt.a) +#CFLAGS+=-DKERBEROS +DPADD+= ${LIBCRYPT} +LDADD+= -lcrypt +.endif + .include diff --git a/usr.bin/su/su.c b/usr.bin/su/su.c index 8a8edc802a..e024d818ec 100644 --- a/usr.bin/su/su.c +++ b/usr.bin/su/su.c @@ -163,11 +163,7 @@ main(argc, argv) /* if target requires a password, verify it */ if (*pwd->pw_passwd) { p = getpass("Password:"); -#ifdef DES if (strcmp(pwd->pw_passwd, crypt(p, pwd->pw_passwd))) { -#else - if (strcmp(pwd->pw_passwd, p)) { -#endif fprintf(stderr, "Sorry\n"); syslog(LOG_AUTH|LOG_WARNING, "BAD SU %s to %s%s", username, -- 2.20.1