From: Aurelien Aptel <aaptel-IBi9RG/b67k@public.gmane.org>
To: linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Cc: Aurelien Aptel <aaptel-IBi9RG/b67k@public.gmane.org>
Subject: [PATCH v2 4/6] CIFS: set signing flag in SMB2+ TreeConnect if needed
Date: Thu, 23 Feb 2017 15:43:32 +0100 [thread overview]
Message-ID: <20170223144334.22320-5-aaptel@suse.com> (raw)
In-Reply-To: <20170223144334.22320-1-aaptel-IBi9RG/b67k@public.gmane.org>
cifs_enable_signing() already sets server->sign according to what the
server requires/offers and what mount options allows/forbids, so use
that.
this is required for IPC tcon that connects to signing-required servers.
Signed-off-by: Aurelien Aptel <aaptel-IBi9RG/b67k@public.gmane.org>
---
fs/cifs/smb2pdu.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/cifs/smb2pdu.c b/fs/cifs/smb2pdu.c
index ad83b3d..c9a1d71 100644
--- a/fs/cifs/smb2pdu.c
+++ b/fs/cifs/smb2pdu.c
@@ -1167,8 +1167,8 @@ SMB2_tcon(const unsigned int xid, struct cifs_ses *ses, const char *tree,
/* since no tcon, smb2_init can not do this, so do here */
req->hdr.sync_hdr.SessionId = ses->Suid;
- /* if (ses->server->sec_mode & SECMODE_SIGN_REQUIRED)
- req->hdr.Flags |= SMB2_FLAGS_SIGNED; */
+ if (ses->server->sign)
+ req->hdr.sync_hdr.Flags |= SMB2_FLAGS_SIGNED;
} else if (encryption_required(tcon))
flags |= CIFS_TRANSFORM_REQ;
--
2.10.2
next prev parent reply other threads:[~2017-02-23 14:43 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-23 14:43 [PATCH v2 0/6] Add support for DFS in SMB2+ Aurelien Aptel
[not found] ` <20170223144334.22320-1-aaptel-IBi9RG/b67k@public.gmane.org>
2017-02-23 14:43 ` [PATCH v2 1/6] CIFS: move DFS response parsing out of SMB1 code Aurelien Aptel
2017-02-23 14:43 ` [PATCH v2 2/6] CIFS: add build_path_from_dentry_optional_prefix() Aurelien Aptel
2017-02-23 14:43 ` [PATCH v2 3/6] CIFS: implement get_dfs_refer for SMB2+ Aurelien Aptel
[not found] ` <20170223144334.22320-4-aaptel-IBi9RG/b67k@public.gmane.org>
2017-02-24 1:06 ` Pavel Shilovsky
[not found] ` <CAKywueSCHszmzBbfLfJTP66=w6FcKgR2p1UJJig4uxcgC4QSfA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2017-02-24 15:25 ` Aurélien Aptel
[not found] ` <mpsvarzfw5r.fsf-zpEvHKhluMwYitT5tn2FcQ@public.gmane.org>
2017-02-24 19:50 ` Pavel Shilovsky
[not found] ` <mpsshmzg1ka.fsf@aaptelpc.suse.de>
[not found] ` <mpsshmzg1ka.fsf-zpEvHKhluMwYitT5tn2FcQ@public.gmane.org>
2017-02-28 18:44 ` Aurélien Aptel
2017-03-01 2:34 ` Pavel Shilovsky
2017-02-23 14:43 ` Aurelien Aptel [this message]
2017-02-23 14:43 ` [PATCH v2 5/6] CIFS: use DFS pathnames in SMB2+ Create requests Aurelien Aptel
2017-02-23 14:43 ` [PATCH v2 6/6] CIFS: enable get_dfs_refer for SMB2+ Aurelien Aptel
2017-02-23 22:40 ` [PATCH v2 0/6] Add support for DFS in SMB2+ Pavel Shilovsky
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170223144334.22320-5-aaptel@suse.com \
--to=aaptel-ibi9rg/b67k@public.gmane.org \
--cc=linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox