idl: rebuild drsuapi.idl
[Samba/aatanasov.git] / nsswitch / winbind_nss_solaris.h
blobf805542f7535265ea5c861f2cf207c65f064d5db
1 /*
2 Unix SMB/CIFS implementation.
4 Winbind daemon for ntdom nss module
6 Copyright (C) Tim Potter 2000
8 This library is free software; you can redistribute it and/or
9 modify it under the terms of the GNU Lesser General Public
10 License as published by the Free Software Foundation; either
11 version 3 of the License, or (at your option) any later version.
13 This library is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 Library General Public License for more details.
18 You should have received a copy of the GNU Lesser General Public License
19 along with this program. If not, see <http://www.gnu.org/licenses/>.
22 #ifndef _WINBIND_NSS_SOLARIS_H
23 #define _WINBIND_NSS_SOLARIS_H
25 /* Solaris has a broken nss_common header file containing C++ reserved names. */
26 #ifndef __cplusplus
27 #undef class
28 #undef private
29 #undef public
30 #undef protected
31 #undef template
32 #undef this
33 #undef new
34 #undef delete
35 #undef friend
36 #endif
38 #include <nss_common.h>
40 #ifndef __cplusplus
41 #define class #error DONT_USE_CPLUSPLUS_RESERVED_NAMES
42 #define private #error DONT_USE_CPLUSPLUS_RESERVED_NAMES
43 #define public #error DONT_USE_CPLUSPLUS_RESERVED_NAMES
44 #define protected #error DONT_USE_CPLUSPLUS_RESERVED_NAMES
45 #define template #error DONT_USE_CPLUSPLUS_RESERVED_NAMES
46 #define this #error DONT_USE_CPLUSPLUS_RESERVED_NAMES
47 #define new #error DONT_USE_CPLUSPLUS_RESERVED_NAMES
48 #define delete #error DONT_USE_CPLUSPLUS_RESERVED_NAMES
49 #define friend #error DONT_USE_CPLUSPLUS_RESERVED_NAMES
50 #endif
52 #include <nss_dbdefs.h>
53 #include <nsswitch.h>
55 typedef nss_status_t NSS_STATUS;
57 #define NSS_STATUS_SUCCESS NSS_SUCCESS
58 #define NSS_STATUS_NOTFOUND NSS_NOTFOUND
59 #define NSS_STATUS_UNAVAIL NSS_UNAVAIL
60 #define NSS_STATUS_TRYAGAIN NSS_TRYAGAIN
62 /* The solaris winbind is implemented as a wrapper around the linux
63 version. */
65 NSS_STATUS _nss_winbind_setpwent(void);
66 NSS_STATUS _nss_winbind_endpwent(void);
67 NSS_STATUS _nss_winbind_getpwent_r(struct passwd* result, char* buffer,
68 size_t buflen, int* errnop);
69 NSS_STATUS _nss_winbind_getpwuid_r(uid_t, struct passwd*, char* buffer,
70 size_t buflen, int* errnop);
71 NSS_STATUS _nss_winbind_getpwnam_r(const char* name, struct passwd* result,
72 char* buffer, size_t buflen, int* errnop);
74 NSS_STATUS _nss_winbind_setgrent(void);
75 NSS_STATUS _nss_winbind_endgrent(void);
76 NSS_STATUS _nss_winbind_getgrent_r(struct group* result, char* buffer,
77 size_t buflen, int* errnop);
78 NSS_STATUS _nss_winbind_getgrnam_r(const char *name,
79 struct group *result, char *buffer,
80 size_t buflen, int *errnop);
81 NSS_STATUS _nss_winbind_getgrgid_r(gid_t gid,
82 struct group *result, char *buffer,
83 size_t buflen, int *errnop);
84 NSS_STATUS _nss_winbind_initgroups_dyn(char *user, gid_t group, long int *start,
85 long int *size, gid_t **groups,
86 long int limit, int *errnop);
88 #endif /* _WINBIND_NSS_SOLARIS_H */