lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAKYAXd9Ju4MFkkH5Jxfi1mO0AWEr=R35M3vQ_Xa7Yw34JoNZ0A@mail.gmail.com>
Date: Thu, 18 Dec 2025 21:17:02 +0900
From: Namjae Jeon <linkinjeon@...nel.org>
To: David Howells <dhowells@...hat.com>
Cc: Steve French <sfrench@...ba.org>, Paulo Alcantara <pc@...guebit.org>, 
	Shyam Prasad N <sprasad@...rosoft.com>, Stefan Metzmacher <metze@...ba.org>, Tom Talpey <tom@...pey.com>, 
	linux-cifs@...r.kernel.org, netfs@...ts.linux.dev, 
	linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v6 1/9] cifs: Remove the RFC1002 header from smb_hdr

On Tue, Dec 2, 2025 at 7:59 AM David Howells <dhowells@...hat.com> wrote:
>
> Remove the RFC1002 header from struct smb_hdr as used for SMB-1.0.  This
> simplifies the SMB-1.0 code by simplifying a lot of places that have to add
> or subtract 4 to work around the fact that the RFC1002 header isn't really
> part of the message and the base for various offsets within the message is
> from the base of the smb_hdr, not the RFC1002 header.
>
> Further, clean up a bunch of places that require an extra kvec struct
> specifically pointing to the RFC1002 header, such that kvec[0].iov_base
> must be exactly 4 bytes before kvec[1].iov_base.
>
> This allows the header preamble size stuff to be removed too.
>
> The size of the request and response message are then handed around either
> directly or by summing the size of all the iov_len members in the kvec
> array for which we have a count.
>
> Also, this simplifies and cleans up the common transmission and receive
> paths for SMB1 and SMB2/3 as there no longer needs to be special handling
> casing for SMB1 messages as the RFC1002 header is now generated on the fly
> for SMB1 as it is for SMB2/3.
>
> Signed-off-by: David Howells <dhowells@...hat.com>
> Reviewed-by: Tom Talpey <tom@...pey.com>
> cc: Steve French <sfrench@...ba.org>
> cc: Paulo Alcantara <pc@...guebit.org>
> cc: Shyam Prasad N <sprasad@...rosoft.com>
> cc: linux-cifs@...r.kernel.org
> cc: netfs@...ts.linux.dev
> cc: linux-fsdevel@...r.kernel.org
> ---
>  fs/smb/client/cifs_debug.c    |  10 +-
>  fs/smb/client/cifs_debug.h    |   6 +-
>  fs/smb/client/cifsencrypt.c   |  36 +-
>  fs/smb/client/cifsglob.h      |  23 +-
>  fs/smb/client/cifspdu.h       |   2 +-
>  fs/smb/client/cifsproto.h     |  51 ++-
>  fs/smb/client/cifssmb.c       | 735 +++++++++++++++++++---------------
>  fs/smb/client/cifstransport.c | 208 ++++------
>  fs/smb/client/connect.c       |  36 +-
>  fs/smb/client/misc.c          |  34 +-
>  fs/smb/client/sess.c          |   8 +-
>  fs/smb/client/smb1ops.c       |  21 +-
>  fs/smb/client/smb2misc.c      |   3 +-
>  fs/smb/client/smb2ops.c       |  11 +-
>  fs/smb/client/smb2proto.h     |   2 +-
>  fs/smb/client/transport.c     |  80 ++--
>  fs/smb/common/smb2pdu.h       |   3 -
>  fs/smb/common/smbglob.h       |   1 -
>  18 files changed, 645 insertions(+), 625 deletions(-)
Why did you only change smb client after changing smb_hdr structure in
smb/common? smb server also uses smb_hdr structure to handle smb1
negotiate request. Also, Why didn't you cc me on the patch that
updates smb/common?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ