smb2_server: make sure we detect stale smbXsrv_connection pointers in smbXsrv_channel...
authorStefan Metzmacher <metze@samba.org>
Fri, 4 Oct 2019 08:02:56 +0000 (10:02 +0200)
committerGünther Deschner <gd@samba.org>
Fri, 15 May 2020 09:04:36 +0000 (09:04 +0000)
commit0cec96526bf4d3209caf36c4a19632ff5d5dd112
treee2032d838b643fa863c6ab0ce113c705dd58c507
parent2ac0f8354585ac2cd617d53bfc9678769c8698fc
smb2_server: make sure we detect stale smbXsrv_connection pointers in smbXsrv_channel_global

Pointer values can be reused (yes, I hit that during my testing!).
Introduce a channel_id to identify connections and also add
some timestamps to make debugging easier.

This makes smbXsrv_session_find_channel() much more robust.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
source3/librpc/idl/smbXsrv.idl
source3/smbd/globals.h
source3/smbd/process.c
source3/smbd/smb2_sesssetup.c
source3/smbd/smbXsrv_client.c
source3/smbd/smbXsrv_session.c