smbd.h revision 7b59d02d2a384be9a08087b14defadd214b3c1dd
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw/*
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * CDDL HEADER START
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw *
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * The contents of this file are subject to the terms of the
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * Common Development and Distribution License (the "License").
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * You may not use this file except in compliance with the License.
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw *
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * or http://www.opensolaris.org/os/licensing.
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * See the License for the specific language governing permissions
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * and limitations under the License.
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw *
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * When distributing Covered Code, include this CDDL HEADER in each
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * If applicable, add the following below this CDDL HEADER, with the
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * fields enclosed by brackets "[]" replaced with your own identifying
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * information: Portions Copyright [yyyy] [name of copyright owner]
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw *
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * CDDL HEADER END
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw */
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw/*
7b59d02d2a384be9a08087b14defadd214b3c1ddjb * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw * Use is subject to license terms.
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw */
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw#ifndef _SMBD_H
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw#define _SMBD_H
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw#pragma ident "%Z%%M% %I% %E% SMI"
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw#ifdef __cplusplus
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amwextern "C" {
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw#endif
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw#include <sys/types.h>
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw#include <smbsrv/smb_token.h>
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw#include <smbsrv/libsmb.h>
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw#include <smbsrv/libmlsvc.h>
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amwextern int smb_nicmon_start(void);
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amwextern void smb_nicmon_stop(void);
7b59d02d2a384be9a08087b14defadd214b3c1ddjbextern void smb_nicmon_reconfig(void);
55bf511df53aad0fdb7eb3fa349f0308cc05234casextern int smb_winpipe_doorsvc_start(void);
55bf511df53aad0fdb7eb3fa349f0308cc05234casextern void smb_winpipe_doorsvc_stop(void);
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amwextern int smb_lmshrd_srv_start(void);
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amwextern void smb_lmshrd_srv_stop(void);
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amwextern int smb_doorsrv_start(void);
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amwextern void smb_doorsrv_stop(void);
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amwextern int smb_ntgroup_doorsrv_start(void);
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amwextern void smb_ntgroup_doorsrv_stop(void);
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amwextern int smb_netlogon_init(void);
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amwextern smb_token_t *smbd_user_auth_logon(netr_client_t *);
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amwextern void smbd_user_nonauth_logon(uint32_t);
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amwextern void smbd_user_auth_logoff(uint32_t);
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amwtypedef struct smbd {
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw const char *s_version; /* smbd version string */
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw const char *s_pname; /* basename to use for messages */
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw pid_t s_pid; /* process-ID of current daemon */
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw uid_t s_uid; /* UID of current daemon */
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw gid_t s_gid; /* GID of current daemon */
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw int s_fg; /* Run in foreground */
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw int s_drv_fd; /* Handle for SMB kernel driver */
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw int s_shutdown_flag; /* Fields for shutdown control */
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw int s_sigval;
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw} smbd_t;
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw#ifdef __cplusplus
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw}
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw#endif
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw
da6c28aaf62fa55f0fdb8004aa40f88f23bf53f0amw#endif /* _SMBD_H */