s3:smbd: Add fsp_client_guid() utility function to return the connected client guid.
authorJeremy Allison <jra@samba.org>
Wed, 5 Nov 2014 05:46:14 +0000 (21:46 -0800)
committerJeremy Allison <jra@samba.org>
Thu, 4 Dec 2014 04:45:09 +0000 (05:45 +0100)
Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
source3/smbd/files.c
source3/smbd/proto.h

index a9e8357cf389d996c8e2627e72c27d5976f289a7..71166288a6595e9c97dc0e2821ab03f255b97913 100644 (file)
@@ -740,3 +740,8 @@ NTSTATUS fsp_set_smb_fname(struct files_struct *fsp,
                        smb_fname_str_dbg(fsp->fsp_name),
                        &fsp->name_hash);
 }
+
+const struct GUID *fsp_client_guid(const files_struct *fsp)
+{
+       return &fsp->conn->sconn->client->connections->smb2.client.guid;
+}
index 1080895fddc2eb38d0c77c2fdd0f9896efafc7b5..0670597e4963e9acee9e77e352c5751deffd5da1 100644 (file)
@@ -387,6 +387,7 @@ NTSTATUS file_name_hash(connection_struct *conn,
                        const char *name, uint32_t *p_name_hash);
 NTSTATUS fsp_set_smb_fname(struct files_struct *fsp,
                           const struct smb_filename *smb_fname_in);
+const struct GUID *fsp_client_guid(const files_struct *fsp);
 
 /* The following definitions come from smbd/ipc.c  */