1 /* $XConsortium: solaris.h /main/7 1996/10/30 11:12:37 drk $ */
2 /*******************************************************************************
4 ** solaris.h 1.9 95/09/10
6 ** Copyright 1993, 1994, 1995 Sun Microsystems, Inc. All rights reserved.
8 ** This file contains header info specific to Sun Solaris login
9 *******************************************************************************/
11 * (c) Copyright 1993, 1994 Hewlett-Packard Company *
12 * (c) Copyright 1993, 1994 International Business Machines Corp. *
13 * (c) Copyright 1993, 1994 Sun Microsystems, Inc. *
14 * (c) Copyright 1993, 1994 Novell, Inc. *
16 /*******************************************************************************
18 ** RESTRICTED CONFIDENTIAL INFORMATION:
20 ** The information in this document is subject to special
21 ** restrictions in a confidential disclosure agreement between
22 ** HP, IBM, Sun, USL, SCO and Univel. Do not distribute this
23 ** document outside HP, IBM, Sun, USL, SCO, or Univel without
24 ** Sun's specific written approval. This document and all copies
25 ** and derivative works thereof must be returned or destroyed at
28 ** Copyright 1994 Sun Microsystems, Inc. All rights reserved.
30 *******************************************************************************/
33 #ifndef _DTLOGIN_SOLARIS_H
34 #define _DTLOGIN_SOLARIS_H
36 #include <sys/types.h>
39 #include <security/pam_appl.h>
40 #define SOLARIS_SUCCESS PAM_SUCCESS
44 #include <security/ia_appl.h>
45 #define SOALRIS_SUCCESS IA_SUCCESS
49 /* Solaris utmp mgt flags */
51 #define SOLARIS_UPDATE_ENTRY 1 /* Update an existing entry */
52 #define SOLARIS_NOLOG 2 /* Don't log the new session */
53 #define SOLARIS_LOGIN 4 /* login type entry (sigh...) */
55 /* Errors returned by solaris_setutmp_mgmt/solaris_reset_utmp_mgmt() */
56 #define SOLARIS_NOENTRY 27 /* No entry found */
57 #define SOLARIS_ENTRYFAIL 28 /* Couldn't edit the entry */
59 /* user credential UID/GID erros */
60 #define SOLARIS_BAD_GID 29 /* Invalid Group ID */
61 #define SOLARIS_INITGROUP_FAIL 30 /* group IDs init failed */
62 #define SOLARIS_BAD_UID 31 /* Invaid User ID */
63 #define SOLARIS_SETGROUP_FAIL 32 /* Set of group IDs failed */
66 * External procedure declarations
70 extern int solaris_authentication(char*, char*, char*, char*, char*);
71 extern int solaris_accounting(char*, char*, char[], char*,
72 char*, pid_t, int, int);
73 extern int solaris_setcred(char*, char *, uid_t, gid_t);
74 extern int solaris_setdevperm(char *, uid_t, gid_t);
75 extern int solaris_resetdevperm(char *);
77 extern int audit_login_save_host(char *host);
78 extern int audit_login_save_ttyn(char *ttyn);
79 extern int audit_login_save_port(void);
80 extern int audit_login_success(void);
81 extern int audit_login_save_pw(struct passwd *pwd);
82 extern int audit_login_bad_pw(void);
83 extern int audit_login_maxtrys(void);
86 #endif /* _DTLOGIN_SOLARIS_H */