Vendor import of OpenPAM Eelgrass.
This commit is contained in:
parent
0ac9b614f9
commit
e7b7250764
@ -26,5 +26,6 @@ or indirectly, with patches, criticism, suggestions, or ideas:
|
||||
Ruslan Ermilov <ru@freebsd.org>
|
||||
Solar Designer <solar@openwall.com>
|
||||
Takanori Saneto <sanewo@ba2.so-net.ne.jp>
|
||||
Yar Tikhiy <yar@freebsd.org>
|
||||
|
||||
$P4: //depot/projects/openpam/CREDITS#9 $
|
||||
$P4: //depot/projects/openpam/CREDITS#10 $
|
||||
|
@ -1,3 +1,12 @@
|
||||
OpenPAM Eelgrass 2004-02-10
|
||||
|
||||
- BUGFIX: Correct array handling bugs in conversation code.
|
||||
|
||||
- BUGFIX: In openpam_ttyconv(3), don't strip trailing linear
|
||||
whitespace from the user's response.
|
||||
|
||||
- BUGFIX: Many constness issues addressed.
|
||||
============================================================================
|
||||
OpenPAM Dogwood 2003-07-15
|
||||
|
||||
- ENHANCE: Use the GNU autotools.
|
||||
@ -263,4 +272,4 @@ OpenPAM Calamite 2002-02-09
|
||||
|
||||
First (beta) release.
|
||||
============================================================================
|
||||
$P4: //depot/projects/openpam/HISTORY#21 $
|
||||
$P4: //depot/projects/openpam/HISTORY#22 $
|
||||
|
@ -102,7 +102,7 @@ RECURSIVE_TARGETS = info-recursive dvi-recursive install-info-recursive \
|
||||
uninstall-recursive check-recursive installcheck-recursive
|
||||
DIST_COMMON = README ./stamp-h.in INSTALL Makefile.am Makefile.in \
|
||||
aclocal.m4 config.guess config.h.in config.sub configure \
|
||||
configure.in install-sh ltconfig ltmain.sh missing \
|
||||
configure.in depcomp install-sh ltconfig ltmain.sh missing \
|
||||
mkinstalldirs
|
||||
DIST_SUBDIRS = $(SUBDIRS)
|
||||
all: config.h
|
||||
|
@ -1,6 +1,6 @@
|
||||
|
||||
Release notes for OpenPAM Dogwood
|
||||
=================================
|
||||
Release notes for OpenPAM Eelgrass
|
||||
==================================
|
||||
|
||||
This release corresponds to the code used in FreeBSD-CURRENT as of the
|
||||
release date. It has also been tested on several other platforms, and
|
||||
@ -26,4 +26,4 @@ proper credit for your contribution.
|
||||
|
||||
Please direct bug reports and inquiries to des@freebsd.org.
|
||||
|
||||
$P4: //depot/projects/openpam/RELNOTES#19 $
|
||||
$P4: //depot/projects/openpam/RELNOTES#20 $
|
||||
|
20
contrib/openpam/configure
vendored
20
contrib/openpam/configure
vendored
@ -1,6 +1,6 @@
|
||||
#! /bin/sh
|
||||
# Guess values for system-dependent variables and create Makefiles.
|
||||
# Generated by GNU Autoconf 2.53 for OpenPAM 20030715.
|
||||
# Generated by GNU Autoconf 2.53 for OpenPAM 20040210.
|
||||
#
|
||||
# Report bugs to <des@freebsd.org>.
|
||||
#
|
||||
@ -256,8 +256,8 @@ SHELL=${CONFIG_SHELL-/bin/sh}
|
||||
# Identity of this package.
|
||||
PACKAGE_NAME='OpenPAM'
|
||||
PACKAGE_TARNAME='openpam'
|
||||
PACKAGE_VERSION='20030715'
|
||||
PACKAGE_STRING='OpenPAM 20030715'
|
||||
PACKAGE_VERSION='20040210'
|
||||
PACKAGE_STRING='OpenPAM 20040210'
|
||||
PACKAGE_BUGREPORT='des@freebsd.org'
|
||||
|
||||
ac_unique_file="lib/pam_start.c"
|
||||
@ -762,7 +762,7 @@ if test "$ac_init_help" = "long"; then
|
||||
# Omit some internal or obsolete options to make the list less imposing.
|
||||
# This message is too long to be a string in the A/UX 3.1 sh.
|
||||
cat <<_ACEOF
|
||||
\`configure' configures OpenPAM 20030715 to adapt to many kinds of systems.
|
||||
\`configure' configures OpenPAM 20040210 to adapt to many kinds of systems.
|
||||
|
||||
Usage: $0 [OPTION]... [VAR=VALUE]...
|
||||
|
||||
@ -829,7 +829,7 @@ fi
|
||||
|
||||
if test -n "$ac_init_help"; then
|
||||
case $ac_init_help in
|
||||
short | recursive ) echo "Configuration of OpenPAM 20030715:";;
|
||||
short | recursive ) echo "Configuration of OpenPAM 20040210:";;
|
||||
esac
|
||||
cat <<\_ACEOF
|
||||
|
||||
@ -928,7 +928,7 @@ fi
|
||||
test -n "$ac_init_help" && exit 0
|
||||
if $ac_init_version; then
|
||||
cat <<\_ACEOF
|
||||
OpenPAM configure 20030715
|
||||
OpenPAM configure 20040210
|
||||
generated by GNU Autoconf 2.53
|
||||
|
||||
Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
|
||||
@ -943,7 +943,7 @@ cat >&5 <<_ACEOF
|
||||
This file contains any messages produced by compilers while
|
||||
running configure, to aid debugging if configure makes a mistake.
|
||||
|
||||
It was created by OpenPAM $as_me 20030715, which was
|
||||
It was created by OpenPAM $as_me 20040210, which was
|
||||
generated by GNU Autoconf 2.53. Invocation command line was
|
||||
|
||||
$ $0 $@
|
||||
@ -3040,7 +3040,7 @@ fi
|
||||
|
||||
# Define the identity of the package.
|
||||
PACKAGE=OpenPAM
|
||||
VERSION=20030715
|
||||
VERSION=20040210
|
||||
|
||||
cat >>confdefs.h <<_ACEOF
|
||||
#define PACKAGE "$PACKAGE"
|
||||
@ -4384,7 +4384,7 @@ _ASBOX
|
||||
} >&5
|
||||
cat >&5 <<_CSEOF
|
||||
|
||||
This file was extended by OpenPAM $as_me 20030715, which was
|
||||
This file was extended by OpenPAM $as_me 20040210, which was
|
||||
generated by GNU Autoconf 2.53. Invocation command line was
|
||||
|
||||
CONFIG_FILES = $CONFIG_FILES
|
||||
@ -4446,7 +4446,7 @@ _ACEOF
|
||||
|
||||
cat >>$CONFIG_STATUS <<_ACEOF
|
||||
ac_cs_version="\\
|
||||
OpenPAM config.status 20030715
|
||||
OpenPAM config.status 20040210
|
||||
configured by $0, generated by GNU Autoconf 2.53,
|
||||
with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
dnl $P4: //depot/projects/openpam/configure.in#3 $
|
||||
|
||||
AC_PREREQ(2.53)
|
||||
AC_INIT([OpenPAM],[20030715],[des@freebsd.org])
|
||||
AC_INIT([OpenPAM],[20040210],[des@freebsd.org])
|
||||
AC_CONFIG_SRCDIR([lib/pam_start.c])
|
||||
AM_CONFIG_HEADER([config.h])
|
||||
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt OPENPAM 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt OPENPAM_BORROW_CRED 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt OPENPAM_FREE_DATA 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt OPENPAM_GET_OPTION 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt OPENPAM_LOG 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt OPENPAM_NULLCONV 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt OPENPAM_READLINE 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt OPENPAM_RESTORE_CRED 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt OPENPAM_SET_OPTION 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt OPENPAM_TTYCONV 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
@ -70,7 +70,7 @@
|
||||
.Ft "int"
|
||||
.Fn pam_end "pam_handle_t *pamh" "int status"
|
||||
.Ft "int"
|
||||
.Fn pam_get_data "pam_handle_t *pamh" "const char *module_data_name" "const void **data"
|
||||
.Fn pam_get_data "pam_handle_t *pamh" "const char *module_data_name" "void **data"
|
||||
.Ft "int"
|
||||
.Fn pam_get_item "pam_handle_t *pamh" "int item_type" "const void **item"
|
||||
.Ft "int"
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_ACCT_MGMT 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_AUTHENTICATE 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_CHAUTHTOK 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_CLOSE_SESSION 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -31,7 +31,7 @@
|
||||
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
.\" SUCH DAMAGE.
|
||||
.\"
|
||||
.\" $P4: //depot/projects/openpam/doc/man/pam_conv.3#3 $
|
||||
.\" $P4: //depot/projects/openpam/doc/man/pam_conv.3#4 $
|
||||
.\"
|
||||
.Dd May 27, 2002
|
||||
.Dt PAM_CONV 3
|
||||
@ -77,9 +77,9 @@ The conversation function's first argument specifies the number of
|
||||
messages (up to
|
||||
.Dv PAM_NUM_MSG )
|
||||
to process.
|
||||
The second argument is a pointer to a contiguous array of
|
||||
.Vt struct pam_message
|
||||
containing the actual messages.
|
||||
The second argument is a pointer to an array of pointers to
|
||||
.Vt pam_message
|
||||
structures containing the actual messages.
|
||||
.Pp
|
||||
Each message can have one of four types, specified by the
|
||||
.Va msg_style
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_END 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_ERROR 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_GET_AUTHTOK 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_GET_DATA 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
@ -45,7 +45,7 @@
|
||||
.In sys/types.h
|
||||
.In security/pam_appl.h
|
||||
.Ft "int"
|
||||
.Fn pam_get_data "pam_handle_t *pamh" "const char *module_data_name" "const void **data"
|
||||
.Fn pam_get_data "pam_handle_t *pamh" "const char *module_data_name" "void **data"
|
||||
.Sh DESCRIPTION
|
||||
The
|
||||
.Nm
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_GET_ITEM 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_GET_USER 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_GETENV 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_GETENVLIST 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_INFO 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_OPEN_SESSION 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_PROMPT 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_PUTENV 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_SET_DATA 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_SET_ITEM 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_SETCRED 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_SETENV 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_SM_ACCT_MGMT 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_SM_AUTHENTICATE 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_SM_CHAUTHTOK 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_SM_CLOSE_SESSION 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_SM_OPEN_SESSION 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_SM_SETCRED 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_START 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_STRERROR 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_VERROR 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_VINFO 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -33,7 +33,7 @@
|
||||
.\"
|
||||
.\" $P4$
|
||||
.\"
|
||||
.Dd July 15, 2003
|
||||
.Dd February 10, 2004
|
||||
.Dt PAM_VPROMPT 3
|
||||
.Os
|
||||
.Sh NAME
|
||||
|
@ -31,7 +31,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $P4: //depot/projects/openpam/include/security/openpam.h#26 $
|
||||
* $P4: //depot/projects/openpam/include/security/openpam.h#27 $
|
||||
*/
|
||||
|
||||
#ifndef _SECURITY_OPENPAM_H_INCLUDED
|
||||
@ -147,7 +147,11 @@ void
|
||||
_openpam_log(int _level,
|
||||
const char *_func,
|
||||
const char *_fmt,
|
||||
...);
|
||||
...)
|
||||
#if defined(__GNUC__)
|
||||
__attribute__((__format__(__printf__, 3, 4)))
|
||||
#endif
|
||||
;
|
||||
|
||||
#if defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199901L)
|
||||
#define openpam_log(lvl, ...) \
|
||||
|
@ -31,14 +31,14 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $P4: //depot/projects/openpam/include/security/openpam_version.h#11 $
|
||||
* $P4: //depot/projects/openpam/include/security/openpam_version.h#12 $
|
||||
*/
|
||||
|
||||
#ifndef _OPENPAM_VERSION_H_INCLUDED
|
||||
#define _OPENPAM_VERSION_H_INCLUDED
|
||||
|
||||
#define _OPENPAM
|
||||
#define _OPENPAM_VERSION 20030715
|
||||
#define _OPENPAM_RELEASE "Dogwood"
|
||||
#define _OPENPAM_VERSION 20040210
|
||||
#define _OPENPAM_RELEASE "Eelgrass"
|
||||
|
||||
#endif
|
||||
|
@ -31,7 +31,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $P4: //depot/projects/openpam/include/security/pam_appl.h#13 $
|
||||
* $P4: //depot/projects/openpam/include/security/pam_appl.h#14 $
|
||||
*/
|
||||
|
||||
#ifndef _PAM_APPL_H_INCLUDED
|
||||
@ -71,7 +71,7 @@ pam_end(pam_handle_t *_pamh,
|
||||
int
|
||||
pam_get_data(pam_handle_t *_pamh,
|
||||
const char *_module_data_name,
|
||||
const void **_data);
|
||||
void **_data);
|
||||
|
||||
int
|
||||
pam_get_item(pam_handle_t *_pamh,
|
||||
|
@ -31,7 +31,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $P4: //depot/projects/openpam/lib/openpam_borrow_cred.c#10 $
|
||||
* $P4: //depot/projects/openpam/lib/openpam_borrow_cred.c#11 $
|
||||
*/
|
||||
|
||||
#include <sys/param.h>
|
||||
@ -57,11 +57,12 @@ openpam_borrow_cred(pam_handle_t *pamh,
|
||||
const struct passwd *pwd)
|
||||
{
|
||||
struct pam_saved_cred *scred;
|
||||
void *scredp;
|
||||
int r;
|
||||
|
||||
ENTERI(pwd->pw_uid);
|
||||
r = pam_get_data(pamh, PAM_SAVED_CRED, (const void **)&scred);
|
||||
if (r == PAM_SUCCESS && scred != NULL) {
|
||||
r = pam_get_data(pamh, PAM_SAVED_CRED, &scredp);
|
||||
if (r == PAM_SUCCESS && scredp != NULL) {
|
||||
openpam_log(PAM_LOG_DEBUG,
|
||||
"already operating under borrowed credentials");
|
||||
RETURNC(PAM_SYSTEM_ERR);
|
||||
|
@ -31,7 +31,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $P4: //depot/projects/openpam/lib/openpam_restore_cred.c#9 $
|
||||
* $P4: //depot/projects/openpam/lib/openpam_restore_cred.c#10 $
|
||||
*/
|
||||
|
||||
#include <sys/param.h>
|
||||
@ -56,14 +56,16 @@ int
|
||||
openpam_restore_cred(pam_handle_t *pamh)
|
||||
{
|
||||
struct pam_saved_cred *scred;
|
||||
void *scredp;
|
||||
int r;
|
||||
|
||||
ENTER();
|
||||
r = pam_get_data(pamh, PAM_SAVED_CRED, (const void **)&scred);
|
||||
r = pam_get_data(pamh, PAM_SAVED_CRED, &scredp);
|
||||
if (r != PAM_SUCCESS)
|
||||
RETURNC(r);
|
||||
if (scred == NULL)
|
||||
if (scredp == NULL)
|
||||
RETURNC(PAM_SYSTEM_ERR);
|
||||
scred = scredp;
|
||||
if (scred->euid != geteuid()) {
|
||||
if (seteuid(scred->euid) < 0 ||
|
||||
setgroups(scred->ngroups, scred->groups) < 0 ||
|
||||
|
@ -31,7 +31,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $P4: //depot/projects/openpam/lib/pam_get_authtok.c#26 $
|
||||
* $P4: //depot/projects/openpam/lib/pam_get_authtok.c#27 $
|
||||
*/
|
||||
|
||||
#include <sys/param.h>
|
||||
@ -60,7 +60,7 @@ pam_get_authtok(pam_handle_t *pamh,
|
||||
const char **authtok,
|
||||
const char *prompt)
|
||||
{
|
||||
const void *oldauthtok;
|
||||
const void *oldauthtok, *prevauthtok, *promptp;
|
||||
const char *default_prompt;
|
||||
char *resp, *resp2;
|
||||
int pitem, r, style, twice;
|
||||
@ -90,16 +90,20 @@ pam_get_authtok(pam_handle_t *pamh,
|
||||
}
|
||||
if (openpam_get_option(pamh, "try_first_pass") ||
|
||||
openpam_get_option(pamh, "use_first_pass")) {
|
||||
r = pam_get_item(pamh, item, (const void **)authtok);
|
||||
if (r == PAM_SUCCESS && *authtok != NULL)
|
||||
r = pam_get_item(pamh, item, &prevauthtok);
|
||||
if (r == PAM_SUCCESS && prevauthtok != NULL) {
|
||||
*authtok = prevauthtok;
|
||||
RETURNC(PAM_SUCCESS);
|
||||
}
|
||||
else if (openpam_get_option(pamh, "use_first_pass"))
|
||||
RETURNC(r == PAM_SUCCESS ? PAM_AUTH_ERR : r);
|
||||
}
|
||||
if (prompt == NULL) {
|
||||
r = pam_get_item(pamh, pitem, (const void **)&prompt);
|
||||
if (r != PAM_SUCCESS || prompt == NULL)
|
||||
r = pam_get_item(pamh, pitem, &promptp);
|
||||
if (r != PAM_SUCCESS || promptp == NULL)
|
||||
prompt = default_prompt;
|
||||
else
|
||||
prompt = promptp;
|
||||
}
|
||||
style = openpam_get_option(pamh, "echo_pass") ?
|
||||
PAM_PROMPT_ECHO_ON : PAM_PROMPT_ECHO_OFF;
|
||||
|
@ -31,9 +31,10 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $P4: //depot/projects/openpam/lib/pam_get_data.c#12 $
|
||||
* $P4: //depot/projects/openpam/lib/pam_get_data.c#13 $
|
||||
*/
|
||||
|
||||
#include <stdint.h>
|
||||
#include <string.h>
|
||||
|
||||
#include <security/pam_appl.h>
|
||||
@ -50,18 +51,19 @@
|
||||
int
|
||||
pam_get_data(pam_handle_t *pamh,
|
||||
const char *module_data_name,
|
||||
const void **data)
|
||||
void **data)
|
||||
{
|
||||
pam_data_t *dp;
|
||||
|
||||
ENTERS(module_data_name);
|
||||
if (pamh == NULL)
|
||||
RETURNC(PAM_SYSTEM_ERR);
|
||||
for (dp = pamh->module_data; dp != NULL; dp = dp->next)
|
||||
for (dp = pamh->module_data; dp != NULL; dp = dp->next) {
|
||||
if (strcmp(dp->name, module_data_name) == 0) {
|
||||
*data = dp->data;
|
||||
*data = (void *)(intptr_t)dp->data;
|
||||
RETURNC(PAM_SUCCESS);
|
||||
}
|
||||
}
|
||||
RETURNC(PAM_NO_MODULE_DATA);
|
||||
}
|
||||
|
||||
|
@ -31,7 +31,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $P4: //depot/projects/openpam/lib/pam_get_user.c#18 $
|
||||
* $P4: //depot/projects/openpam/lib/pam_get_user.c#19 $
|
||||
*/
|
||||
|
||||
#include <sys/param.h>
|
||||
@ -57,6 +57,7 @@ pam_get_user(pam_handle_t *pamh,
|
||||
const char **user,
|
||||
const char *prompt)
|
||||
{
|
||||
const void *promptp;
|
||||
char *resp;
|
||||
int r;
|
||||
|
||||
@ -67,9 +68,11 @@ pam_get_user(pam_handle_t *pamh,
|
||||
if (r == PAM_SUCCESS && *user != NULL)
|
||||
RETURNC(PAM_SUCCESS);
|
||||
if (prompt == NULL) {
|
||||
r = pam_get_item(pamh, PAM_USER_PROMPT, (const void **)&prompt);
|
||||
if (r != PAM_SUCCESS || prompt == NULL)
|
||||
r = pam_get_item(pamh, PAM_USER_PROMPT, &promptp);
|
||||
if (r != PAM_SUCCESS || promptp == NULL)
|
||||
prompt = user_prompt;
|
||||
else
|
||||
prompt = promptp;
|
||||
}
|
||||
r = pam_prompt(pamh, PAM_PROMPT_ECHO_ON, &resp, "%s", prompt);
|
||||
if (r != PAM_SUCCESS)
|
||||
|
@ -31,7 +31,7 @@
|
||||
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
||||
* SUCH DAMAGE.
|
||||
*
|
||||
* $P4: //depot/projects/openpam/lib/pam_vprompt.c#12 $
|
||||
* $P4: //depot/projects/openpam/lib/pam_vprompt.c#13 $
|
||||
*/
|
||||
|
||||
#include <stdarg.h>
|
||||
@ -59,13 +59,15 @@ pam_vprompt(pam_handle_t *pamh,
|
||||
struct pam_message msg;
|
||||
const struct pam_message *msgp;
|
||||
struct pam_response *rsp;
|
||||
struct pam_conv *conv;
|
||||
const struct pam_conv *conv;
|
||||
const void *convp;
|
||||
int r;
|
||||
|
||||
ENTER();
|
||||
r = pam_get_item(pamh, PAM_CONV, (const void **)&conv);
|
||||
r = pam_get_item(pamh, PAM_CONV, &convp);
|
||||
if (r != PAM_SUCCESS)
|
||||
RETURNC(r);
|
||||
conv = convp;
|
||||
if (conv == NULL || conv->conv == NULL) {
|
||||
openpam_log(PAM_LOG_ERROR, "no conversation function");
|
||||
RETURNC(PAM_SYSTEM_ERR);
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -0,0 +1 @@
|
||||
timestamp
|
Loading…
Reference in New Issue
Block a user