]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s3: smbd: Look at the correct signing state for the debug messages in make_connection...
authorJeremy Allison <jra@samba.org>
Tue, 8 Mar 2022 03:06:34 +0000 (19:06 -0800)
committerDavid Mulder <dmulder@samba.org>
Tue, 8 Mar 2022 22:12:37 +0000 (22:12 +0000)
The rest of the changes should now be just renaming
the SMB1 signing functions to make it clear they are
SMB1 specific.

Signed-off-by: Jeremy Allison <jra@samba.org>
Signed-off-by: David Mulder <dmulder@samba.org>
source3/smbd/service.c

index ef7c14d92d0e5edda4eb5522e67cb73942ddb735..2a527234e98237ca15c513de769576701d641849 100644 (file)
@@ -852,10 +852,18 @@ static NTSTATUS make_connection_snum(struct smbXsrv_connection *xconn,
         */
 
        if( DEBUGLVL( IS_IPC(conn) ? 3 : 2 ) ) {
+               bool signing_active;
+
                dbgtext( "%s (%s) ", get_remote_machine_name(),
                         tsocket_address_string(conn->sconn->remote_address,
                                                talloc_tos()) );
-               dbgtext( "%s", srv_is_signing_active(xconn) ? "signed " : "");
+               if (sconn->using_smb2) {
+                       signing_active = smb2_signing_key_valid(
+                                               session->global->encryption_key);
+               } else {
+                       signing_active = srv_is_signing_active(xconn);
+               }
+               dbgtext( "%s", signing_active ? "signed " : "");
                dbgtext( "connect to service %s ",
                         lp_const_servicename(snum) );
                dbgtext( "initially as user %s ",