2 * <security/pam_appl.h>
4 * This header file collects definitions for the PAM API --- that is,
5 * public interface between the PAM library and an application program
6 * that wishes to use it.
8 * Note, the copyright information is at end of file.
10 * Created: 15-Jan-96 by TYT
11 * Last modified: 1996/3/5 by AGM
13 * $Log: pam_appl.h,v $
14 * Revision 1.5 1996/11/10 19:56:11 morgan
15 * minor prototype change
17 * Revision 1.4 1996/03/16 22:38:17 morgan
18 * made all of the pam_start input arguments constant
20 * Revision 1.3 1996/03/16 20:22:59 morgan
21 * changed name comment at top of file.
23 * Revision 1.2 1996/03/09 20:39:06 morgan
24 * added RCS information
27 * $Id: pam_appl.h,v 1.5 1996/11/10 19:56:11 morgan Exp $
31 #ifndef _SECURITY_PAM_APPL_H
32 #define _SECURITY_PAM_APPL_H
34 #include <security/_pam_types.h> /* Linux-PAM common defined types */
36 /* -------------- The Linux-PAM Framework layer API ------------- */
38 extern int pam_start(const char *service_name, const char *user,
39 const struct pam_conv *pam_conversation,
41 extern int pam_end(pam_handle_t *pamh, int pam_status);
43 /* Authentication API's */
45 extern int pam_authenticate(pam_handle_t *pamh, int flags);
46 extern int pam_setcred(pam_handle_t *pamh, int flags);
48 /* Account Management API's */
50 extern int pam_acct_mgmt(pam_handle_t *pamh, int flags);
52 /* Session Management API's */
54 extern int pam_open_session(pam_handle_t *pamh, int flags);
55 extern int pam_close_session(pam_handle_t *pamh, int flags);
57 /* Password Management API's */
59 extern int pam_chauthtok(pam_handle_t *pamh, int flags);
61 /* take care of any compatibility issues */
62 #include <security/_pam_compat.h>
65 * Copyright Theodore Ts'o, 1996. All rights reserved.
67 * Redistribution and use in source and binary forms, with or without
68 * modification, are permitted provided that the following conditions
70 * 1. Redistributions of source code must retain the above copyright
71 * notice, and the entire permission notice in its entirety,
72 * including the disclaimer of warranties.
73 * 2. Redistributions in binary form must reproduce the above copyright
74 * notice, this list of conditions and the following disclaimer in the
75 * documentation and/or other materials provided with the distribution.
76 * 3. The name of the author may not be used to endorse or promote
77 * products derived from this software without specific prior
80 * ALTERNATIVELY, this product may be distributed under the terms of
81 * the GNU Public License, in which case the provisions of the GPL are
82 * required INSTEAD OF the above restrictions. (This clause is
83 * necessary due to a potential bad interaction between the GPL and
84 * the restrictions contained in a BSD-style copyright.)
86 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED
87 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
88 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
89 * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
90 * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
91 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
92 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
93 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
94 * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
95 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
96 * OF THE POSSIBILITY OF SUCH DAMAGE.
99 #endif /* _SECURITY_PAM_APPL_H */