s3:smbd/service disable case-sensitivity for SMB2/3 connections
authorChristian Ambach <ambi@samba.org>
Sun, 3 Apr 2016 03:06:05 +0000 (05:06 +0200)
committerJeremy Allison <jra@samba.org>
Tue, 3 May 2016 23:28:23 +0000 (01:28 +0200)
in SMB2, there is no flag to let us know if the client wants to have case-sensitive behavior,
so in Auto mode, disable case-sensitivity

Bug: https://bugzilla.samba.org/show_bug.cgi?id=11438
Signed-off-by: Christian Ambach <ambi@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/smbd/service.c

index 2777a09e8e290a6a981042e1eb6c9255a58eaf59..e4a910afa0b455066a3996116423742a05ec0225 100644 (file)
@@ -212,7 +212,9 @@ bool set_current_service(connection_struct *conn, uint16_t flags, bool do_chdir)
                        {
                                /* We need this uglyness due to DOS/Win9x clients that lie about case insensitivity. */
                                enum remote_arch_types ra_type = get_remote_arch();
-                               if ((ra_type != RA_SAMBA) && (ra_type != RA_CIFSFS)) {
+                               if (conn->sconn->using_smb2) {
+                                       conn->case_sensitive = false;
+                               } else if ((ra_type != RA_SAMBA) && (ra_type != RA_CIFSFS)) {
                                        /* Client can't support per-packet case sensitive pathnames. */
                                        conn->case_sensitive = False;
                                } else {