2011-03-19 02:47:12 +03:00
/*
Unix SMB / CIFS implementation .
Main SMB server routines
This program is free software ; you can redistribute it and / or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation ; either version 3 of the License , or
( at your option ) any later version .
This program is distributed in the hope that it will be useful ,
but WITHOUT ANY WARRANTY ; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE . See the
GNU General Public License for more details .
You should have received a copy of the GNU General Public License
along with this program . If not , see < http : //www.gnu.org/licenses/>.
*/
# ifndef _SMBD_SMBD_H
# define _SMBD_SMBD_H
2012-06-05 12:28:49 +04:00
struct dptr_struct ;
2011-03-19 02:47:12 +03:00
# include "smb_acls.h"
2012-07-02 16:46:00 +04:00
# include "vfs.h"
2011-03-19 02:47:12 +03:00
# include "smbd/proto.h"
2011-03-23 14:43:17 +03:00
# include "locking/proto.h"
2022-08-18 15:14:20 +03:00
# include "locking/share_mode_lock.h"
2020-09-27 14:14:30 +03:00
# include "smbd/fd_handle.h"
2022-03-11 18:44:02 +03:00
# if defined(WITH_SMB1SERVER)
# include "smbd/smb1_message.h"
2022-03-11 18:46:46 +03:00
# include "smbd/smb1_sesssetup.h"
2022-03-11 18:50:12 +03:00
# include "smbd/smb1_lanman.h"
2022-03-11 19:17:59 +03:00
# include "smbd/smb1_aio.h"
2022-03-11 19:57:57 +03:00
# include "smbd/smb1_ipc.h"
2022-03-11 20:20:48 +03:00
# include "smbd/smb1_negprot.h"
2022-03-11 22:20:52 +03:00
# include "smbd/smb1_nttrans.h"
2022-03-15 23:32:08 +03:00
# include "smbd/smb1_oplock.h"
2022-03-15 23:50:16 +03:00
# include "smbd/smb1_pipes.h"
2022-03-17 21:59:22 +03:00
# include "smbd/smb1_reply.h"
2022-03-17 22:32:30 +03:00
# include "smbd/smb1_service.h"
2022-03-17 23:54:01 +03:00
# include "smbd/smb1_signing.h"
2022-03-21 17:30:48 +03:00
# include "smbd/smb1_process.h"
2022-03-21 18:56:04 +03:00
# include "smbd/smb1_utils.h"
2022-03-21 20:51:41 +03:00
# include "smbd/smb1_trans2.h"
2022-03-11 18:44:02 +03:00
# endif
2011-03-19 02:47:12 +03:00
2012-06-05 12:00:06 +04:00
struct trans_state {
struct trans_state * next , * prev ;
2012-06-05 17:14:04 +04:00
uint64_t vuid ; /* SMB2 compat */
2012-06-05 12:00:06 +04:00
uint64_t mid ;
2015-05-03 07:01:14 +03:00
uint32_t max_param_return ;
uint32_t max_data_return ;
uint32_t max_setup_return ;
2012-06-05 12:00:06 +04:00
2015-05-03 07:01:14 +03:00
uint8_t cmd ; /* SMBtrans or SMBtrans2 */
2012-06-05 12:00:06 +04:00
char * name ; /* for trans requests */
2015-05-03 07:01:14 +03:00
uint16_t call ; /* for trans2 and nttrans requests */
2012-06-05 12:00:06 +04:00
bool close_on_completion ;
bool one_way ;
unsigned int setup_count ;
2015-05-03 07:01:14 +03:00
uint16_t * setup ;
2012-06-05 12:00:06 +04:00
size_t received_data ;
size_t received_param ;
size_t total_param ;
char * param ;
size_t total_data ;
char * data ;
} ;
2012-06-05 12:48:57 +04:00
/*
* unix_convert_flags
*/
2020-03-27 02:27:25 +03:00
/* UCF_SAVE_LCOMP 0x00000001 is no longer used. */
2021-12-03 23:40:43 +03:00
/* UCF_ALWAYS_ALLOW_WCARD_LCOMP 0x00000002 is no longer used. */
2020-09-29 06:12:23 +03:00
/* UCF_COND_ALLOW_WCARD_LCOMP 0x00000004 is no longer used. */
2012-06-05 12:48:57 +04:00
# define UCF_POSIX_PATHNAMES 0x00000008
2020-10-22 12:12:11 +03:00
/* #define UCF_UNIX_NAME_LOOKUP 0x00000010 is no longer used. */
2013-12-03 22:19:09 +04:00
# define UCF_PREP_CREATEFILE 0x00000020
2022-12-20 23:26:10 +03:00
/*
* Return a non - fsp smb_fname for a symlink
*/
# define UCF_LCOMP_LNK_OK 0x00000040
2017-05-18 23:24:26 +03:00
/*
* Use the same bit as FLAGS2_REPARSE_PATH
* which means the same thing .
*/
# define UCF_GMT_PATHNAME 0x00000400
2017-05-18 22:18:58 +03:00
/*
* Use the same bit as FLAGS2_DFS_PATHNAMES
* which means the same thing .
*/
# define UCF_DFS_PATHNAME 0x00001000
2012-06-05 12:48:57 +04:00
2011-03-19 02:47:12 +03:00
# endif /* _SMBD_SMBD_H */