From 9b4110c5e555d41430fe37b1252470a8a81431f3 Mon Sep 17 00:00:00 2001 From: green Date: Tue, 12 Jun 2001 03:43:47 +0000 Subject: [PATCH] Enable Kerberos 5 support in sshd again. --- crypto/openssh/auth-krb5.c | 1 + crypto/openssh/auth.h | 1 + crypto/openssh/auth1.c | 4 ++-- secure/usr.sbin/sshd/Makefile | 2 -- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/crypto/openssh/auth-krb5.c b/crypto/openssh/auth-krb5.c index 0fb0ea21b9af..efe93765f07d 100644 --- a/crypto/openssh/auth-krb5.c +++ b/crypto/openssh/auth-krb5.c @@ -6,6 +6,7 @@ #include "includes.h" #include "ssh.h" +#include "ssh1.h" #include "packet.h" #include "xmalloc.h" diff --git a/crypto/openssh/auth.h b/crypto/openssh/auth.h index cd27684a7a7c..5996480824f6 100644 --- a/crypto/openssh/auth.h +++ b/crypto/openssh/auth.h @@ -99,6 +99,7 @@ int auth_rsa_challenge_dialog(RSA *pk); #ifdef KRB5 #include +#include int auth_krb5(); /* XXX Doplnit prototypy */ int auth_krb5_tgt(); int krb5_init(); diff --git a/crypto/openssh/auth1.c b/crypto/openssh/auth1.c index 0e494eb3de4d..d5d15ef09ed6 100644 --- a/crypto/openssh/auth1.c +++ b/crypto/openssh/auth1.c @@ -416,8 +416,8 @@ do_authloop(Authctxt *authctxt) tgt.data = packet_get_string(&tgtlen); tgt.length = tgtlen; - if (!auth_krb5_tgt(luser, &tgt, tkt_client)) - verbose ("Kerberos V5 TGT refused for %.100s", luser); + if (!auth_krb5_tgt(pw->pw_name, &tgt, tkt_client)) + verbose ("Kerberos V5 TGT refused for %.100s", pw->pw_name); xfree(tgt.data); break; diff --git a/secure/usr.sbin/sshd/Makefile b/secure/usr.sbin/sshd/Makefile index ba03d23f6178..4c61997ba216 100644 --- a/secure/usr.sbin/sshd/Makefile +++ b/secure/usr.sbin/sshd/Makefile @@ -21,7 +21,6 @@ LDADD+= -lkrb -lcom_err DPADD+= ${LIBKRB} ${LIBCOM_ERR} .endif # MAKE_KERBEROS4 -.if 0 .if defined(MAKE_KERBEROS5) && \ ((${MAKE_KERBEROS5} == "yes") || (${MAKE_KERBEROS5} == "YES")) DISTRIBUTION=krb5 @@ -30,7 +29,6 @@ SRCS+= auth-krb5.c LDADD+= -lkrb5 -lasn1 -lcom_err -lmd -L${.OBJDIR}/../../../kerberos5/lib/libroken -lroken DPADD+= ${LIBKRB5} ${LIBCOM_ERR} ${LIBASN1} ${LIBMD} .endif # MAKE_KERBEROS5 -.endif # 0 CFLAGS+= -DSKEY LDADD+= -lopie -lmd