include/nss_info.h

説明を見る。
00001 /* 
00002    Unix SMB/CIFS implementation.
00003    Idmap NSS headers
00004 
00005    Copyright (C) Gerald Carter             2006
00006 
00007    This library is free software; you can redistribute it and/or
00008    modify it under the terms of the GNU Library General Public
00009    License as published by the Free Software Foundation; either
00010    version 2 of the License, or (at your option) any later version.
00011    
00012    This library is distributed in the hope that it will be useful,
00013    but WITHOUT ANY WARRANTY; without even the implied warranty of
00014    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00015    Library General Public License for more details.
00016    
00017    You should have received a copy of the GNU Library General Public
00018    License along with this library; if not, write to the
00019    Free Software Foundation, Inc., 59 Temple Place - Suite 330,
00020    Boston, MA  02111-1307, USA.   
00021 */
00022 
00023 #ifndef _IDMAP_NSS_H
00024 #define _IDMAP_NSS_H
00025 
00026 #ifndef HAVE_LDAP
00027 #  ifndef LDAPMessage
00028 #    define LDAPMessage void
00029 #  endif
00030 #endif
00031 
00032 /* The interface version specifier */
00033 
00034 #define SMB_NSS_INFO_INTERFACE_VERSION    1
00035 
00036 /* List of available backends.  All backends must 
00037    register themselves */
00038 
00039 struct nss_function_entry {
00040         struct nss_function_entry *prev, *next;
00041         
00042         const char *name;
00043         struct nss_info_methods *methods;
00044 };
00045 
00046 /* List of configured domains.  Each domain points 
00047    back to its configured backend. */
00048 
00049 struct nss_domain_entry {
00050         struct nss_domain_entry *prev, *next;
00051 
00052         const char *domain;
00053 
00054         NTSTATUS init_status;   
00055         struct nss_function_entry *backend;
00056 
00057         /* hold state on a per domain basis */
00058 
00059         void *state;
00060 };
00061 
00062 /* API */
00063 
00064 struct nss_info_methods {
00065         NTSTATUS (*init)( struct nss_domain_entry *e );
00066         NTSTATUS (*get_nss_info)( struct nss_domain_entry *e, 
00067                                   const DOM_SID *sid, 
00068                                   TALLOC_CTX *ctx, 
00069                                   ADS_STRUCT *ads, LDAPMessage *msg,
00070                                   char **homedir, char **shell, char **gecos, gid_t *p_gid);
00071         NTSTATUS (*close_fn)( void );
00072 };
00073 
00074 
00075 /* The following definitions come from nsswitch/nss_info.c  */
00076 
00077 NTSTATUS smb_register_idmap_nss(int version, 
00078                                 const char *name, 
00079                                 struct nss_info_methods *methods);
00080 
00081 NTSTATUS nss_init( const char **nss_list );
00082 
00083 NTSTATUS nss_get_info( const char *domain, const DOM_SID *user_sid,
00084                        TALLOC_CTX *ctx,
00085                        ADS_STRUCT *ads, LDAPMessage *msg,
00086                        char **homedir, char **shell, char **gecos,
00087                        gid_t *p_gid);
00088 
00089 NTSTATUS nss_close( const char *parameters );
00090 
00091 #endif /* _IDMAP_NSS_H_ */
00092 

Sambaに対してSat Aug 29 21:22:54 2009に生成されました。  doxygen 1.4.7