[PATCH] Display status of encryption and signing in smbstatus

Ralph Boehme rb at sernet.de
Thu Jan 21 16:38:55 UTC 2016


On Thu, Jan 21, 2016 at 08:33:13AM -0800, Jeremy Allison wrote:
> On Thu, Jan 21, 2016 at 05:14:32PM +0100, Ralph Boehme wrote:
> > On Thu, Jan 21, 2016 at 11:23:53AM +0100, Ralph Boehme wrote:
> > > On Wed, Jan 20, 2016 at 03:57:37PM -0800, Jeremy Allison wrote:
> > > > On Wed, Jan 20, 2016 at 03:03:26PM -0800, Jeremy Allison wrote:
> > > > > On Wed, Jan 20, 2016 at 09:11:29AM +0100, Ralph Boehme wrote:
> > > > > > Hi!
> > > > > > 
> > > > > > Looks like this one gut stuck, can someone take a look? Thanks!
> > > > > 
> > > > > Reviewing this now - minor change needed. More when
> > > > > I've finished.
> > > > 
> > > > OK, if you can merge the following patch to
> > > > the code that adds the SMB1 smb1srv_update_crypto_flags()
> > > > function then I'm OK for you to push with my
> > > > 'Reviewed-by: Jeremy Allison' added.
> > > > 
> > > > Thanks Ralph !
> > > > 
> > > > Jeremy.
> > > 
> > > > diff --git a/source3/smbd/process.c b/source3/smbd/process.c
> > > > index adcea25..4c49ea2 100644
> > > > --- a/source3/smbd/process.c
> > > > +++ b/source3/smbd/process.c
> > > > @@ -1444,7 +1444,7 @@ static void smb1srv_update_crypto_flags(struct smbXsrv_session *session,
> > > >  	bool update_session = false;
> > > >  	bool update_tcon = false;
> > > >  
> > > > -	if (ENCRYPTION_REQUIRED(conn)) {
> > > > +	if (req->encrypted) {
> > > >  		encrypt_flag = SMBXSRV_PROCESSED_ENCRYPTED_PACKET;
> > > >  	}
> > > 
> > > Pushed with the change.
> > 
> > ...and crashed in autobuild. Working on it...
> 
> Related ? Looking at req->encrypted is certainly
> the correct thing here as ENCRYPTION_REQUIRED(conn)
> is a static config, and req->encrypted is per-packet.

no, no. It crashed at logoff when session->global is alredy gone away
when I call smb1srv_update_crypto_flags(). Iirc there was a reason I
put the flag updating behind the packet processing. No idea why this
didn't crash on me in manual testing.

Running a local make test now with an upated version, seems make test
finally got usable on my devel machine.

-Ralph

-- 
SerNet GmbH, Bahnhofsallee 1b, 37081 Göttingen
phone: +49-551-370000-0, fax: +49-551-370000-9
AG Göttingen, HRB 2816, GF: Dr. Johannes Loxen
http://www.sernet.de,mailto:kontakt@sernet.de



More information about the samba-technical mailing list