Updated commit description wording and added cc: stable Let me know if you see any problems with it. On Fri, Aug 31, 2018 at 7:21 AM Aurélien Aptel <aaptel@xxxxxxxx> wrote: > > Reviewed-by: Aurelien Aptel <aaptel@xxxxxxxx> > > Steve, you might want to edit the message to something simpler and wrap > the long line. > > Cheers, > -- > Aurélien Aptel / SUSE Labs Samba Team > GPG: 1839 CB5F 9F5B FB9B AA97 8C99 03C8 A49B 521B D5D3 > SUSE Linux GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany > GF: Felix Imendörffer, Jane Smithard, Graham Norton, HRB 21284 (AG Nürnberg) -- Thanks, Steve
From ab5deb20ecaaff6809d200b33c2ae941d47404d4 Mon Sep 17 00:00:00 2001 From: Thomas Werschlein <thomas.werschlein@xxxxxxxxxx> Date: Thu, 30 Aug 2018 18:29:20 +0200 Subject: [PATCH] cifs: connect to servername instead of IP for IPC$ share MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This patch is required allows access to a Microsoft fileserver failover cluster behind a 1:1 NAT firewall. The change also provides stronger context for authentication and share connection (see MS-SMB2 3.3.5.7 and MS-SRVS 3.1.6.8) as noted by Tom Talpey, and addresses comments about the buffer size for the UNC made by Aurélien Aptel. Signed-off-by: Thomas Werschlein <thomas.werschlein@xxxxxxxxxx> Signed-off-by: Steve French <stfrench@xxxxxxxxxxxxx> CC: Tom Talpey <ttalpey@xxxxxxxxxxxxx> Reviewed-by: Aurelien Aptel <aaptel@xxxxxxxx> CC: Stable <stable@xxxxxxxxxxxxxxx> --- fs/cifs/connect.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/cifs/connect.c b/fs/cifs/connect.c index c832a8a1970a..7aa08dba4719 100644 --- a/fs/cifs/connect.c +++ b/fs/cifs/connect.c @@ -2547,7 +2547,7 @@ cifs_setup_ipc(struct cifs_ses *ses, struct smb_vol *volume_info) if (tcon == NULL) return -ENOMEM; - snprintf(unc, sizeof(unc), "\\\\%s\\IPC$", ses->serverName); + snprintf(unc, sizeof(unc), "\\\\%s\\IPC$", ses->server->hostname); /* cannot fail */ nls_codepage = load_nls_default(); -- 2.17.1