(1) edit src/lib/krb5/os/kuserok.c, applying this patch: *** kuserok.c.orig Fri May 5 12:06:49 2000 --- kuserok.c Thu May 11 01:28:29 2000 *************** *** 83,105 **** if ((pwd = getpwnam(luser)) == NULL) { return(FALSE); } ! (void) strncpy(pbuf, pwd->pw_dir, sizeof(pbuf) - 1); pbuf[sizeof(pbuf) - 1] = '\0'; (void) strncat(pbuf, "/.k5login", sizeof(pbuf) - 1 - strlen(pbuf)); - if (access(pbuf, F_OK)) { /* not accessible */ - /* - * if he's trying to log in as himself, and there is no .k5login file, - * let him. To find out, call - * krb5_aname_to_localname to convert the principal to a name - * which we can string compare. - */ - if (!(krb5_aname_to_localname(context, principal, - sizeof(kuser), kuser)) - && (strcmp(kuser, luser) == 0)) { - return(TRUE); - } - } if (krb5_unparse_name(context, principal, &princname)) return(FALSE); /* no hope of matching */ --- 83,94 ---- if ((pwd = getpwnam(luser)) == NULL) { return(FALSE); } ! (void) strncpy(pbuf, "/var/userauth/", sizeof(pbuf) - 1); ! pbuf[sizeof(pbuf) - 1] = '\0'; ! (void) strncat(pbuf, luser, sizeof(pbuf) - 1 - strlen(pbuf)); pbuf[sizeof(pbuf) - 1] = '\0'; (void) strncat(pbuf, "/.k5login", sizeof(pbuf) - 1 - strlen(pbuf)); if (krb5_unparse_name(context, principal, &princname)) return(FALSE); /* no hope of matching */ *************** *** 115,121 **** return(FALSE); sprintf(princname, "%s%s%s@%s", v4_name, *v4_inst ? "." : "", v4_inst, v4_realm); ! sprintf(pbuf, "%s/.klogin", pwd->pw_dir); fp = fopen(pbuf, "r"); } } --- 104,111 ---- return(FALSE); sprintf(princname, "%s%s%s@%s", v4_name, *v4_inst ? "." : "", v4_inst, v4_realm); ! snprintf(pbuf, sizeof(pbuf), "/var/userauth/%s/.klogin", ! luser); fp = fopen(pbuf, "r"); } } (2) compile kuserok.c using /usr/gcc/bin/gcc -I../../../include -I../../../include/krb5 -DKRB5_KRB4_COMPAT -c kuserok.c (3) cd to src/lib/krb5, and type make libkrb5.a (4) cd to src/appl/bsd and type make kshd make klogind (you may need to change the Makefile to use /usr/afsws/lib rather than /.srvd/usr/afsws/lib) (5) cd to src/appl/telnet/telnetd and type make (you may need to change the Makefile to use /usr/afsws/lib rather than /.srvd/usr/afsws/lib)