From 1ae23164b085307a22a0eeeda34e03204ae89293 Mon Sep 17 00:00:00 2001 From: christos Date: Sun, 25 Dec 2011 22:27:55 +0000 Subject: [PATCH] apply our changes. --- .../bsd/openpam/dist/bin/pamtest/pamtest.1 | 2 +- .../bsd/openpam/dist/bin/pamtest/pamtest.c | 2 +- external/bsd/openpam/dist/bin/su/su.1 | 2 +- external/bsd/openpam/dist/bin/su/su.c | 2 +- external/bsd/openpam/dist/doc/man/openpam.3 | 4 +- .../dist/doc/man/openpam_borrow_cred.3 | 5 +- .../openpam/dist/doc/man/openpam_free_data.3 | 4 +- .../dist/doc/man/openpam_free_envlist.3 | 4 +- .../openpam/dist/doc/man/openpam_get_option.3 | 5 +- .../bsd/openpam/dist/doc/man/openpam_log.3 | 4 +- .../openpam/dist/doc/man/openpam_nullconv.3 | 8 +- .../openpam/dist/doc/man/openpam_readline.3 | 4 +- .../dist/doc/man/openpam_restore_cred.3 | 5 +- .../openpam/dist/doc/man/openpam_set_option.3 | 5 +- .../bsd/openpam/dist/doc/man/openpam_subst.3 | 4 +- .../openpam/dist/doc/man/openpam_ttyconv.3 | 13 ++- external/bsd/openpam/dist/doc/man/pam.3 | 4 +- external/bsd/openpam/dist/doc/man/pam.conf.5 | 2 +- .../bsd/openpam/dist/doc/man/pam_acct_mgmt.3 | 4 +- .../openpam/dist/doc/man/pam_authenticate.3 | 4 +- .../bsd/openpam/dist/doc/man/pam_chauthtok.3 | 4 +- .../openpam/dist/doc/man/pam_close_session.3 | 4 +- external/bsd/openpam/dist/doc/man/pam_conv.3 | 7 +- external/bsd/openpam/dist/doc/man/pam_end.3 | 4 +- external/bsd/openpam/dist/doc/man/pam_error.3 | 5 +- .../openpam/dist/doc/man/pam_get_authtok.3 | 5 +- .../bsd/openpam/dist/doc/man/pam_get_data.3 | 4 +- .../bsd/openpam/dist/doc/man/pam_get_item.3 | 13 ++- .../bsd/openpam/dist/doc/man/pam_get_user.3 | 5 +- .../bsd/openpam/dist/doc/man/pam_getenv.3 | 5 +- .../bsd/openpam/dist/doc/man/pam_getenvlist.3 | 4 +- external/bsd/openpam/dist/doc/man/pam_info.3 | 5 +- .../openpam/dist/doc/man/pam_open_session.3 | 4 +- .../bsd/openpam/dist/doc/man/pam_prompt.3 | 5 +- .../bsd/openpam/dist/doc/man/pam_putenv.3 | 5 +- .../bsd/openpam/dist/doc/man/pam_set_data.3 | 5 +- .../bsd/openpam/dist/doc/man/pam_set_item.3 | 4 +- .../bsd/openpam/dist/doc/man/pam_setcred.3 | 4 +- .../bsd/openpam/dist/doc/man/pam_setenv.3 | 5 +- .../openpam/dist/doc/man/pam_sm_acct_mgmt.3 | 4 +- .../dist/doc/man/pam_sm_authenticate.3 | 4 +- .../openpam/dist/doc/man/pam_sm_chauthtok.3 | 4 +- .../dist/doc/man/pam_sm_close_session.3 | 4 +- .../dist/doc/man/pam_sm_open_session.3 | 4 +- .../bsd/openpam/dist/doc/man/pam_sm_setcred.3 | 4 +- external/bsd/openpam/dist/doc/man/pam_start.3 | 5 +- .../bsd/openpam/dist/doc/man/pam_strerror.3 | 8 +- .../bsd/openpam/dist/doc/man/pam_verror.3 | 5 +- external/bsd/openpam/dist/doc/man/pam_vinfo.3 | 5 +- .../bsd/openpam/dist/doc/man/pam_vprompt.3 | 5 +- .../openpam/dist/include/security/openpam.h | 15 +++- .../dist/include/security/openpam_attr.h | 2 +- .../dist/include/security/openpam_version.h | 2 +- .../openpam/dist/include/security/pam_appl.h | 2 +- .../dist/include/security/pam_constants.h | 4 +- .../dist/include/security/pam_modules.h | 2 +- .../openpam/dist/include/security/pam_types.h | 2 +- .../openpam/dist/lib/openpam_borrow_cred.c | 5 +- .../dist/lib/openpam_check_owner_perms.c | 2 +- .../bsd/openpam/dist/lib/openpam_configure.c | 34 +++++++- .../bsd/openpam/dist/lib/openpam_constants.c | 4 +- .../bsd/openpam/dist/lib/openpam_constants.h | 2 +- external/bsd/openpam/dist/lib/openpam_debug.h | 16 ++-- .../bsd/openpam/dist/lib/openpam_dispatch.c | 35 ++++++-- .../bsd/openpam/dist/lib/openpam_dynamic.c | 6 +- .../bsd/openpam/dist/lib/openpam_findenv.c | 3 +- .../bsd/openpam/dist/lib/openpam_free_data.c | 4 +- .../openpam/dist/lib/openpam_free_envlist.c | 2 +- .../bsd/openpam/dist/lib/openpam_get_option.c | 3 +- external/bsd/openpam/dist/lib/openpam_impl.h | 4 +- external/bsd/openpam/dist/lib/openpam_load.c | 2 +- external/bsd/openpam/dist/lib/openpam_log.c | 2 +- .../bsd/openpam/dist/lib/openpam_nullconv.c | 7 +- .../bsd/openpam/dist/lib/openpam_readline.c | 8 +- .../openpam/dist/lib/openpam_restore_cred.c | 3 +- .../bsd/openpam/dist/lib/openpam_set_option.c | 3 +- .../bsd/openpam/dist/lib/openpam_static.c | 6 +- .../bsd/openpam/dist/lib/openpam_strlcmp.h | 2 +- .../bsd/openpam/dist/lib/openpam_strlcpy.h | 2 +- external/bsd/openpam/dist/lib/openpam_subst.c | 8 +- .../bsd/openpam/dist/lib/openpam_ttyconv.c | 83 +++++++++++++------ external/bsd/openpam/dist/lib/pam_acct_mgmt.c | 3 +- .../bsd/openpam/dist/lib/pam_authenticate.c | 3 +- .../dist/lib/pam_authenticate_secondary.c | 2 +- external/bsd/openpam/dist/lib/pam_chauthtok.c | 3 +- .../bsd/openpam/dist/lib/pam_close_session.c | 3 +- external/bsd/openpam/dist/lib/pam_end.c | 3 +- external/bsd/openpam/dist/lib/pam_error.c | 2 +- .../bsd/openpam/dist/lib/pam_get_authtok.c | 10 ++- external/bsd/openpam/dist/lib/pam_get_data.c | 3 +- external/bsd/openpam/dist/lib/pam_get_item.c | 10 ++- .../openpam/dist/lib/pam_get_mapped_authtok.c | 2 +- .../dist/lib/pam_get_mapped_username.c | 2 +- external/bsd/openpam/dist/lib/pam_get_user.c | 3 +- external/bsd/openpam/dist/lib/pam_getenv.c | 3 +- .../bsd/openpam/dist/lib/pam_getenvlist.c | 3 +- external/bsd/openpam/dist/lib/pam_info.c | 2 +- .../bsd/openpam/dist/lib/pam_open_session.c | 3 +- external/bsd/openpam/dist/lib/pam_prompt.c | 2 +- external/bsd/openpam/dist/lib/pam_putenv.c | 6 +- external/bsd/openpam/dist/lib/pam_set_data.c | 5 +- external/bsd/openpam/dist/lib/pam_set_item.c | 7 +- .../openpam/dist/lib/pam_set_mapped_authtok.c | 2 +- .../dist/lib/pam_set_mapped_username.c | 2 +- external/bsd/openpam/dist/lib/pam_setcred.c | 3 +- external/bsd/openpam/dist/lib/pam_setenv.c | 3 +- .../bsd/openpam/dist/lib/pam_sm_acct_mgmt.c | 2 +- .../openpam/dist/lib/pam_sm_authenticate.c | 2 +- .../dist/lib/pam_sm_authenticate_secondary.c | 2 +- .../bsd/openpam/dist/lib/pam_sm_chauthtok.c | 2 +- .../openpam/dist/lib/pam_sm_close_session.c | 2 +- .../dist/lib/pam_sm_get_mapped_authtok.c | 2 +- .../dist/lib/pam_sm_get_mapped_username.c | 2 +- .../openpam/dist/lib/pam_sm_open_session.c | 2 +- .../dist/lib/pam_sm_set_mapped_authtok.c | 2 +- .../dist/lib/pam_sm_set_mapped_username.c | 2 +- .../bsd/openpam/dist/lib/pam_sm_setcred.c | 2 +- external/bsd/openpam/dist/lib/pam_start.c | 5 +- external/bsd/openpam/dist/lib/pam_strerror.c | 3 +- external/bsd/openpam/dist/lib/pam_verror.c | 2 +- external/bsd/openpam/dist/lib/pam_vinfo.c | 2 +- external/bsd/openpam/dist/lib/pam_vprompt.c | 5 +- external/bsd/openpam/dist/misc/gendoc.pl | 6 +- .../openpam/dist/modules/pam_deny/pam_deny.c | 2 +- .../dist/modules/pam_permit/pam_permit.c | 2 +- .../openpam/dist/modules/pam_unix/pam_unix.c | 2 +- 126 files changed, 401 insertions(+), 251 deletions(-) diff --git a/external/bsd/openpam/dist/bin/pamtest/pamtest.1 b/external/bsd/openpam/dist/bin/pamtest/pamtest.1 index fad69793cc87..f7a1d88587c3 100644 --- a/external/bsd/openpam/dist/bin/pamtest/pamtest.1 +++ b/external/bsd/openpam/dist/bin/pamtest/pamtest.1 @@ -1,4 +1,4 @@ -.\" $NetBSD: pamtest.1,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ +.\" $NetBSD: pamtest.1,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2011 Dag-Erling Smørgrav diff --git a/external/bsd/openpam/dist/bin/pamtest/pamtest.c b/external/bsd/openpam/dist/bin/pamtest/pamtest.c index d503b63c299e..79b39f02b614 100644 --- a/external/bsd/openpam/dist/bin/pamtest/pamtest.c +++ b/external/bsd/openpam/dist/bin/pamtest/pamtest.c @@ -1,4 +1,4 @@ -/* $NetBSD: pamtest.c,v 1.1.1.1 2011/12/25 21:42:53 christos Exp $ */ +/* $NetBSD: pamtest.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2011 Dag-Erling Smørgrav diff --git a/external/bsd/openpam/dist/bin/su/su.1 b/external/bsd/openpam/dist/bin/su/su.1 index a5c8b01d821d..4afb936d230c 100644 --- a/external/bsd/openpam/dist/bin/su/su.1 +++ b/external/bsd/openpam/dist/bin/su/su.1 @@ -1,4 +1,4 @@ -.\" $NetBSD: su.1,v 1.1.1.1 2011/12/25 21:42:53 christos Exp $ +.\" $NetBSD: su.1,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2011 Dag-Erling Smørgrav diff --git a/external/bsd/openpam/dist/bin/su/su.c b/external/bsd/openpam/dist/bin/su/su.c index 3bb151efede5..2187d7c23771 100644 --- a/external/bsd/openpam/dist/bin/su/su.c +++ b/external/bsd/openpam/dist/bin/su/su.c @@ -1,4 +1,4 @@ -/* $NetBSD: su.c,v 1.1.1.1 2011/12/25 21:42:53 christos Exp $ */ +/* $NetBSD: su.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/doc/man/openpam.3 b/external/bsd/openpam/dist/doc/man/openpam.3 index 49b854647b60..67b7c837ad92 100644 --- a/external/bsd/openpam/dist/doc/man/openpam.3 +++ b/external/bsd/openpam/dist/doc/man/openpam.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: openpam.3,v 1.1.1.1 2011/12/25 21:42:59 christos Exp $ +.\" $NetBSD: openpam.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: openpam.3,v 1.1.1.1 2011/12/25 21:42:59 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt OPENPAM 3 diff --git a/external/bsd/openpam/dist/doc/man/openpam_borrow_cred.3 b/external/bsd/openpam/dist/doc/man/openpam_borrow_cred.3 index 47b8aff217a5..b5eb70200796 100644 --- a/external/bsd/openpam/dist/doc/man/openpam_borrow_cred.3 +++ b/external/bsd/openpam/dist/doc/man/openpam_borrow_cred.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: openpam_borrow_cred.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: openpam_borrow_cred.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: openpam_borrow_cred.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt OPENPAM_BORROW_CRED 3 @@ -61,7 +61,6 @@ The affected credentials are the effective UID, the effective GID, and the group access list. The original credentials can be restored using .Xr openpam_restore_cred 3 . -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/openpam_free_data.3 b/external/bsd/openpam/dist/doc/man/openpam_free_data.3 index 342f6dd519bd..0eb818519285 100644 --- a/external/bsd/openpam/dist/doc/man/openpam_free_data.3 +++ b/external/bsd/openpam/dist/doc/man/openpam_free_data.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: openpam_free_data.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: openpam_free_data.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: openpam_free_data.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt OPENPAM_FREE_DATA 3 diff --git a/external/bsd/openpam/dist/doc/man/openpam_free_envlist.3 b/external/bsd/openpam/dist/doc/man/openpam_free_envlist.3 index 7d182db562c7..c4a8acd76a2c 100644 --- a/external/bsd/openpam/dist/doc/man/openpam_free_envlist.3 +++ b/external/bsd/openpam/dist/doc/man/openpam_free_envlist.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: openpam_free_envlist.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: openpam_free_envlist.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: openpam_free_envlist.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt OPENPAM_FREE_ENVLIST 3 diff --git a/external/bsd/openpam/dist/doc/man/openpam_get_option.3 b/external/bsd/openpam/dist/doc/man/openpam_get_option.3 index 33dbdfabb2fd..bd41d1fcf4bd 100644 --- a/external/bsd/openpam/dist/doc/man/openpam_get_option.3 +++ b/external/bsd/openpam/dist/doc/man/openpam_get_option.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: openpam_get_option.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: openpam_get_option.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: openpam_get_option.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt OPENPAM_GET_OPTION 3 @@ -57,7 +57,6 @@ function returns the value of the specified option in the context of the currently executing service module, or .Dv NULL if the option is not set or no module is currently executing. -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/openpam_log.3 b/external/bsd/openpam/dist/doc/man/openpam_log.3 index af68c7ab6576..3d685bacb471 100644 --- a/external/bsd/openpam/dist/doc/man/openpam_log.3 +++ b/external/bsd/openpam/dist/doc/man/openpam_log.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: openpam_log.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: openpam_log.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: openpam_log.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt OPENPAM_LOG 3 diff --git a/external/bsd/openpam/dist/doc/man/openpam_nullconv.3 b/external/bsd/openpam/dist/doc/man/openpam_nullconv.3 index d2416e89b1f8..373b178a11f4 100644 --- a/external/bsd/openpam/dist/doc/man/openpam_nullconv.3 +++ b/external/bsd/openpam/dist/doc/man/openpam_nullconv.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: openpam_nullconv.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: openpam_nullconv.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: openpam_nullconv.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt OPENPAM_NULLCONV 3 @@ -68,9 +68,7 @@ and their PAM configuration should specify the option for all modules that require access to the authentication token, to make sure they use .Dv PAM_AUTHTOK -rather than -try to query the user. -.Pp +rather than try to query the user. .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/openpam_readline.3 b/external/bsd/openpam/dist/doc/man/openpam_readline.3 index b51f22d9dcda..91af4047381c 100644 --- a/external/bsd/openpam/dist/doc/man/openpam_readline.3 +++ b/external/bsd/openpam/dist/doc/man/openpam_readline.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: openpam_readline.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: openpam_readline.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: openpam_readline.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt OPENPAM_READLINE 3 diff --git a/external/bsd/openpam/dist/doc/man/openpam_restore_cred.3 b/external/bsd/openpam/dist/doc/man/openpam_restore_cred.3 index 20ec29adaaa7..67f80f1a3085 100644 --- a/external/bsd/openpam/dist/doc/man/openpam_restore_cred.3 +++ b/external/bsd/openpam/dist/doc/man/openpam_restore_cred.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: openpam_restore_cred.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: openpam_restore_cred.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: openpam_restore_cred.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt OPENPAM_RESTORE_CRED 3 @@ -55,7 +55,6 @@ The .Nm function restores the credentials saved by .Xr openpam_borrow_cred 3 . -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/openpam_set_option.3 b/external/bsd/openpam/dist/doc/man/openpam_set_option.3 index a434d88ec7ca..e9747a05dd86 100644 --- a/external/bsd/openpam/dist/doc/man/openpam_set_option.3 +++ b/external/bsd/openpam/dist/doc/man/openpam_set_option.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: openpam_set_option.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: openpam_set_option.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: openpam_set_option.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt OPENPAM_SET_OPTION 3 @@ -55,7 +55,6 @@ The .Nm function sets the specified option in the context of the currently executing service module. -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/openpam_subst.3 b/external/bsd/openpam/dist/doc/man/openpam_subst.3 index ebe88fc4615e..a35bede538cf 100644 --- a/external/bsd/openpam/dist/doc/man/openpam_subst.3 +++ b/external/bsd/openpam/dist/doc/man/openpam_subst.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: openpam_subst.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: openpam_subst.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: openpam_subst.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt OPENPAM_SUBST 3 diff --git a/external/bsd/openpam/dist/doc/man/openpam_ttyconv.3 b/external/bsd/openpam/dist/doc/man/openpam_ttyconv.3 index 77c92939f56c..d930a39f078b 100644 --- a/external/bsd/openpam/dist/doc/man/openpam_ttyconv.3 +++ b/external/bsd/openpam/dist/doc/man/openpam_ttyconv.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: openpam_ttyconv.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: openpam_ttyconv.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: openpam_ttyconv.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt OPENPAM_TTYCONV 3 @@ -60,6 +60,14 @@ programs. .Pp The .Nm +function displays a prompt to, and reads in a +password from /dev/tty. If this file is not accessible, +.Nm +displays the prompt on the standard error output and reads from the +standard input. +.Pp +The +.Nm function allows the application to specify a timeout for user input by setting the global integer variable .Va openpam_ttyconv_timeout @@ -78,6 +86,7 @@ Conversation failure. System error. .El .Sh SEE ALSO +.Xr getpass 3 , .Xr openpam_nullconv 3 , .Xr pam 3 , .Xr pam_prompt 3 , diff --git a/external/bsd/openpam/dist/doc/man/pam.3 b/external/bsd/openpam/dist/doc/man/pam.3 index ff89ced7ad59..65c1e372d130 100644 --- a/external/bsd/openpam/dist/doc/man/pam.3 +++ b/external/bsd/openpam/dist/doc/man/pam.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM 3 diff --git a/external/bsd/openpam/dist/doc/man/pam.conf.5 b/external/bsd/openpam/dist/doc/man/pam.conf.5 index 0e9dbeddea42..62b3f997b691 100644 --- a/external/bsd/openpam/dist/doc/man/pam.conf.5 +++ b/external/bsd/openpam/dist/doc/man/pam.conf.5 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam.conf.5,v 1.1.1.1 2011/12/25 21:42:59 christos Exp $ +.\" $NetBSD: pam.conf.5,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2005-2011 Dag-Erling Smørgrav diff --git a/external/bsd/openpam/dist/doc/man/pam_acct_mgmt.3 b/external/bsd/openpam/dist/doc/man/pam_acct_mgmt.3 index ada609ea2e55..57afbf3603e9 100644 --- a/external/bsd/openpam/dist/doc/man/pam_acct_mgmt.3 +++ b/external/bsd/openpam/dist/doc/man/pam_acct_mgmt.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_acct_mgmt.3,v 1.1.1.1 2011/12/25 21:42:56 christos Exp $ +.\" $NetBSD: pam_acct_mgmt.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_acct_mgmt.3,v 1.1.1.1 2011/12/25 21:42:56 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_ACCT_MGMT 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_authenticate.3 b/external/bsd/openpam/dist/doc/man/pam_authenticate.3 index e3d35842c9fe..051e670d53c7 100644 --- a/external/bsd/openpam/dist/doc/man/pam_authenticate.3 +++ b/external/bsd/openpam/dist/doc/man/pam_authenticate.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_authenticate.3,v 1.1.1.1 2011/12/25 21:42:56 christos Exp $ +.\" $NetBSD: pam_authenticate.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_authenticate.3,v 1.1.1.1 2011/12/25 21:42:56 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_AUTHENTICATE 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_chauthtok.3 b/external/bsd/openpam/dist/doc/man/pam_chauthtok.3 index 8cc8341e88f9..80ab38ed6154 100644 --- a/external/bsd/openpam/dist/doc/man/pam_chauthtok.3 +++ b/external/bsd/openpam/dist/doc/man/pam_chauthtok.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_chauthtok.3,v 1.1.1.1 2011/12/25 21:42:56 christos Exp $ +.\" $NetBSD: pam_chauthtok.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_chauthtok.3,v 1.1.1.1 2011/12/25 21:42:56 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_CHAUTHTOK 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_close_session.3 b/external/bsd/openpam/dist/doc/man/pam_close_session.3 index a45b26e6fca1..0f7eca0a4b09 100644 --- a/external/bsd/openpam/dist/doc/man/pam_close_session.3 +++ b/external/bsd/openpam/dist/doc/man/pam_close_session.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_close_session.3,v 1.1.1.1 2011/12/25 21:42:56 christos Exp $ +.\" $NetBSD: pam_close_session.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_close_session.3,v 1.1.1.1 2011/12/25 21:42:56 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_CLOSE_SESSION 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_conv.3 b/external/bsd/openpam/dist/doc/man/pam_conv.3 index 56e7103a6aa2..1e41b5bae51c 100644 --- a/external/bsd/openpam/dist/doc/man/pam_conv.3 +++ b/external/bsd/openpam/dist/doc/man/pam_conv.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_conv.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_conv.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -178,8 +178,9 @@ System error. .Re .Sh AUTHORS The OpenPAM library and this manual page were developed for the -FreeBSD Project by ThinkSec AS and Network Associates Laboratories, -the Security Research Division of Network Associates, Inc.\& under +.Fx +Project by ThinkSec AS and Network Associates Laboratories, +the Security Research Division of Network Associates, Inc. under DARPA/SPAWAR contract N66001-01-C-8035 .Pq Dq CBOSS , as part of the DARPA CHATS research program. diff --git a/external/bsd/openpam/dist/doc/man/pam_end.3 b/external/bsd/openpam/dist/doc/man/pam_end.3 index cb5841e6ade7..e9d1973558c6 100644 --- a/external/bsd/openpam/dist/doc/man/pam_end.3 +++ b/external/bsd/openpam/dist/doc/man/pam_end.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_end.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_end.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_end.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_END 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_error.3 b/external/bsd/openpam/dist/doc/man/pam_error.3 index 59b109ec9c74..22fc5a05cbfb 100644 --- a/external/bsd/openpam/dist/doc/man/pam_error.3 +++ b/external/bsd/openpam/dist/doc/man/pam_error.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_error.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: pam_error.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_error.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_ERROR 3 @@ -54,7 +54,6 @@ The .Nm function displays an error message through the intermediary of the given PAM context's conversation function. -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/pam_get_authtok.3 b/external/bsd/openpam/dist/doc/man/pam_get_authtok.3 index d745212a8b4b..8632f0f48ee9 100644 --- a/external/bsd/openpam/dist/doc/man/pam_get_authtok.3 +++ b/external/bsd/openpam/dist/doc/man/pam_get_authtok.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_get_authtok.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: pam_get_authtok.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_get_authtok.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_GET_AUTHTOK 3 @@ -119,7 +119,6 @@ If there is a mismatch, .Nm will return .Dv PAM_TRY_AGAIN . -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/pam_get_data.3 b/external/bsd/openpam/dist/doc/man/pam_get_data.3 index 7107af51ec66..fceebd7d2b93 100644 --- a/external/bsd/openpam/dist/doc/man/pam_get_data.3 +++ b/external/bsd/openpam/dist/doc/man/pam_get_data.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_get_data.3,v 1.1.1.1 2011/12/25 21:42:56 christos Exp $ +.\" $NetBSD: pam_get_data.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_get_data.3,v 1.1.1.1 2011/12/25 21:42:56 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_GET_DATA 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_get_item.3 b/external/bsd/openpam/dist/doc/man/pam_get_item.3 index 17a48045dd3c..e65e4693589d 100644 --- a/external/bsd/openpam/dist/doc/man/pam_get_item.3 +++ b/external/bsd/openpam/dist/doc/man/pam_get_item.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_get_item.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_get_item.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_get_item.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_GET_ITEM 3 @@ -100,13 +100,20 @@ The prompt to use when asking the applicant for an expired authentication token prior to changing it. .It Dv PAM_HOST The name of the host the application runs on. +.It Dv PAM_SOCKADDR +The sockaddr_storage of the applicants's host. +.It Dv PAM_NUSER +The +.Do +nested +.Dc +user if this is a login on top of a previous one. .El .Pp See .Xr pam_start 3 for a description of .Vt struct pam_conv . -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/pam_get_user.3 b/external/bsd/openpam/dist/doc/man/pam_get_user.3 index 46e895b3f526..67d8c05fa845 100644 --- a/external/bsd/openpam/dist/doc/man/pam_get_user.3 +++ b/external/bsd/openpam/dist/doc/man/pam_get_user.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_get_user.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_get_user.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_get_user.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_GET_USER 3 @@ -92,7 +92,6 @@ both the argument and the .Dv PAM_USER_PROMPT item. -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/pam_getenv.3 b/external/bsd/openpam/dist/doc/man/pam_getenv.3 index 3e3094410765..619cdfe8d64b 100644 --- a/external/bsd/openpam/dist/doc/man/pam_getenv.3 +++ b/external/bsd/openpam/dist/doc/man/pam_getenv.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_getenv.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_getenv.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_getenv.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_GETENV 3 @@ -57,7 +57,6 @@ Its semantics are similar to those of .Xr getenv 3 , but it accesses the PAM context's environment list instead of the application's. -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/pam_getenvlist.3 b/external/bsd/openpam/dist/doc/man/pam_getenvlist.3 index 8760081bbeeb..d04440700ff1 100644 --- a/external/bsd/openpam/dist/doc/man/pam_getenvlist.3 +++ b/external/bsd/openpam/dist/doc/man/pam_getenvlist.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_getenvlist.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_getenvlist.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_getenvlist.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_GETENVLIST 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_info.3 b/external/bsd/openpam/dist/doc/man/pam_info.3 index f8c0d0cac172..1c242089fb4c 100644 --- a/external/bsd/openpam/dist/doc/man/pam_info.3 +++ b/external/bsd/openpam/dist/doc/man/pam_info.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_info.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: pam_info.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_info.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_INFO 3 @@ -54,7 +54,6 @@ The .Nm function displays an informational message through the intermediary of the given PAM context's conversation function. -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/pam_open_session.3 b/external/bsd/openpam/dist/doc/man/pam_open_session.3 index 998d1d58163d..f59be555fcb4 100644 --- a/external/bsd/openpam/dist/doc/man/pam_open_session.3 +++ b/external/bsd/openpam/dist/doc/man/pam_open_session.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_open_session.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_open_session.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_open_session.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_OPEN_SESSION 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_prompt.3 b/external/bsd/openpam/dist/doc/man/pam_prompt.3 index 3454d92e15c5..41078f518572 100644 --- a/external/bsd/openpam/dist/doc/man/pam_prompt.3 +++ b/external/bsd/openpam/dist/doc/man/pam_prompt.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_prompt.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: pam_prompt.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_prompt.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_PROMPT 3 @@ -66,7 +66,6 @@ argument. See .Xr pam_vprompt 3 for further details. -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/pam_putenv.3 b/external/bsd/openpam/dist/doc/man/pam_putenv.3 index 6b84564e0c31..0703349adaaa 100644 --- a/external/bsd/openpam/dist/doc/man/pam_putenv.3 +++ b/external/bsd/openpam/dist/doc/man/pam_putenv.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_putenv.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_putenv.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_putenv.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_PUTENV 3 @@ -57,7 +57,6 @@ Its semantics are similar to those of .Xr putenv 3 , but it modifies the PAM context's environment list instead of the application's. -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/pam_set_data.3 b/external/bsd/openpam/dist/doc/man/pam_set_data.3 index accd622428f0..ab76db97d41d 100644 --- a/external/bsd/openpam/dist/doc/man/pam_set_data.3 +++ b/external/bsd/openpam/dist/doc/man/pam_set_data.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_set_data.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_set_data.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_set_data.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_SET_DATA 3 @@ -82,6 +82,7 @@ Memory buffer error. System error. .El .Sh SEE ALSO +.Xr openpam_free_data 3 , .Xr pam 3 , .Xr pam_get_data 3 , .Xr pam_strerror 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_set_item.3 b/external/bsd/openpam/dist/doc/man/pam_set_item.3 index 38617948eb6f..b99cf4f9ad9d 100644 --- a/external/bsd/openpam/dist/doc/man/pam_set_item.3 +++ b/external/bsd/openpam/dist/doc/man/pam_set_item.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_set_item.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_set_item.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_set_item.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_SET_ITEM 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_setcred.3 b/external/bsd/openpam/dist/doc/man/pam_setcred.3 index 91748df12f29..9134000b72c2 100644 --- a/external/bsd/openpam/dist/doc/man/pam_setcred.3 +++ b/external/bsd/openpam/dist/doc/man/pam_setcred.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_setcred.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_setcred.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_setcred.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_SETCRED 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_setenv.3 b/external/bsd/openpam/dist/doc/man/pam_setenv.3 index 79bd52a8224f..273b9d26d6f4 100644 --- a/external/bsd/openpam/dist/doc/man/pam_setenv.3 +++ b/external/bsd/openpam/dist/doc/man/pam_setenv.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_setenv.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: pam_setenv.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_setenv.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_SETENV 3 @@ -57,7 +57,6 @@ Its semantics are similar to those of .Xr setenv 3 , but it modifies the PAM context's environment list instead of the application's. -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/pam_sm_acct_mgmt.3 b/external/bsd/openpam/dist/doc/man/pam_sm_acct_mgmt.3 index 3be70d9fae71..4b4e480b6bd9 100644 --- a/external/bsd/openpam/dist/doc/man/pam_sm_acct_mgmt.3 +++ b/external/bsd/openpam/dist/doc/man/pam_sm_acct_mgmt.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_sm_acct_mgmt.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_sm_acct_mgmt.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_sm_acct_mgmt.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_SM_ACCT_MGMT 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_sm_authenticate.3 b/external/bsd/openpam/dist/doc/man/pam_sm_authenticate.3 index 6dc067574b30..de0f2d3939fc 100644 --- a/external/bsd/openpam/dist/doc/man/pam_sm_authenticate.3 +++ b/external/bsd/openpam/dist/doc/man/pam_sm_authenticate.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_sm_authenticate.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_sm_authenticate.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_sm_authenticate.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_SM_AUTHENTICATE 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_sm_chauthtok.3 b/external/bsd/openpam/dist/doc/man/pam_sm_chauthtok.3 index 42bafe0af3ea..26839f55520d 100644 --- a/external/bsd/openpam/dist/doc/man/pam_sm_chauthtok.3 +++ b/external/bsd/openpam/dist/doc/man/pam_sm_chauthtok.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_sm_chauthtok.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_sm_chauthtok.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_sm_chauthtok.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_SM_CHAUTHTOK 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_sm_close_session.3 b/external/bsd/openpam/dist/doc/man/pam_sm_close_session.3 index 1b60ec8e4faf..e94d01155736 100644 --- a/external/bsd/openpam/dist/doc/man/pam_sm_close_session.3 +++ b/external/bsd/openpam/dist/doc/man/pam_sm_close_session.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_sm_close_session.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_sm_close_session.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_sm_close_session.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_SM_CLOSE_SESSION 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_sm_open_session.3 b/external/bsd/openpam/dist/doc/man/pam_sm_open_session.3 index 7017004a3b74..c23957917340 100644 --- a/external/bsd/openpam/dist/doc/man/pam_sm_open_session.3 +++ b/external/bsd/openpam/dist/doc/man/pam_sm_open_session.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_sm_open_session.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: pam_sm_open_session.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_sm_open_session.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_SM_OPEN_SESSION 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_sm_setcred.3 b/external/bsd/openpam/dist/doc/man/pam_sm_setcred.3 index e2a38b90e6dc..dd3149cfe1f4 100644 --- a/external/bsd/openpam/dist/doc/man/pam_sm_setcred.3 +++ b/external/bsd/openpam/dist/doc/man/pam_sm_setcred.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_sm_setcred.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" $NetBSD: pam_sm_setcred.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_sm_setcred.3,v 1.1.1.1 2011/12/25 21:42:58 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_SM_SETCRED 3 diff --git a/external/bsd/openpam/dist/doc/man/pam_start.3 b/external/bsd/openpam/dist/doc/man/pam_start.3 index 453d74570758..0348530fa7f0 100644 --- a/external/bsd/openpam/dist/doc/man/pam_start.3 +++ b/external/bsd/openpam/dist/doc/man/pam_start.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_start.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_start.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_start.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_START 3 @@ -77,7 +77,6 @@ describing the conversation function to use; see .Fa pam_conv for details. -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/pam_strerror.3 b/external/bsd/openpam/dist/doc/man/pam_strerror.3 index f93e46f312f1..feae9ef7ecb6 100644 --- a/external/bsd/openpam/dist/doc/man/pam_strerror.3 +++ b/external/bsd/openpam/dist/doc/man/pam_strerror.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_strerror.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" $NetBSD: pam_strerror.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,9 +34,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_strerror.3,v 1.1.1.1 2011/12/25 21:42:57 christos Exp $ +.\" Id .\" -.Dd December 18, 2011 +.Dd December 25, 2011 .Dt PAM_STRERROR 3 .Os .Sh NAME @@ -56,6 +56,8 @@ function returns a pointer to a string containing a textual description of the error indicated by the .Fa error_number argument. +argument, in the context of the PAM transaction described by the +.Fa pamh The .Fa pamh argument is ignored. diff --git a/external/bsd/openpam/dist/doc/man/pam_verror.3 b/external/bsd/openpam/dist/doc/man/pam_verror.3 index b333e4551f52..8e6fa0eb64f0 100644 --- a/external/bsd/openpam/dist/doc/man/pam_verror.3 +++ b/external/bsd/openpam/dist/doc/man/pam_verror.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_verror.3,v 1.1.1.1 2011/12/25 21:42:59 christos Exp $ +.\" $NetBSD: pam_verror.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_verror.3,v 1.1.1.1 2011/12/25 21:42:59 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_VERROR 3 @@ -58,7 +58,6 @@ with a style argument of .Dv PAM_ERROR_MSG , and discards the response. -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/pam_vinfo.3 b/external/bsd/openpam/dist/doc/man/pam_vinfo.3 index c63b7c0d0d30..dacf9a6ad249 100644 --- a/external/bsd/openpam/dist/doc/man/pam_vinfo.3 +++ b/external/bsd/openpam/dist/doc/man/pam_vinfo.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_vinfo.3,v 1.1.1.1 2011/12/25 21:42:59 christos Exp $ +.\" $NetBSD: pam_vinfo.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_vinfo.3,v 1.1.1.1 2011/12/25 21:42:59 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_VINFO 3 @@ -58,7 +58,6 @@ with a style argument of .Dv PAM_TEXT_INFO , and discards the response. -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/doc/man/pam_vprompt.3 b/external/bsd/openpam/dist/doc/man/pam_vprompt.3 index 96b44fe11909..a97bac752261 100644 --- a/external/bsd/openpam/dist/doc/man/pam_vprompt.3 +++ b/external/bsd/openpam/dist/doc/man/pam_vprompt.3 @@ -1,4 +1,4 @@ -.\" $NetBSD: pam_vprompt.3,v 1.1.1.1 2011/12/25 21:42:59 christos Exp $ +.\" $NetBSD: pam_vprompt.3,v 1.2 2011/12/25 22:27:55 christos Exp $ .\" .\"- .\" Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -34,7 +34,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: pam_vprompt.3,v 1.1.1.1 2011/12/25 21:42:59 christos Exp $ +.\" Id .\" .Dd December 18, 2011 .Dt PAM_VPROMPT 3 @@ -92,7 +92,6 @@ or .Dv PAM_MAX_RESP_SIZE , respectively. If they do, they may be truncated. -.Pp .Sh RETURN VALUES The .Nm diff --git a/external/bsd/openpam/dist/include/security/openpam.h b/external/bsd/openpam/dist/include/security/openpam.h index a9de772f3d12..c4c145ad0b1e 100644 --- a/external/bsd/openpam/dist/include/security/openpam.h +++ b/external/bsd/openpam/dist/include/security/openpam.h @@ -1,4 +1,4 @@ -/* $NetBSD: openpam.h,v 1.1.1.1 2011/12/25 21:42:55 christos Exp $ */ +/* $NetBSD: openpam.h,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -191,9 +191,9 @@ _openpam_log(int _level, #elif defined(__GNUC__) && (__GNUC__ >= 2) && (__GNUC_MINOR__ >= 95) #define openpam_log(lvl, fmt...) \ _openpam_log((lvl), __func__, ##fmt) -#elif defined(__GNUC__) && defined(__FUNCTION__) +#elif defined(__GNUC__) && defined(__func__) #define openpam_log(lvl, fmt...) \ - _openpam_log((lvl), __FUNCTION__, ##fmt) + _openpam_log((lvl), __func__, ##fmt) #else void openpam_log(int _level, @@ -327,7 +327,14 @@ struct pam_module { # endif /* gcc, static linking */ # include -# include +# ifdef __FreeBSD__ +# include +# endif +# ifdef __NetBSD__ +# define DATA_SET(a, b) __link_set_add_data(a, b) +# define SET_DECLARE(a, b) __link_set_decl(a, b) +# define SET_FOREACH(a, b) __link_set_foreach(a, b) +# endif # define PAM_EXTERN static # define PAM_MODULE_ENTRY(name) \ static char _pam_name[] = name PAM_SOEXT; \ diff --git a/external/bsd/openpam/dist/include/security/openpam_attr.h b/external/bsd/openpam/dist/include/security/openpam_attr.h index 9a97176a4137..5839d1f6a17d 100644 --- a/external/bsd/openpam/dist/include/security/openpam_attr.h +++ b/external/bsd/openpam/dist/include/security/openpam_attr.h @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_attr.h,v 1.1.1.1 2011/12/25 21:42:55 christos Exp $ */ +/* $NetBSD: openpam_attr.h,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /* * Id: openpam_attr.h 405 2007-12-19 11:38:27Z des diff --git a/external/bsd/openpam/dist/include/security/openpam_version.h b/external/bsd/openpam/dist/include/security/openpam_version.h index 8392d86feba2..782d61725fff 100644 --- a/external/bsd/openpam/dist/include/security/openpam_version.h +++ b/external/bsd/openpam/dist/include/security/openpam_version.h @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_version.h,v 1.1.1.1 2011/12/25 21:42:55 christos Exp $ */ +/* $NetBSD: openpam_version.h,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/include/security/pam_appl.h b/external/bsd/openpam/dist/include/security/pam_appl.h index 74dab6be006c..06a73df9a2f7 100644 --- a/external/bsd/openpam/dist/include/security/pam_appl.h +++ b/external/bsd/openpam/dist/include/security/pam_appl.h @@ -1,4 +1,4 @@ -/* $NetBSD: pam_appl.h,v 1.1.1.1 2011/12/25 21:42:55 christos Exp $ */ +/* $NetBSD: pam_appl.h,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/include/security/pam_constants.h b/external/bsd/openpam/dist/include/security/pam_constants.h index 481df3f2fb30..f39f3be559e7 100644 --- a/external/bsd/openpam/dist/include/security/pam_constants.h +++ b/external/bsd/openpam/dist/include/security/pam_constants.h @@ -1,4 +1,4 @@ -/* $NetBSD: pam_constants.h,v 1.1.1.1 2011/12/25 21:42:55 christos Exp $ */ +/* $NetBSD: pam_constants.h,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -129,6 +129,8 @@ enum { PAM_AUTHTOK_PROMPT = 11, /* OpenPAM extension */ PAM_OLDAUTHTOK_PROMPT = 12, /* OpenPAM extension */ PAM_HOST = 13, /* OpenPAM extension */ + PAM_SOCKADDR = 14, /* NetBSD extension */ + PAM_NUSER = 15, /* NetBSD extension */ PAM_NUM_ITEMS /* OpenPAM extension */ }; diff --git a/external/bsd/openpam/dist/include/security/pam_modules.h b/external/bsd/openpam/dist/include/security/pam_modules.h index 62ab1a343bfa..c3fe87b9e9b9 100644 --- a/external/bsd/openpam/dist/include/security/pam_modules.h +++ b/external/bsd/openpam/dist/include/security/pam_modules.h @@ -1,4 +1,4 @@ -/* $NetBSD: pam_modules.h,v 1.1.1.1 2011/12/25 21:42:55 christos Exp $ */ +/* $NetBSD: pam_modules.h,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/include/security/pam_types.h b/external/bsd/openpam/dist/include/security/pam_types.h index dfde6a637dc5..ef074bc552f8 100644 --- a/external/bsd/openpam/dist/include/security/pam_types.h +++ b/external/bsd/openpam/dist/include/security/pam_types.h @@ -1,4 +1,4 @@ -/* $NetBSD: pam_types.h,v 1.1.1.1 2011/12/25 21:42:55 christos Exp $ */ +/* $NetBSD: pam_types.h,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/openpam_borrow_cred.c b/external/bsd/openpam/dist/lib/openpam_borrow_cred.c index 33c2103be30e..4572f8f669cc 100644 --- a/external/bsd/openpam/dist/lib/openpam_borrow_cred.c +++ b/external/bsd/openpam/dist/lib/openpam_borrow_cred.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_borrow_cred.c,v 1.1.1.1 2011/12/25 21:42:48 christos Exp $ */ +/* $NetBSD: openpam_borrow_cred.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -79,7 +79,7 @@ openpam_borrow_cred(pam_handle_t *pamh, (int)geteuid()); RETURNC(PAM_PERM_DENIED); } - scred = calloc(1, sizeof *scred); + scred = calloc((size_t)1, sizeof *scred); if (scred == NULL) RETURNC(PAM_BUF_ERR); scred->euid = geteuid(); @@ -103,6 +103,7 @@ openpam_borrow_cred(pam_handle_t *pamh, RETURNC(PAM_SYSTEM_ERR); } RETURNC(PAM_SUCCESS); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/openpam_check_owner_perms.c b/external/bsd/openpam/dist/lib/openpam_check_owner_perms.c index 632c633288a1..9722a5978923 100644 --- a/external/bsd/openpam/dist/lib/openpam_check_owner_perms.c +++ b/external/bsd/openpam/dist/lib/openpam_check_owner_perms.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_check_owner_perms.c,v 1.1.1.1 2011/12/25 21:42:49 christos Exp $ */ +/* $NetBSD: openpam_check_owner_perms.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2011 Dag-Erling Smørgrav diff --git a/external/bsd/openpam/dist/lib/openpam_configure.c b/external/bsd/openpam/dist/lib/openpam_configure.c index 9d550c5956b1..b23b3054e59a 100644 --- a/external/bsd/openpam/dist/lib/openpam_configure.c +++ b/external/bsd/openpam/dist/lib/openpam_configure.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_configure.c,v 1.1.1.1 2011/12/25 21:42:49 christos Exp $ */ +/* $NetBSD: openpam_configure.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -450,7 +450,7 @@ openpam_parse_chain(pam_handle_t *pamh, goto syserr; /* allocate new entry */ - if ((this = calloc(1, sizeof *this)) == NULL) + if ((this = calloc((size_t)1, sizeof *this)) == NULL) goto syserr; this->flag = ctlf; @@ -512,8 +512,12 @@ fail: static const char *openpam_policy_path[] = { "/etc/pam.d/", "/etc/pam.conf", +#ifndef __NetBSD__ "/usr/local/etc/pam.d/", "/usr/local/etc/pam.conf", +#else + /* Possibly /usr/pkg? */ +#endif NULL }; @@ -531,6 +535,12 @@ openpam_load_chain(pam_handle_t *pamh, size_t len; int ret; + /* don't allow to escape from policy_path */ + if (strchr(service, '/')) { + openpam_log(PAM_LOG_ERROR, "illegal service \"%s\"", service); + return (-PAM_SYSTEM_ERR); + } + for (path = openpam_policy_path; *path != NULL; ++path) { len = strlen(*path); if ((*path)[len - 1] == '/') { @@ -577,6 +587,26 @@ openpam_configure(pam_handle_t *pamh, if (openpam_load_chain(pamh, PAM_OTHER, fclt) != PAM_SUCCESS) goto load_err; } +#ifdef __NetBSD__ + /* + * On NetBSD we require the AUTH chain to have a binding + * or a required module. + */ + { + pam_chain_t *this = pamh->chains[PAM_AUTH]; + for (; this != NULL; this = this->next) + if (this->flag == PAM_BINDING || + this->flag == PAM_REQUIRED) + break; + if (this == NULL) { + openpam_log(PAM_LOG_ERROR, + "No required or binding component " + "in service %s, facility %s", + service, _pam_facility_name[PAM_AUTH]); + goto load_err; + } + } +#endif return (PAM_SUCCESS); load_err: openpam_clear_chains(pamh->chains); diff --git a/external/bsd/openpam/dist/lib/openpam_constants.c b/external/bsd/openpam/dist/lib/openpam_constants.c index a21727583ecd..a167ebeb4b28 100644 --- a/external/bsd/openpam/dist/lib/openpam_constants.c +++ b/external/bsd/openpam/dist/lib/openpam_constants.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_constants.c,v 1.1.1.1 2011/12/25 21:42:49 christos Exp $ */ +/* $NetBSD: openpam_constants.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -93,6 +93,8 @@ const char *pam_item_name[PAM_NUM_ITEMS] = { "PAM_AUTHTOK_PROMPT", "PAM_OLDAUTHTOK_PROMPT", "PAM_HOST", + "PAM_SOCKADDR", + "PAM_NUSER" }; const char *pam_facility_name[PAM_NUM_FACILITIES] = { diff --git a/external/bsd/openpam/dist/lib/openpam_constants.h b/external/bsd/openpam/dist/lib/openpam_constants.h index 3f37c1a74878..640f11a5e343 100644 --- a/external/bsd/openpam/dist/lib/openpam_constants.h +++ b/external/bsd/openpam/dist/lib/openpam_constants.h @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_constants.h,v 1.1.1.1 2011/12/25 21:42:48 christos Exp $ */ +/* $NetBSD: openpam_constants.h,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2011 Dag-Erling Smørgrav diff --git a/external/bsd/openpam/dist/lib/openpam_debug.h b/external/bsd/openpam/dist/lib/openpam_debug.h index 310b5b22fdcb..f5056605def7 100644 --- a/external/bsd/openpam/dist/lib/openpam_debug.h +++ b/external/bsd/openpam/dist/lib/openpam_debug.h @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_debug.h,v 1.1.1.1 2011/12/25 21:42:48 christos Exp $ */ +/* $NetBSD: openpam_debug.h,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -48,18 +48,18 @@ openpam_log(PAM_LOG_DEBUG, "entering: %s", pam_item_name[i_]); \ else \ openpam_log(PAM_LOG_DEBUG, "entering: %d", i_); \ -} while (0) +} while (/*CONSTCOND*/0) #define ENTERN(n) do { \ int n_ = (n); \ openpam_log(PAM_LOG_DEBUG, "entering: %d", n_); \ -} while (0) +} while (/*CONSTCOND*/0) #define ENTERS(s) do { \ const char *s_ = (s); \ if (s_ == NULL) \ openpam_log(PAM_LOG_DEBUG, "entering: NULL"); \ else \ openpam_log(PAM_LOG_DEBUG, "entering: '%s'", s_); \ -} while (0) +} while (/*CONSTCOND*/0) #define RETURNV() openpam_log(PAM_LOG_DEBUG, "returning") #define RETURNC(c) do { \ int c_ = (c); \ @@ -68,12 +68,12 @@ else \ openpam_log(PAM_LOG_DEBUG, "returning %d!", c_); \ return (c_); \ -} while (0) +} while (/*CONSTCOND*/0) #define RETURNN(n) do { \ int n_ = (n); \ openpam_log(PAM_LOG_DEBUG, "returning %d", n_); \ return (n_); \ -} while (0) +} while (/*CONSTCOND*/0) #define RETURNP(p) do { \ const void *p_ = (p); \ if (p_ == NULL) \ @@ -81,7 +81,7 @@ else \ openpam_log(PAM_LOG_DEBUG, "returning %p", p_); \ return (p_); \ -} while (0) +} while (/*CONSTCOND*/0) #define RETURNS(s) do { \ const char *s_ = (s); \ if (s_ == NULL) \ @@ -89,7 +89,7 @@ else \ openpam_log(PAM_LOG_DEBUG, "returning '%s'", s_); \ return (s_); \ -} while (0) +} while (/*CONSTCOND*/0) #else #define ENTER() #define ENTERI(i) diff --git a/external/bsd/openpam/dist/lib/openpam_dispatch.c b/external/bsd/openpam/dist/lib/openpam_dispatch.c index 79f8eef6654e..e2dd6959277a 100644 --- a/external/bsd/openpam/dist/lib/openpam_dispatch.c +++ b/external/bsd/openpam/dist/lib/openpam_dispatch.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_dispatch.c,v 1.1.1.1 2011/12/25 21:42:49 christos Exp $ */ +/* $NetBSD: openpam_dispatch.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -65,7 +65,7 @@ openpam_dispatch(pam_handle_t *pamh, int flags) { pam_chain_t *chain; - int err, fail, r; + int err, fail, nsuccess, r; int debug; ENTER(); @@ -103,11 +103,18 @@ openpam_dispatch(pam_handle_t *pamh, } /* execute */ - for (err = fail = 0; chain != NULL; chain = chain->next) { + err = PAM_SUCCESS; + fail = nsuccess = 0; + for (; chain != NULL; chain = chain->next) { if (chain->module->func[primitive] == NULL) { + /* + * This module does not implement this primitive. + * That may be ignorable, or not, depending + * on flags. + */ openpam_log(PAM_LOG_ERROR, "%s: no %s()", chain->module->path, pam_sm_func_name[primitive]); - r = PAM_SYSTEM_ERR; + continue; } else { pamh->primitive = primitive; pamh->current = chain; @@ -117,7 +124,7 @@ openpam_dispatch(pam_handle_t *pamh, openpam_log(PAM_LOG_DEBUG, "calling %s() in %s", pam_sm_func_name[primitive], chain->module->path); r = (chain->module->func[primitive])(pamh, flags, - chain->optc, (const char **)chain->optv); + chain->optc, (void *)chain->optv); pamh->current = NULL; openpam_log(PAM_LOG_DEBUG, "%s: %s(): %s", chain->module->path, pam_sm_func_name[primitive], @@ -129,6 +136,7 @@ openpam_dispatch(pam_handle_t *pamh, if (r == PAM_IGNORE) continue; if (r == PAM_SUCCESS) { + ++nsuccess; /* * For pam_setcred() and pam_chauthtok() with the * PAM_PRELIM_CHECK flag, treat "sufficient" as @@ -150,7 +158,7 @@ openpam_dispatch(pam_handle_t *pamh, * fail. If a required module fails, record the * return code from the first required module to fail. */ - if (err == 0) + if (err == PAM_SUCCESS) err = r; if ((chain->flag == PAM_REQUIRED || chain->flag == PAM_BINDING) && !fail) { @@ -172,7 +180,22 @@ openpam_dispatch(pam_handle_t *pamh, if (!fail && err != PAM_NEW_AUTHTOK_REQD) err = PAM_SUCCESS; + +#ifdef __NetBSD__ + /* + * Require the chain to be non-empty, and at least one module + * in the chain to be successful, so that we don't fail open. + */ + if (err == PAM_SUCCESS && nsuccess < 1) { + openpam_log(PAM_LOG_ERROR, + "all modules were unsuccessful for %s()", + _pam_sm_func_name[primitive]); + err = PAM_SYSTEM_ERR; + } +#endif + RETURNC(err); + /*NOTREACHED*/ } #if !defined(OPENPAM_RELAX_CHECKS) diff --git a/external/bsd/openpam/dist/lib/openpam_dynamic.c b/external/bsd/openpam/dist/lib/openpam_dynamic.c index 2372a8487b99..3a63b7ce9f8f 100644 --- a/external/bsd/openpam/dist/lib/openpam_dynamic.c +++ b/external/bsd/openpam/dist/lib/openpam_dynamic.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_dynamic.c,v 1.1.1.1 2011/12/25 21:42:49 christos Exp $ */ +/* $NetBSD: openpam_dynamic.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -96,7 +96,7 @@ openpam_dynamic(const char *path) prefix = ""; /* try versioned module first, then unversioned module */ - if (asprintf(&vpath, "%s%s.%d", prefix, path, LIB_MAJ) < 0) + if (asprintf(&vpath, "%s/%s.%d", prefix, path, LIB_MAJ) < 0) goto err; if ((dlh = try_dlopen(vpath)) == NULL && errno == ENOENT) { *strrchr(vpath, '.') = '\0'; @@ -107,7 +107,7 @@ openpam_dynamic(const char *path) errno = serrno; if (dlh == NULL) goto err; - if ((module = calloc(1, sizeof *module)) == NULL) + if ((module = calloc((size_t)1, sizeof *module)) == NULL) goto buf_err; if ((module->path = strdup(path)) == NULL) goto buf_err; diff --git a/external/bsd/openpam/dist/lib/openpam_findenv.c b/external/bsd/openpam/dist/lib/openpam_findenv.c index df9566ff402b..ec538588c7ab 100644 --- a/external/bsd/openpam/dist/lib/openpam_findenv.c +++ b/external/bsd/openpam/dist/lib/openpam_findenv.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_findenv.c,v 1.1.1.1 2011/12/25 21:42:49 christos Exp $ */ +/* $NetBSD: openpam_findenv.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -68,6 +68,7 @@ openpam_findenv(pam_handle_t *pamh, pamh->env[i][len] == '=') RETURNN(i); RETURNN(-1); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/openpam_free_data.c b/external/bsd/openpam/dist/lib/openpam_free_data.c index 8339da7e2e64..1e785a946688 100644 --- a/external/bsd/openpam/dist/lib/openpam_free_data.c +++ b/external/bsd/openpam/dist/lib/openpam_free_data.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_free_data.c,v 1.1.1.1 2011/12/25 21:42:49 christos Exp $ */ +/* $NetBSD: openpam_free_data.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -61,7 +61,9 @@ openpam_free_data(pam_handle_t *pamh, { ENTER(); + /*LINTED unused*/ (void)pamh; + /*LINTED unused*/ (void)status; FREE(data); RETURNV(); diff --git a/external/bsd/openpam/dist/lib/openpam_free_envlist.c b/external/bsd/openpam/dist/lib/openpam_free_envlist.c index 081cf6ea499b..47cffbb1f435 100644 --- a/external/bsd/openpam/dist/lib/openpam_free_envlist.c +++ b/external/bsd/openpam/dist/lib/openpam_free_envlist.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_free_envlist.c,v 1.1.1.1 2011/12/25 21:42:49 christos Exp $ */ +/* $NetBSD: openpam_free_envlist.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2005-2011 Dag-Erling Smørgrav diff --git a/external/bsd/openpam/dist/lib/openpam_get_option.c b/external/bsd/openpam/dist/lib/openpam_get_option.c index 9c58f4fb7b17..4c040b9f8e20 100644 --- a/external/bsd/openpam/dist/lib/openpam_get_option.c +++ b/external/bsd/openpam/dist/lib/openpam_get_option.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_get_option.c,v 1.1.1.1 2011/12/25 21:42:49 christos Exp $ */ +/* $NetBSD: openpam_get_option.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -78,6 +78,7 @@ openpam_get_option(pam_handle_t *pamh, } } RETURNS(NULL); + /*NOTREACHED*/ } /** diff --git a/external/bsd/openpam/dist/lib/openpam_impl.h b/external/bsd/openpam/dist/lib/openpam_impl.h index 4737040db4e9..463fac2eed58 100644 --- a/external/bsd/openpam/dist/lib/openpam_impl.h +++ b/external/bsd/openpam/dist/lib/openpam_impl.h @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_impl.h,v 1.1.1.1 2011/12/25 21:42:48 christos Exp $ */ +/* $NetBSD: openpam_impl.h,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2001-2003 Networks Associates Technology, Inc. @@ -159,7 +159,7 @@ pam_module_t *openpam_static(const char *); #endif pam_module_t *openpam_dynamic(const char *); -#define FREE(p) do { free((p)); (p) = NULL; } while (0) +#define FREE(p) do { free((p)); (p) = NULL; } while (/*CONSTCOND*/0) #include "openpam_constants.h" #include "openpam_debug.h" diff --git a/external/bsd/openpam/dist/lib/openpam_load.c b/external/bsd/openpam/dist/lib/openpam_load.c index f5dcbd58bc71..a92e803c4d68 100644 --- a/external/bsd/openpam/dist/lib/openpam_load.c +++ b/external/bsd/openpam/dist/lib/openpam_load.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_load.c,v 1.1.1.1 2011/12/25 21:42:49 christos Exp $ */ +/* $NetBSD: openpam_load.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/openpam_log.c b/external/bsd/openpam/dist/lib/openpam_log.c index c1b93bf04a85..570df454ed15 100644 --- a/external/bsd/openpam/dist/lib/openpam_log.c +++ b/external/bsd/openpam/dist/lib/openpam_log.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_log.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: openpam_log.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/openpam_nullconv.c b/external/bsd/openpam/dist/lib/openpam_nullconv.c index 3ee7b5f3c32a..63f583ae075e 100644 --- a/external/bsd/openpam/dist/lib/openpam_nullconv.c +++ b/external/bsd/openpam/dist/lib/openpam_nullconv.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_nullconv.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: openpam_nullconv.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -61,11 +61,16 @@ openpam_nullconv(int n, { ENTER(); + /*LINTED unused*/ (void)n; + /*LINTED unused*/ (void)msg; + /*LINTED unused*/ (void)resp; + /*LINTED unused*/ (void)data; RETURNC(PAM_CONV_ERR); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/openpam_readline.c b/external/bsd/openpam/dist/lib/openpam_readline.c index ae44b4383b0d..332406b6a6a7 100644 --- a/external/bsd/openpam/dist/lib/openpam_readline.c +++ b/external/bsd/openpam/dist/lib/openpam_readline.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_readline.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: openpam_readline.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2003 Networks Associates Technology, Inc. @@ -63,7 +63,7 @@ openpam_readline(FILE *f, int *lineno, size_t *lenp) size_t len, size; int ch; - if ((line = malloc(MIN_LINE_LENGTH)) == NULL) + if ((line = malloc((size_t)MIN_LINE_LENGTH)) == NULL) return (NULL); size = MIN_LINE_LENGTH; len = 0; @@ -77,7 +77,7 @@ openpam_readline(FILE *f, int *lineno, size_t *lenp) } \ line[len++] = ch; \ line[len] = '\0'; \ -} while (0) +} while (/*CONSTCOND*/0) for (;;) { ch = fgetc(f); @@ -108,7 +108,7 @@ openpam_readline(FILE *f, int *lineno, size_t *lenp) break; } /* whitespace */ - if (isspace(ch)) { + if (isspace((unsigned char)ch)) { /* ignore leading whitespace */ /* collapse linear whitespace */ if (len > 0 && line[len - 1] != ' ') diff --git a/external/bsd/openpam/dist/lib/openpam_restore_cred.c b/external/bsd/openpam/dist/lib/openpam_restore_cred.c index 2a8ea031b3fe..9c27a7fe73a2 100644 --- a/external/bsd/openpam/dist/lib/openpam_restore_cred.c +++ b/external/bsd/openpam/dist/lib/openpam_restore_cred.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_restore_cred.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: openpam_restore_cred.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -81,6 +81,7 @@ openpam_restore_cred(pam_handle_t *pamh) } pam_set_data(pamh, PAM_SAVED_CRED, NULL, NULL); RETURNC(PAM_SUCCESS); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/openpam_set_option.c b/external/bsd/openpam/dist/lib/openpam_set_option.c index 5dd48e148a13..57f5b9afb366 100644 --- a/external/bsd/openpam/dist/lib/openpam_set_option.c +++ b/external/bsd/openpam/dist/lib/openpam_set_option.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_set_option.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: openpam_set_option.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -108,6 +108,7 @@ openpam_set_option(pam_handle_t *pamh, cur->optv[i] = opt; } RETURNC(PAM_SUCCESS); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/openpam_static.c b/external/bsd/openpam/dist/lib/openpam_static.c index 80026e7297c7..0ae8a2943409 100644 --- a/external/bsd/openpam/dist/lib/openpam_static.c +++ b/external/bsd/openpam/dist/lib/openpam_static.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_static.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: openpam_static.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -60,7 +60,7 @@ SET_DECLARE(openpam_static_modules, pam_module_t); pam_module_t * openpam_static(const char *path) { - pam_module_t **module; + pam_module_t * const *module; SET_FOREACH(module, openpam_static_modules) { if (strcmp((*module)->path, path) == 0) @@ -69,7 +69,7 @@ openpam_static(const char *path) return (NULL); } -#endif +#endif /* OPENPAM_STATIC_MODULES */ /* * NOPARSE diff --git a/external/bsd/openpam/dist/lib/openpam_strlcmp.h b/external/bsd/openpam/dist/lib/openpam_strlcmp.h index 27bf915bf20a..7ef5b6d803a0 100644 --- a/external/bsd/openpam/dist/lib/openpam_strlcmp.h +++ b/external/bsd/openpam/dist/lib/openpam_strlcmp.h @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_strlcmp.h,v 1.1.1.1 2011/12/25 21:42:48 christos Exp $ */ +/* $NetBSD: openpam_strlcmp.h,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2011 Dag-Erling Smørgrav diff --git a/external/bsd/openpam/dist/lib/openpam_strlcpy.h b/external/bsd/openpam/dist/lib/openpam_strlcpy.h index 6ab9de7b6e9a..043cc722dd82 100644 --- a/external/bsd/openpam/dist/lib/openpam_strlcpy.h +++ b/external/bsd/openpam/dist/lib/openpam_strlcpy.h @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_strlcpy.h,v 1.1.1.1 2011/12/25 21:42:48 christos Exp $ */ +/* $NetBSD: openpam_strlcpy.h,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2011 Dag-Erling Smørgrav diff --git a/external/bsd/openpam/dist/lib/openpam_subst.c b/external/bsd/openpam/dist/lib/openpam_subst.c index b7c04649a2fb..b2f82d73eeb0 100644 --- a/external/bsd/openpam/dist/lib/openpam_subst.c +++ b/external/bsd/openpam/dist/lib/openpam_subst.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_subst.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: openpam_subst.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2011 Dag-Erling Smørgrav @@ -42,13 +42,13 @@ if (buf && len < *bufsize) \ *buf++ = ch_; \ ++len; \ -} while (0) +} while (/*CONSTCOND*/0) #define subst_string(s) do { \ const char *s_ = (s); \ while (*s_) \ subst_char(*s_++); \ -} while (0) +} while (/*CONSTCOND*/0) #define subst_item(i) do { \ int i_ = (i); \ @@ -56,7 +56,7 @@ ret = pam_get_item(pamh, i_, &p_); \ if (ret == PAM_SUCCESS && p_ != NULL) \ subst_string(p_); \ -} while (0) +} while (/*CONSTCOND*/0) /* * OpenPAM internal diff --git a/external/bsd/openpam/dist/lib/openpam_ttyconv.c b/external/bsd/openpam/dist/lib/openpam_ttyconv.c index defacea492ea..8d304c79b2ff 100644 --- a/external/bsd/openpam/dist/lib/openpam_ttyconv.c +++ b/external/bsd/openpam/dist/lib/openpam_ttyconv.c @@ -1,4 +1,4 @@ -/* $NetBSD: openpam_ttyconv.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: openpam_ttyconv.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -52,6 +52,7 @@ #include #include #include +#include #include @@ -62,44 +63,47 @@ int openpam_ttyconv_timeout = 0; static void timeout(int sig) { - + /*LINTED unused*/ (void)sig; } static char * -prompt(const char *msg) +prompt(const char *msg, FILE *infp, FILE *outfp, FILE *errfp) { char buf[PAM_MAX_RESP_SIZE]; struct sigaction action, saved_action; - sigset_t saved_sigset, sigset; + sigset_t saved_sigset, sigs; unsigned int saved_alarm; int eof, error, fd; size_t len; char *retval; char ch; - sigemptyset(&sigset); - sigaddset(&sigset, SIGINT); - sigaddset(&sigset, SIGTSTP); - sigprocmask(SIG_SETMASK, &sigset, &saved_sigset); + saved_alarm = 0; + sigemptyset(&sigs); + sigaddset(&sigs, SIGINT); + sigaddset(&sigs, SIGTSTP); + sigprocmask(SIG_SETMASK, &sigs, &saved_sigset); action.sa_handler = &timeout; action.sa_flags = 0; sigemptyset(&action.sa_mask); sigaction(SIGALRM, &action, &saved_action); - fputs(msg, stdout); - fflush(stdout); + + + fputs(msg, outfp); + fflush(outfp); #ifdef HAVE_FPURGE - fpurge(stdin); + fpurge(infp); #endif - fd = fileno(stdin); + fd = fileno(infp); buf[0] = '\0'; eof = error = 0; saved_alarm = 0; if (openpam_ttyconv_timeout >= 0) - saved_alarm = alarm(openpam_ttyconv_timeout); + saved_alarm = alarm((unsigned int)openpam_ttyconv_timeout); ch = '\0'; for (len = 0; ch != '\n' && !eof && !error; ++len) { - switch (read(fd, &ch, 1)) { + switch (read(fd, &ch, (size_t)1)) { case 1: if (len < PAM_MAX_RESP_SIZE - 1) { buf[len + 1] = '\0'; @@ -121,9 +125,9 @@ prompt(const char *msg) if (saved_alarm > 0) alarm(saved_alarm); if (error == EINTR) - fputs(" timeout!", stderr); + fputs(" timeout!", errfp); if (error || eof) { - fputs("\n", stderr); + fputs("\n", errfp); memset(buf, 0, sizeof(buf)); return (NULL); } @@ -138,14 +142,14 @@ prompt(const char *msg) } static char * -prompt_echo_off(const char *msg) +prompt_echo_off(const char *msg, FILE *infp, FILE *outfp, FILE *errfp) { struct termios tattr; tcflag_t lflag; char *ret; int fd; - fd = fileno(stdin); + fd = fileno(infp); if (tcgetattr(fd, &tattr) != 0) { openpam_log(PAM_LOG_ERROR, "tcgetattr(): %m"); return (NULL); @@ -156,11 +160,11 @@ prompt_echo_off(const char *msg) openpam_log(PAM_LOG_ERROR, "tcsetattr(): %m"); return (NULL); } - ret = prompt(msg); + ret = prompt(msg, infp, outfp, errfp); tattr.c_lflag = lflag; (void)tcsetattr(fd, TCSANOW, &tattr); if (ret != NULL) - fputs("\n", stdout); + fputs("\n", outfp); return (ret); } @@ -178,43 +182,59 @@ openpam_ttyconv(int n, { struct pam_response *aresp; int i; + FILE *infp, *outfp, *errfp; ENTER(); + /*LINTED unused*/ (void)data; if (n <= 0 || n > PAM_MAX_NUM_MSG) RETURNC(PAM_CONV_ERR); - if ((aresp = calloc(n, sizeof *aresp)) == NULL) + if ((aresp = calloc((size_t)n, sizeof *aresp)) == NULL) RETURNC(PAM_BUF_ERR); + + /* + * read and write to /dev/tty if possible; else read from + * stdin and write to stderr. + */ + if ((outfp = infp = errfp = fopen(_PATH_TTY, "w+")) == NULL) { + errfp = stderr; + outfp = stderr; + infp = stdin; + } + for (i = 0; i < n; ++i) { aresp[i].resp_retcode = 0; aresp[i].resp = NULL; switch (msg[i]->msg_style) { case PAM_PROMPT_ECHO_OFF: - aresp[i].resp = prompt_echo_off(msg[i]->msg); + aresp[i].resp = prompt_echo_off(msg[i]->msg, infp, + outfp, errfp); if (aresp[i].resp == NULL) goto fail; break; case PAM_PROMPT_ECHO_ON: - aresp[i].resp = prompt(msg[i]->msg); + aresp[i].resp = prompt(msg[i]->msg, infp, outfp, errfp); if (aresp[i].resp == NULL) goto fail; break; case PAM_ERROR_MSG: - fputs(msg[i]->msg, stderr); + fputs(msg[i]->msg, errfp); if (strlen(msg[i]->msg) > 0 && msg[i]->msg[strlen(msg[i]->msg) - 1] != '\n') - fputc('\n', stderr); + fputc('\n', errfp); break; case PAM_TEXT_INFO: - fputs(msg[i]->msg, stdout); + fputs(msg[i]->msg, outfp); if (strlen(msg[i]->msg) > 0 && msg[i]->msg[strlen(msg[i]->msg) - 1] != '\n') - fputc('\n', stdout); + fputc('\n', outfp); break; default: goto fail; } } + if (infp != stdin) + (void)fclose(infp); *resp = aresp; RETURNC(PAM_SUCCESS); fail: @@ -224,10 +244,13 @@ fail: FREE(aresp[i].resp); } } + if (infp != stdin) + (void)fclose(infp); memset(aresp, 0, n * sizeof *aresp); FREE(aresp); *resp = NULL; RETURNC(PAM_CONV_ERR); + /*NOTREACHED*/ } /* @@ -244,6 +267,11 @@ fail: * It should be adequate for the needs of most text-based interactive * programs. * + * The =openpam_ttyconv function displays a prompt to, and reads in a + * password from /dev/tty. If this file is not accessible, =openpam_ttyconv + * displays the prompt on the standard error output and reads from the + * standard input. + * * The =openpam_ttyconv function allows the application to specify a * timeout for user input by setting the global integer variable * :openpam_ttyconv_timeout to the length of the timeout in seconds. @@ -251,4 +279,5 @@ fail: * >openpam_nullconv * >pam_prompt * >pam_vprompt + * >getpass */ diff --git a/external/bsd/openpam/dist/lib/pam_acct_mgmt.c b/external/bsd/openpam/dist/lib/pam_acct_mgmt.c index 428fdc1d3574..dec8cd3fd43b 100644 --- a/external/bsd/openpam/dist/lib/pam_acct_mgmt.c +++ b/external/bsd/openpam/dist/lib/pam_acct_mgmt.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_acct_mgmt.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: pam_acct_mgmt.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -63,6 +63,7 @@ pam_acct_mgmt(pam_handle_t *pamh, ENTER(); r = openpam_dispatch(pamh, PAM_SM_ACCT_MGMT, flags); RETURNC(r); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/pam_authenticate.c b/external/bsd/openpam/dist/lib/pam_authenticate.c index 75ee446a7bb7..92be9b5e9b1c 100644 --- a/external/bsd/openpam/dist/lib/pam_authenticate.c +++ b/external/bsd/openpam/dist/lib/pam_authenticate.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_authenticate.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: pam_authenticate.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -66,6 +66,7 @@ pam_authenticate(pam_handle_t *pamh, r = openpam_dispatch(pamh, PAM_SM_AUTHENTICATE, flags); pam_set_item(pamh, PAM_AUTHTOK, NULL); RETURNC(r); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/pam_authenticate_secondary.c b/external/bsd/openpam/dist/lib/pam_authenticate_secondary.c index 1b17e5620420..77a0edb2ea2f 100644 --- a/external/bsd/openpam/dist/lib/pam_authenticate_secondary.c +++ b/external/bsd/openpam/dist/lib/pam_authenticate_secondary.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_authenticate_secondary.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_authenticate_secondary.c,v 1.2 2011/12/25 22:27:55 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_chauthtok.c b/external/bsd/openpam/dist/lib/pam_chauthtok.c index 608adb2b21bb..64a13f48bbd2 100644 --- a/external/bsd/openpam/dist/lib/pam_chauthtok.c +++ b/external/bsd/openpam/dist/lib/pam_chauthtok.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_chauthtok.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: pam_chauthtok.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -71,6 +71,7 @@ pam_chauthtok(pam_handle_t *pamh, pam_set_item(pamh, PAM_OLDAUTHTOK, NULL); pam_set_item(pamh, PAM_AUTHTOK, NULL); RETURNC(r); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/pam_close_session.c b/external/bsd/openpam/dist/lib/pam_close_session.c index 928324737753..bad2b46b86c5 100644 --- a/external/bsd/openpam/dist/lib/pam_close_session.c +++ b/external/bsd/openpam/dist/lib/pam_close_session.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_close_session.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: pam_close_session.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -65,6 +65,7 @@ pam_close_session(pam_handle_t *pamh, RETURNC(PAM_SYMBOL_ERR); r = openpam_dispatch(pamh, PAM_SM_CLOSE_SESSION, flags); RETURNC(r); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/pam_end.c b/external/bsd/openpam/dist/lib/pam_end.c index d48ff71a6701..f55b6e803f32 100644 --- a/external/bsd/openpam/dist/lib/pam_end.c +++ b/external/bsd/openpam/dist/lib/pam_end.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_end.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: pam_end.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -91,6 +91,7 @@ pam_end(pam_handle_t *pamh, FREE(pamh); RETURNC(PAM_SUCCESS); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/pam_error.c b/external/bsd/openpam/dist/lib/pam_error.c index fd19d17eae14..cd3f752cf056 100644 --- a/external/bsd/openpam/dist/lib/pam_error.c +++ b/external/bsd/openpam/dist/lib/pam_error.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_error.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: pam_error.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_get_authtok.c b/external/bsd/openpam/dist/lib/pam_get_authtok.c index c2d2df4ccc67..2e62c6f92713 100644 --- a/external/bsd/openpam/dist/lib/pam_get_authtok.c +++ b/external/bsd/openpam/dist/lib/pam_get_authtok.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_get_authtok.c,v 1.1.1.1 2011/12/25 21:42:50 christos Exp $ */ +/* $NetBSD: pam_get_authtok.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -132,21 +132,27 @@ pam_get_authtok(pam_handle_t *pamh, if (twice) { r = pam_prompt(pamh, style, &resp2, "Retype %s", prompt); if (r != PAM_SUCCESS) { + memset(resp, 0, strlen(resp)); FREE(resp); RETURNC(r); } - if (strcmp(resp, resp2) != 0) + if (strcmp(resp, resp2) != 0) { + memset(resp, 0, strlen(resp)); FREE(resp); + } + memset(resp2, 0, strlen(resp2)); FREE(resp2); } if (resp == NULL) RETURNC(PAM_TRY_AGAIN); r = pam_set_item(pamh, item, resp); + memset(resp, 0, strlen(resp)); FREE(resp); if (r != PAM_SUCCESS) RETURNC(r); r = pam_get_item(pamh, item, (const void **)authtok); RETURNC(r); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/pam_get_data.c b/external/bsd/openpam/dist/lib/pam_get_data.c index b92dff1dfc50..62e7bad707b4 100644 --- a/external/bsd/openpam/dist/lib/pam_get_data.c +++ b/external/bsd/openpam/dist/lib/pam_get_data.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_get_data.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_get_data.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -71,6 +71,7 @@ pam_get_data(const pam_handle_t *pamh, } } RETURNC(PAM_NO_MODULE_DATA); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/pam_get_item.c b/external/bsd/openpam/dist/lib/pam_get_item.c index 13e6e55d9515..535d3fbeeb8a 100644 --- a/external/bsd/openpam/dist/lib/pam_get_item.c +++ b/external/bsd/openpam/dist/lib/pam_get_item.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_get_item.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_get_item.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -77,10 +77,14 @@ pam_get_item(const pam_handle_t *pamh, case PAM_AUTHTOK_PROMPT: case PAM_OLDAUTHTOK_PROMPT: case PAM_HOST: + case PAM_SOCKADDR: + case PAM_NUSER: *item = pamh->item[item_type]; RETURNC(PAM_SUCCESS); + /*NOTREACHED*/ default: RETURNC(PAM_SYMBOL_ERR); + /*NOTREACHED*/ } } @@ -130,6 +134,10 @@ pam_get_item(const pam_handle_t *pamh, * expired authentication token prior to changing it. * =PAM_HOST: * The name of the host the application runs on. + * =PAM_SOCKADDR: + * The sockaddr_storage of the applicants's host. + * =PAM_NUSER: + * The "nested" user if this is a login on top of a previous one. * * See =pam_start for a description of =struct pam_conv. * diff --git a/external/bsd/openpam/dist/lib/pam_get_mapped_authtok.c b/external/bsd/openpam/dist/lib/pam_get_mapped_authtok.c index e3fc12055f69..d497e51d672e 100644 --- a/external/bsd/openpam/dist/lib/pam_get_mapped_authtok.c +++ b/external/bsd/openpam/dist/lib/pam_get_mapped_authtok.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_get_mapped_authtok.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_get_mapped_authtok.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_get_mapped_username.c b/external/bsd/openpam/dist/lib/pam_get_mapped_username.c index 74a06fdba51a..40c903b149d2 100644 --- a/external/bsd/openpam/dist/lib/pam_get_mapped_username.c +++ b/external/bsd/openpam/dist/lib/pam_get_mapped_username.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_get_mapped_username.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_get_mapped_username.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_get_user.c b/external/bsd/openpam/dist/lib/pam_get_user.c index 725b1aa181a8..8b768d4e616d 100644 --- a/external/bsd/openpam/dist/lib/pam_get_user.c +++ b/external/bsd/openpam/dist/lib/pam_get_user.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_get_user.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_get_user.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -101,6 +101,7 @@ pam_get_user(pam_handle_t *pamh, RETURNC(r); r = pam_get_item(pamh, PAM_USER, (const void **)user); RETURNC(r); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/pam_getenv.c b/external/bsd/openpam/dist/lib/pam_getenv.c index 6abb51bdfdd9..4fc9f644d68c 100644 --- a/external/bsd/openpam/dist/lib/pam_getenv.c +++ b/external/bsd/openpam/dist/lib/pam_getenv.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_getenv.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_getenv.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -76,6 +76,7 @@ pam_getenv(pam_handle_t *pamh, } } RETURNS(str); + /*NOTREACHED*/ } /** diff --git a/external/bsd/openpam/dist/lib/pam_getenvlist.c b/external/bsd/openpam/dist/lib/pam_getenvlist.c index 875f4908bbd6..5f5d9b1136a2 100644 --- a/external/bsd/openpam/dist/lib/pam_getenvlist.c +++ b/external/bsd/openpam/dist/lib/pam_getenvlist.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_getenvlist.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_getenvlist.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -84,6 +84,7 @@ pam_getenvlist(pam_handle_t *pamh) } envlist[i] = NULL; RETURNP(envlist); + /*NOTREACHED*/ } /** diff --git a/external/bsd/openpam/dist/lib/pam_info.c b/external/bsd/openpam/dist/lib/pam_info.c index dd07b8f1588b..73be74a0f5ba 100644 --- a/external/bsd/openpam/dist/lib/pam_info.c +++ b/external/bsd/openpam/dist/lib/pam_info.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_info.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_info.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_open_session.c b/external/bsd/openpam/dist/lib/pam_open_session.c index 38f59f262852..e69396aa9fad 100644 --- a/external/bsd/openpam/dist/lib/pam_open_session.c +++ b/external/bsd/openpam/dist/lib/pam_open_session.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_open_session.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_open_session.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -65,6 +65,7 @@ pam_open_session(pam_handle_t *pamh, RETURNC(PAM_SYMBOL_ERR); r = openpam_dispatch(pamh, PAM_SM_OPEN_SESSION, flags); RETURNC(r); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/pam_prompt.c b/external/bsd/openpam/dist/lib/pam_prompt.c index 4c077bc3f4fd..3de8d5e0f089 100644 --- a/external/bsd/openpam/dist/lib/pam_prompt.c +++ b/external/bsd/openpam/dist/lib/pam_prompt.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_prompt.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_prompt.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_putenv.c b/external/bsd/openpam/dist/lib/pam_putenv.c index 25337d8d13bd..313f496f8c23 100644 --- a/external/bsd/openpam/dist/lib/pam_putenv.c +++ b/external/bsd/openpam/dist/lib/pam_putenv.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_putenv.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_putenv.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -71,7 +71,8 @@ pam_putenv(pam_handle_t *pamh, RETURNC(PAM_SYSTEM_ERR); /* see if the variable is already in the environment */ - if ((i = openpam_findenv(pamh, namevalue, p - namevalue)) >= 0) { + if ((i = openpam_findenv(pamh, namevalue, + (size_t)(p - namevalue))) >= 0) { if ((p = strdup(namevalue)) == NULL) RETURNC(PAM_BUF_ERR); FREE(pamh->env[i]); @@ -94,6 +95,7 @@ pam_putenv(pam_handle_t *pamh, RETURNC(PAM_BUF_ERR); ++pamh->env_count; RETURNC(PAM_SUCCESS); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/pam_set_data.c b/external/bsd/openpam/dist/lib/pam_set_data.c index 22587c3f671d..27cf15c64cd8 100644 --- a/external/bsd/openpam/dist/lib/pam_set_data.c +++ b/external/bsd/openpam/dist/lib/pam_set_data.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_set_data.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_set_data.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -88,6 +88,7 @@ pam_set_data(pam_handle_t *pamh, dp->next = pamh->module_data; pamh->module_data = dp; RETURNC(PAM_SUCCESS); + /*NOTREACHED*/ } /* @@ -107,4 +108,6 @@ pam_set_data(pam_handle_t *pamh, * * This function and its counterpart =pam_get_data are useful for managing * data that are meaningful only to a particular service module. + * + * >openpam_free_data */ diff --git a/external/bsd/openpam/dist/lib/pam_set_item.c b/external/bsd/openpam/dist/lib/pam_set_item.c index 28bf0065dcb4..4fff714568c0 100644 --- a/external/bsd/openpam/dist/lib/pam_set_item.c +++ b/external/bsd/openpam/dist/lib/pam_set_item.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_set_item.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_set_item.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -86,6 +86,7 @@ pam_set_item(pam_handle_t *pamh, case PAM_AUTHTOK_PROMPT: case PAM_OLDAUTHTOK_PROMPT: case PAM_HOST: + case PAM_NUSER: if (*slot != NULL) osize = strlen(*slot) + 1; if (item != NULL) @@ -97,6 +98,9 @@ pam_set_item(pam_handle_t *pamh, case PAM_CONV: osize = nsize = sizeof(struct pam_conv); break; + case PAM_SOCKADDR: + osize = nsize = sizeof(struct sockaddr_storage); + break; default: RETURNC(PAM_SYMBOL_ERR); } @@ -113,6 +117,7 @@ pam_set_item(pam_handle_t *pamh, } *slot = tmp; RETURNC(PAM_SUCCESS); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/pam_set_mapped_authtok.c b/external/bsd/openpam/dist/lib/pam_set_mapped_authtok.c index fe8e7e6f72ae..2de296bffdde 100644 --- a/external/bsd/openpam/dist/lib/pam_set_mapped_authtok.c +++ b/external/bsd/openpam/dist/lib/pam_set_mapped_authtok.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_set_mapped_authtok.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_set_mapped_authtok.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_set_mapped_username.c b/external/bsd/openpam/dist/lib/pam_set_mapped_username.c index cb16478480e6..6e095181898c 100644 --- a/external/bsd/openpam/dist/lib/pam_set_mapped_username.c +++ b/external/bsd/openpam/dist/lib/pam_set_mapped_username.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_set_mapped_username.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_set_mapped_username.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_setcred.c b/external/bsd/openpam/dist/lib/pam_setcred.c index e7f13ae525b6..fc6bdc979069 100644 --- a/external/bsd/openpam/dist/lib/pam_setcred.c +++ b/external/bsd/openpam/dist/lib/pam_setcred.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_setcred.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_setcred.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -67,6 +67,7 @@ pam_setcred(pam_handle_t *pamh, /* XXX enforce exclusivity */ r = openpam_dispatch(pamh, PAM_SM_SETCRED, flags); RETURNC(r); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/pam_setenv.c b/external/bsd/openpam/dist/lib/pam_setenv.c index d51bb5d4722c..3185504b3ef5 100644 --- a/external/bsd/openpam/dist/lib/pam_setenv.c +++ b/external/bsd/openpam/dist/lib/pam_setenv.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_setenv.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_setenv.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -83,6 +83,7 @@ pam_setenv(pam_handle_t *pamh, r = pam_putenv(pamh, env); FREE(env); RETURNC(r); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/pam_sm_acct_mgmt.c b/external/bsd/openpam/dist/lib/pam_sm_acct_mgmt.c index 5e1ed45a2f6b..3ec6e1b85a30 100644 --- a/external/bsd/openpam/dist/lib/pam_sm_acct_mgmt.c +++ b/external/bsd/openpam/dist/lib/pam_sm_acct_mgmt.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_sm_acct_mgmt.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_sm_acct_mgmt.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_sm_authenticate.c b/external/bsd/openpam/dist/lib/pam_sm_authenticate.c index 521ed54169a6..5c25b044d29a 100644 --- a/external/bsd/openpam/dist/lib/pam_sm_authenticate.c +++ b/external/bsd/openpam/dist/lib/pam_sm_authenticate.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_sm_authenticate.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_sm_authenticate.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_sm_authenticate_secondary.c b/external/bsd/openpam/dist/lib/pam_sm_authenticate_secondary.c index 47ae58e1dd58..184eceaf76b5 100644 --- a/external/bsd/openpam/dist/lib/pam_sm_authenticate_secondary.c +++ b/external/bsd/openpam/dist/lib/pam_sm_authenticate_secondary.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_sm_authenticate_secondary.c,v 1.1.1.1 2011/12/25 21:42:49 christos Exp $ */ +/* $NetBSD: pam_sm_authenticate_secondary.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_sm_chauthtok.c b/external/bsd/openpam/dist/lib/pam_sm_chauthtok.c index f7d05cd3f90c..0a8b04713e07 100644 --- a/external/bsd/openpam/dist/lib/pam_sm_chauthtok.c +++ b/external/bsd/openpam/dist/lib/pam_sm_chauthtok.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_sm_chauthtok.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_sm_chauthtok.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_sm_close_session.c b/external/bsd/openpam/dist/lib/pam_sm_close_session.c index 9d8baa10180b..f0251910da18 100644 --- a/external/bsd/openpam/dist/lib/pam_sm_close_session.c +++ b/external/bsd/openpam/dist/lib/pam_sm_close_session.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_sm_close_session.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_sm_close_session.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_sm_get_mapped_authtok.c b/external/bsd/openpam/dist/lib/pam_sm_get_mapped_authtok.c index b1c99b8492ea..ea3647cd1ab7 100644 --- a/external/bsd/openpam/dist/lib/pam_sm_get_mapped_authtok.c +++ b/external/bsd/openpam/dist/lib/pam_sm_get_mapped_authtok.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_sm_get_mapped_authtok.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_sm_get_mapped_authtok.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_sm_get_mapped_username.c b/external/bsd/openpam/dist/lib/pam_sm_get_mapped_username.c index b04ba4837ab3..581dc72bf36c 100644 --- a/external/bsd/openpam/dist/lib/pam_sm_get_mapped_username.c +++ b/external/bsd/openpam/dist/lib/pam_sm_get_mapped_username.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_sm_get_mapped_username.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_sm_get_mapped_username.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_sm_open_session.c b/external/bsd/openpam/dist/lib/pam_sm_open_session.c index 76101e759832..7936ad70f4ea 100644 --- a/external/bsd/openpam/dist/lib/pam_sm_open_session.c +++ b/external/bsd/openpam/dist/lib/pam_sm_open_session.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_sm_open_session.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_sm_open_session.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_sm_set_mapped_authtok.c b/external/bsd/openpam/dist/lib/pam_sm_set_mapped_authtok.c index ee3dcc6f645d..02d7917ed52f 100644 --- a/external/bsd/openpam/dist/lib/pam_sm_set_mapped_authtok.c +++ b/external/bsd/openpam/dist/lib/pam_sm_set_mapped_authtok.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_sm_set_mapped_authtok.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_sm_set_mapped_authtok.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_sm_set_mapped_username.c b/external/bsd/openpam/dist/lib/pam_sm_set_mapped_username.c index 3c54311c2b73..c7feb7af81ed 100644 --- a/external/bsd/openpam/dist/lib/pam_sm_set_mapped_username.c +++ b/external/bsd/openpam/dist/lib/pam_sm_set_mapped_username.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_sm_set_mapped_username.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_sm_set_mapped_username.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_sm_setcred.c b/external/bsd/openpam/dist/lib/pam_sm_setcred.c index 7b0445c7683b..4c15d0d1685e 100644 --- a/external/bsd/openpam/dist/lib/pam_sm_setcred.c +++ b/external/bsd/openpam/dist/lib/pam_sm_setcred.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_sm_setcred.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_sm_setcred.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_start.c b/external/bsd/openpam/dist/lib/pam_start.c index f02b2c326b96..c2f2b83ae854 100644 --- a/external/bsd/openpam/dist/lib/pam_start.c +++ b/external/bsd/openpam/dist/lib/pam_start.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_start.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_start.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -74,7 +74,7 @@ pam_start(const char *service, int r; ENTER(); - if ((ph = calloc(1, sizeof *ph)) == NULL) + if ((ph = calloc((size_t)1, sizeof *ph)) == NULL) RETURNC(PAM_BUF_ERR); if ((r = pam_set_item(ph, PAM_SERVICE, service)) != PAM_SUCCESS) goto fail; @@ -94,6 +94,7 @@ pam_start(const char *service, fail: pam_end(ph, r); RETURNC(r); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/lib/pam_strerror.c b/external/bsd/openpam/dist/lib/pam_strerror.c index 12be79c701c1..cf713d5298b7 100644 --- a/external/bsd/openpam/dist/lib/pam_strerror.c +++ b/external/bsd/openpam/dist/lib/pam_strerror.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_strerror.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_strerror.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -60,6 +60,7 @@ pam_strerror(const pam_handle_t *pamh, { static char unknown[16]; + /*LINTED unused*/ (void)pamh; switch (error_number) { diff --git a/external/bsd/openpam/dist/lib/pam_verror.c b/external/bsd/openpam/dist/lib/pam_verror.c index ff8c2fd33c25..f183094a5117 100644 --- a/external/bsd/openpam/dist/lib/pam_verror.c +++ b/external/bsd/openpam/dist/lib/pam_verror.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_verror.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_verror.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_vinfo.c b/external/bsd/openpam/dist/lib/pam_vinfo.c index b2507898c1fd..f414f12d0d0a 100644 --- a/external/bsd/openpam/dist/lib/pam_vinfo.c +++ b/external/bsd/openpam/dist/lib/pam_vinfo.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_vinfo.c,v 1.1.1.1 2011/12/25 21:42:51 christos Exp $ */ +/* $NetBSD: pam_vinfo.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/lib/pam_vprompt.c b/external/bsd/openpam/dist/lib/pam_vprompt.c index 4579729f7448..0e5e574494ef 100644 --- a/external/bsd/openpam/dist/lib/pam_vprompt.c +++ b/external/bsd/openpam/dist/lib/pam_vprompt.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_vprompt.c,v 1.1.1.1 2011/12/25 21:42:52 christos Exp $ */ +/* $NetBSD: pam_vprompt.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. @@ -79,7 +79,7 @@ pam_vprompt(const pam_handle_t *pamh, openpam_log(PAM_LOG_ERROR, "no conversation function"); RETURNC(PAM_SYSTEM_ERR); } - vsnprintf(msgbuf, PAM_MAX_MSG_SIZE, fmt, ap); + vsnprintf(msgbuf, (size_t)PAM_MAX_MSG_SIZE, fmt, ap); msg.msg_style = style; msg.msg = msgbuf; msgp = &msg; @@ -88,6 +88,7 @@ pam_vprompt(const pam_handle_t *pamh, *resp = rsp == NULL ? NULL : rsp->resp; FREE(rsp); RETURNC(r); + /*NOTREACHED*/ } /* diff --git a/external/bsd/openpam/dist/misc/gendoc.pl b/external/bsd/openpam/dist/misc/gendoc.pl index 550f3ee4f22a..af317c9b25da 100644 --- a/external/bsd/openpam/dist/misc/gendoc.pl +++ b/external/bsd/openpam/dist/misc/gendoc.pl @@ -291,6 +291,7 @@ sub parse_source($) { s/\s*=(struct \w+(?: \*)?)\b\s*/\n.Vt $1\n/gs; s/\s*:([a-z_]+)\b\s*/\n.Va $1\n/gs; s/\s*;([a-z_]+)\b\s*/\n.Dv $1\n/gs; + s/\s*=cleanup\s*/\n.Ar cleanup\n/gs; while (s/\s*=([a-z_]+)\b\s*/\n.Xr $1 3\n/s) { ++$xref{3}->{$1}; } @@ -426,7 +427,10 @@ sub gendoc($) { return if defined($func->{'nodoc'}); - $mdoc = "$COPYRIGHT + $mdoc = ".\\\"\t\$". +"NetBSD\$ +.\\\" +$COPYRIGHT .Dd $TODAY .Dt " . uc($func->{'name'}) . " 3 .Os diff --git a/external/bsd/openpam/dist/modules/pam_deny/pam_deny.c b/external/bsd/openpam/dist/modules/pam_deny/pam_deny.c index f0b4bb740d99..67d85ff34eb7 100644 --- a/external/bsd/openpam/dist/modules/pam_deny/pam_deny.c +++ b/external/bsd/openpam/dist/modules/pam_deny/pam_deny.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_deny.c,v 1.1.1.1 2011/12/25 21:42:54 christos Exp $ */ +/* $NetBSD: pam_deny.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/modules/pam_permit/pam_permit.c b/external/bsd/openpam/dist/modules/pam_permit/pam_permit.c index e3ed9beb3293..cfd16179fe13 100644 --- a/external/bsd/openpam/dist/modules/pam_permit/pam_permit.c +++ b/external/bsd/openpam/dist/modules/pam_permit/pam_permit.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_permit.c,v 1.1.1.1 2011/12/25 21:42:55 christos Exp $ */ +/* $NetBSD: pam_permit.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc. diff --git a/external/bsd/openpam/dist/modules/pam_unix/pam_unix.c b/external/bsd/openpam/dist/modules/pam_unix/pam_unix.c index 3ae19c2e538e..a41c8ef97066 100644 --- a/external/bsd/openpam/dist/modules/pam_unix/pam_unix.c +++ b/external/bsd/openpam/dist/modules/pam_unix/pam_unix.c @@ -1,4 +1,4 @@ -/* $NetBSD: pam_unix.c,v 1.1.1.1 2011/12/25 21:42:54 christos Exp $ */ +/* $NetBSD: pam_unix.c,v 1.2 2011/12/25 22:27:56 christos Exp $ */ /*- * Copyright (c) 2002-2003 Networks Associates Technology, Inc.