From 985171769d01bfa8cd583e75c08d13949ac201fc Mon Sep 17 00:00:00 2001 From: Tracy Di Marco White Date: Mon, 30 May 2005 04:35:52 +0000 Subject: [PATCH] netbsd-pam-20050529 FIXES 18924 pam support for nbsd --- src/pam/Makefile.in | 6 +++--- src/pam/afs_auth.c | 2 +- src/pam/afs_password.c | 2 +- src/pam/afs_setcred.c | 2 +- src/pam/test_pam.c | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/pam/Makefile.in b/src/pam/Makefile.in index 05cd27cdf..4d5b0fd0a 100644 --- a/src/pam/Makefile.in +++ b/src/pam/Makefile.in @@ -61,7 +61,7 @@ pam_afs.so.1: $(SHOBJS) afs_setcred.o afs_auth.o afs_util.o *linux*) \ $(CC) $(LDFLAGS) -o $@ afs_setcred.o \ afs_auth.o afs_util.o $(SHOBJS) $(LIBS) ;;\ - *fbsd*) \ + *fbsd*| *nbsd*) \ $(CC) $(LDFLAGS) -o $@ afs_setcred.o \ afs_auth.o afs_util.o $(SHOBJS) $(LIBS) ;;\ * ) \ @@ -82,7 +82,7 @@ pam_afs.krb.so.1: $(SHOBJS) afs_setcred_krb.o afs_auth_krb.o afs_util_krb.o *linux*) \ $(CC) $(LDFLAGS) -o $@ afs_setcred_krb.o \ afs_auth_krb.o afs_util_krb.o $(SHOBJS) $(KLIBS) ;;\ - *fbsd*) \ + *fbsd*| *nbsd*) \ $(CC) $(LDFLAGS) -o $@ afs_setcred_krb.o \ afs_auth_krb.o afs_util_krb.o $(SHOBJS) $(KLIBS) ;;\ * ) \ @@ -98,7 +98,7 @@ test_pam: test_pam.o $(CC) $(CFLAGS) -o $@ test_pam.o ${PAM_LIBS};; \ *linux*) \ $(CC) $(CFLAGS) -rdynamic -o $@ test_pam.o -lpam -ldl;; \ - *fbsd*) \ + *fbsd*| *nbsd*) \ $(CC) $(CFLAGS) -rdynamic -o $@ test_pam.o -lpam ;; \ *) \ echo No link line for system $(SYS_NAME). ;; \ diff --git a/src/pam/afs_auth.c b/src/pam/afs_auth.c index 7fb77a3e5..0a0325867 100644 --- a/src/pam/afs_auth.c +++ b/src/pam/afs_auth.c @@ -190,7 +190,7 @@ pam_sm_authenticate(pam_handle_t * pamh, int flags, int argc, RET(PAM_AUTH_ERR); } #else -#if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) +#if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) || defined(AFS_NBSD_ENV) upwd = getpwnam(user); #else upwd = getpwnam_r(user, &unix_pwd, upwd_buf, sizeof(upwd_buf)); diff --git a/src/pam/afs_password.c b/src/pam/afs_password.c index 014b7566c..9fcfaa87b 100644 --- a/src/pam/afs_password.c +++ b/src/pam/afs_password.c @@ -134,7 +134,7 @@ pam_sm_chauthtok(pam_handle_t * pamh, int flags, int argc, const char **argv) RET(PAM_AUTH_ERR); } #else -#if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) +#if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) || defined(AFS_NBSD_ENV) upwd = getpwnam(user); #else upwd = getpwnam_r(user, &unix_pwd, upwd_buf, sizeof(upwd_buf)); diff --git a/src/pam/afs_setcred.c b/src/pam/afs_setcred.c index 5262f1c78..e6713f3f0 100644 --- a/src/pam/afs_setcred.c +++ b/src/pam/afs_setcred.c @@ -170,7 +170,7 @@ pam_sm_setcred(pam_handle_t * pamh, int flags, int argc, const char **argv) RET(PAM_AUTH_ERR); } #else -#if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) +#if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) || defined(AFS_NBSD_ENV) upwd = getpwnam(user); #else upwd = getpwnam_r(user, &unix_pwd, upwd_buf, sizeof(upwd_buf)); diff --git a/src/pam/test_pam.c b/src/pam/test_pam.c index 44406a057..39d35cb90 100644 --- a/src/pam/test_pam.c +++ b/src/pam/test_pam.c @@ -34,7 +34,7 @@ static const char *service = "afstest"; static const char *new_envstring = "GOTHEREVIATESTPAM=1"; static const char *new_homestring = "HOME=/tmp"; -#if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) +#if defined(AFS_LINUX20_ENV) || defined(AFS_FBSD_ENV) || defined(AFS_NBSD_ENV) #define getpassphrase getpass #endif -- 2.39.5