diff --git a/source3/librpc/idl/smbXsrv.idl b/source3/librpc/idl/smbXsrv.idl index 5078d0d2800..f6a5fd98c36 100644 --- a/source3/librpc/idl/smbXsrv.idl +++ b/source3/librpc/idl/smbXsrv.idl @@ -123,6 +123,10 @@ interface smbXsrv SMBXSRV_PROCESSED_UNENCRYPTED_PACKET = 0x08 } smbXsrv_encrpytion_flags; + typedef [public,bitmap8bit] bitmap { + SMBXSRV_SIGNING_REQUIRED = 0x01 + } smbXsrv_signing_flags; + typedef struct { server_id server_id; [charset(UTF8),string] char local_address[]; @@ -148,7 +152,7 @@ interface smbXsrv uint32 auth_session_info_seqnum; auth_session_info *auth_session_info; uint16 connection_dialect; - boolean8 signing_required; + smbXsrv_signing_flags signing_flags; smbXsrv_encrpytion_flags encryption_flags; [noprint] DATA_BLOB signing_key; [noprint] DATA_BLOB encryption_key; diff --git a/source3/smbd/smb2_server.c b/source3/smbd/smb2_server.c index 70fbdc7a0b3..a9916cca2a8 100644 --- a/source3/smbd/smb2_server.c +++ b/source3/smbd/smb2_server.c @@ -2125,7 +2125,7 @@ NTSTATUS smbd_smb2_request_dispatch(struct smbd_smb2_request *req) session_status = smbd_smb2_request_check_session(req); x = req->session; if (x != NULL) { - signing_required = x->global->signing_required; + signing_required = x->global->signing_flags & SMBXSRV_SIGNING_REQUIRED; encryption_desired = x->global->encryption_flags & SMBXSRV_ENCRYPTION_DESIRED; encryption_required = x->global->encryption_flags & SMBXSRV_ENCRYPTION_REQUIRED; } diff --git a/source3/smbd/smb2_sesssetup.c b/source3/smbd/smb2_sesssetup.c index 2b83d1e24bf..a6c66e2feed 100644 --- a/source3/smbd/smb2_sesssetup.c +++ b/source3/smbd/smb2_sesssetup.c @@ -263,7 +263,7 @@ static NTSTATUS smbd_smb2_auth_generic_return(struct smbXsrv_session *session, if ((in_security_mode & SMB2_NEGOTIATE_SIGNING_REQUIRED) || lp_server_signing() == SMB_SIGNING_REQUIRED) { - x->global->signing_required = true; + x->global->signing_flags = SMBXSRV_SIGNING_REQUIRED; } if ((lp_smb_encrypt(-1) >= SMB_SIGNING_DESIRED) && @@ -281,7 +281,7 @@ static NTSTATUS smbd_smb2_auth_generic_return(struct smbXsrv_session *session, *out_session_flags |= SMB2_SESSION_FLAG_IS_GUEST; *out_session_flags |= SMB2_SESSION_FLAG_IS_NULL; /* force no signing */ - x->global->signing_required = false; + x->global->signing_flags &= ~SMBXSRV_SIGNING_REQUIRED; guest = true; }