15331Samw /* 25331Samw * CDDL HEADER START 35331Samw * 45331Samw * The contents of this file are subject to the terms of the 55331Samw * Common Development and Distribution License (the "License"). 65331Samw * You may not use this file except in compliance with the License. 75331Samw * 85331Samw * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 95331Samw * or http://www.opensolaris.org/os/licensing. 105331Samw * See the License for the specific language governing permissions 115331Samw * and limitations under the License. 125331Samw * 135331Samw * When distributing Covered Code, include this CDDL HEADER in each 145331Samw * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 155331Samw * If applicable, add the following below this CDDL HEADER, with the 165331Samw * fields enclosed by brackets "[]" replaced with your own identifying 175331Samw * information: Portions Copyright [yyyy] [name of copyright owner] 185331Samw * 195331Samw * CDDL HEADER END 205331Samw */ 215331Samw /* 225772Sas200622 * Copyright 2008 Sun Microsystems, Inc. All rights reserved. 235331Samw * Use is subject to license terms. 245331Samw */ 255331Samw 265331Samw #ifndef _LIBMLSVC_H 275331Samw #define _LIBMLSVC_H 285331Samw 295331Samw #include <sys/types.h> 306432Sas200622 #include <smbsrv/smb_sid.h> 315331Samw #include <smbsrv/hash_table.h> 325331Samw #include <smbsrv/smb_token.h> 335331Samw #include <smbsrv/smb_privilege.h> 347052Samw #include <smbsrv/smb_share.h> 355331Samw #include <smbsrv/libsmb.h> 36*7588Samw@Sun.COM #include <smbsrv/smb_xdr.h> 375331Samw 385331Samw #ifdef __cplusplus 395331Samw extern "C" { 405331Samw #endif 415331Samw 42*7588Samw@Sun.COM extern int mlsvc_get_door_fd(void); 43*7588Samw@Sun.COM extern uint64_t mlsvc_get_num_users(void); 44*7588Samw@Sun.COM extern int mlsvc_get_user_list(int, smb_dr_ulist_t *); 455331Samw extern int mlsvc_init(void); 46*7588Samw@Sun.COM extern void mlsvc_set_door_fd(int); 47*7588Samw@Sun.COM extern int mlsvc_set_share(int, char *, char *); 486432Sas200622 extern uint32_t mlsvc_lookup_name(char *, smb_sid_t **, uint16_t *); 496432Sas200622 extern uint32_t mlsvc_lookup_sid(smb_sid_t *, char **); 506139Sjb150015 extern DWORD mlsvc_netlogon(char *, char *); 515331Samw extern DWORD lsa_query_primary_domain_info(void); 525331Samw extern DWORD lsa_query_account_domain_info(void); 535331Samw extern DWORD lsa_enum_trusted_domains(void); 545331Samw 556139Sjb150015 extern boolean_t smbd_locate_dc(char *, char *); 565331Samw 575331Samw #define SMB_AUTOHOME_FILE "smbautohome" 585331Samw #define SMB_AUTOHOME_PATH "/etc" 595331Samw 605331Samw typedef struct smb_autohome { 615331Samw struct smb_autohome *ah_next; 625331Samw uint32_t ah_hits; 635331Samw time_t ah_timestamp; 645331Samw char *ah_name; /* User account name */ 655331Samw char *ah_path; /* Home directory path */ 665331Samw char *ah_container; /* ADS container distinguished name */ 675331Samw } smb_autohome_t; 685331Samw 696771Sjb150015 extern void smb_autohome_add(const char *); 706771Sjb150015 extern void smb_autohome_remove(const char *); 715331Samw 725331Samw #ifdef __cplusplus 735331Samw } 745331Samw #endif 755331Samw 765331Samw #endif /* _LIBMLSVC_H */ 77