Initial import of the CDE 2.1.30 sources from the Open Group.
[oweals/cde.git] / cde / programs / dtlogin / bls / bls.h
1 /*
2  * xdm - display manager daemon
3  *
4  * $XConsortium: bls.h /main/4 1996/10/30 11:35:48 drk $
5  *
6  * Copyright 1988 Massachusetts Institute of Technology
7  *
8  * Permission to use, copy, modify, and distribute this software and its
9  * documentation for any purpose and without fee is hereby granted, provided
10  * that the above copyright notice appear in all copies and that both that
11  * copyright notice and this permission notice appear in supporting
12  * documentation, and that the name of M.I.T. not be used in advertising or
13  * publicity pertaining to distribution of the software without specific,
14  * written prior permission.  M.I.T. makes no representations about the
15  * suitability of this software for any purpose.  It is provided "as is"
16  * without express or implied warranty.
17  *
18  * Author:  Keith Packard, MIT X Consortium
19  */
20
21 /*
22  * bls.h
23  *
24  * public interfaces for B1 greet/verify functionality
25  */
26
27
28 #ifndef _BLS_H
29 #define _BLS_H
30
31 typedef unsigned char BOOL;
32
33 #ifndef FALSE
34 #define FALSE   0
35 #endif
36
37 #ifndef TRUE
38 #define TRUE    1
39 #endif
40
41 #ifdef BLS
42 #include <sys/security.h>
43 #include <sys/audit.h>     /* for passwd and pr_passwd */
44 #endif
45
46 #ifdef pegasus
47 #undef dirty            /* Some bozo put a macro called dirty in sys/param.h */
48 #endif /* pegasus */
49
50 struct greet_info {
51         char            *name;          /* user name */
52         char            *password;      /* user password */
53 #ifdef BLS
54         char            *b1security;    /* user's b1 security */
55 #endif
56         char            *string;        /* random string */
57 };
58                                 
59 struct verify_info {
60         int             uid;            /* user id */
61 #ifdef NGROUPS
62         int             groups[NGROUPS];/* group list */
63         int             ngroups;        /* number of elements in groups */
64 #else
65         int             gid;            /* group id */
66 #endif
67         char            **argv;         /* arguments to session */
68         char            **userEnviron;  /* environment for session */
69         char            **systemEnviron;/* environment for startup/reset */
70 #ifdef BLS
71         char *user_name;
72         struct mand_ir_t *sec_label_ir;
73         struct mand_ir_t *clearance_ir;
74         /* save these for logout time */
75         struct pr_passwd *prpwd;
76         struct passwd *pwd;
77         char terminal[16];
78 #endif
79 };
80
81 /***************************************************************************
82  *
83  *  Global variables
84  *
85  ***************************************************************************/
86 extern struct pr_passwd         *b1_pwd;
87 extern struct verify_info       *verify;        
88 extern struct greet_info        *greet; 
89
90 #endif  /* _BLS_H */