This commit was manufactured by cvs2svn to create branch 'SAMBA_3_0'.
[sfrench/samba-autobuild/.git] / source / include / rpc_creds.h
1 /* 
2    Unix SMB/CIFS implementation.
3    SMB parameters and setup
4    Copyright (C) Andrew Tridgell 1992-1999
5    Copyright (C) Luke Kenneth Casson Leighton 1996-1999
6    
7    This program is free software; you can redistribute it and/or modify
8    it under the terms of the GNU General Public License as published by
9    the Free Software Foundation; either version 2 of the License, or
10    (at your option) any later version.
11    
12    This program is distributed in the hope that it will be useful,
13    but WITHOUT ANY WARRANTY; without even the implied warranty of
14    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15    GNU General Public License for more details.
16    
17    You should have received a copy of the GNU General Public License
18    along with this program; if not, write to the Free Software
19    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
20 */
21
22
23 #ifndef _RPC_CREDS_H /* _RPC_CREDS_H */
24 #define _RPC_CREDS_H 
25
26 typedef struct ntuser_creds
27 {
28         fstring user_name;
29         fstring domain;
30         struct pwd_info pwd;
31
32         uint32 ntlmssp_flags;
33
34 } CREDS_NT;
35
36 typedef struct unixuser_creds
37 {
38         fstring user_name;
39         fstring requested_name;
40         fstring real_name;
41         BOOL guest;
42
43 } CREDS_UNIX;
44
45 typedef struct unixsec_creds
46 {
47         uint32 uid;
48         uint32 gid;
49         int num_grps;
50         uint32 *grps;
51
52 } CREDS_UNIX_SEC;
53
54 typedef struct ntsec_creds
55 {
56         DOM_SID sid;
57         uint32 num_grps;
58         uint32 *grp_rids;
59
60 } CREDS_NT_SEC;
61
62 typedef struct user_creds
63 {
64         BOOL reuse;
65
66         uint32 ptr_ntc;
67         uint32 ptr_uxc;
68         uint32 ptr_nts;
69         uint32 ptr_uxs;
70         uint32 ptr_ssk;
71
72         CREDS_NT   ntc;
73         CREDS_UNIX uxc;
74
75         CREDS_NT_SEC   nts;
76         CREDS_UNIX_SEC uxs;
77
78         uchar usr_sess_key[16];
79
80 } CREDS_HYBRID;
81
82 typedef struct cred_command
83 {
84         uint16 version;
85         uint16 command;
86         uint32 pid; /* unique process id */
87
88         fstring name;
89
90         uint32 ptr_creds;
91         CREDS_HYBRID *cred;
92
93 } CREDS_CMD;
94
95 #endif /* _RPC_CREDS_H */
96