linux/fs/cifs
Pavel Shilovsky d0d2a4c829 CIFS: Fix a possible memory corruption during reconnect
[ Upstream commit 53e0e11efe ]

We can not unlock/lock cifs_tcp_ses_lock while walking through ses
and tcon lists because it can corrupt list iterator pointers and
a tcon structure can be released if we don't hold an extra reference.
Fix it by moving a reconnect process to a separate delayed work
and acquiring a reference to every tcon that needs to be reconnected.
Also do not send an echo request on newly established connections.

CC: Stable <stable@vger.kernel.org>
Signed-off-by: Pavel Shilovsky <pshilov@microsoft.com>
Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
History 2017-01-15 09:49:51 -05:00
..
asn1.c [CIFS] cifs: Rename cERROR and cFYI to cifs_dbg 2013-05-04 22:17:23 -05:00
cache.c [CIFS] cifs: Rename cERROR and cFYI to cifs_dbg 2013-05-04 22:17:23 -05:00
cifs_debug.c cifs: Ratelimit kernel log messages 2016-02-09 22:57:06 -05:00
cifs_debug.h cifs: Ratelimit kernel log messages 2016-02-09 22:57:06 -05:00
cifs_dfs_ref.c cifs: replace strnicmp with strncasecmp 2014-10-14 02:18:24 +02:00
cifs_fs_sb.h fs/cifs: make share unaccessible at root level mountable 2016-08-22 12:23:19 -04:00
cifs_spnego.c cifs: Create dedicated keyring for spnego operations 2016-06-06 19:11:09 -04:00
cifs_spnego.h [CIFS] Rename three structures to avoid camel case 2011-05-27 04:34:02 +00:00
cifs_unicode.c File names with trailing period or space need special case conversion 2016-07-12 08:47:09 -04:00
cifs_unicode.h File names with trailing period or space need special case conversion 2016-07-12 08:47:09 -04:00
cifs_uniupr.h cifs: correction of unicode header files 2010-08-20 00:46:42 +00:00
cifsacl.c KEYS: Remove key_type::match in favour of overriding default by match_preparse 2014-09-16 17:36:06 +01:00
cifsacl.h cifs: fix SID binary to string conversion 2012-12-11 11:48:49 -06:00
cifsencrypt.c cifs: fix crash due to race in hmac(md5) handling 2016-08-22 12:23:14 -04:00
cifsfs.c fs/cifs: make share unaccessible at root level mountable 2016-08-22 12:23:19 -04:00
cifsfs.h Fix cifs_uniqueid_to_ino_t() function for s390x 2016-03-11 09:45:23 -05:00
cifsglob.h CIFS: Fix a possible memory corruption during reconnect 2017-01-15 09:49:51 -05:00
cifspdu.h Add missing definitions for CIFS File System Attributes 2014-08-12 23:47:14 -05:00
cifsproto.h CIFS: Fix a possible memory corruption during reconnect 2017-01-15 09:49:51 -05:00
cifssmb.c CIFS: Fix SMB2+ interim response processing for read requests 2016-03-11 09:45:23 -05:00
connect.c CIFS: Fix a possible memory corruption during reconnect 2017-01-15 09:49:51 -05:00
dir.c fs/cifs: make share unaccessible at root level mountable 2016-08-22 12:23:19 -04:00
dns_resolve.c cifs: fix composing of mount options for DFS referrals 2013-05-24 13:08:31 -05:00
dns_resolve.h DNS: Separate out CIFS DNS Resolver code 2010-08-05 17:17:51 +00:00
export.c [CIFS] cifs: Rename cERROR and cFYI to cifs_dbg 2013-05-04 22:17:23 -05:00
file.c cifs: fix use-after-free bug in find_writable_file 2015-04-24 17:14:01 -04:00
fscache.c NFS client updates for Linux 3.13 2013-11-08 05:57:46 +09:00
fscache.h CIFS: FS-Cache: Uncache unread pages in cifs_readpages() before freeing them 2013-09-18 10:17:03 -05:00
inode.c fs/cifs: make share unaccessible at root level mountable 2016-08-22 12:23:19 -04:00
ioctl.c CIFS: fix type confusion in copy offload ioctl 2015-10-07 10:14:50 -04:00
Kconfig Clarify Kconfig help text for CIFS and SMB2/SMB3 2014-08-25 17:01:05 -05:00
link.c [CIFS] Remove obsolete comment 2014-10-17 17:17:12 -05:00
Makefile cifs: add new case-insensitive conversion routines that are based on wchar_t's 2013-09-08 14:38:05 -05:00
misc.c cifs: convert to print_hex_dump() instead of custom implementation 2016-02-09 22:57:05 -05:00
netmisc.c [CIFS] Fix setting time before epoch (negative time values) 2014-09-14 17:06:36 -05:00
nterr.c CIFS: Rename 7 error codes to NT_ style 2012-07-24 10:25:10 -05:00
nterr.h CIFS: Rename 7 error codes to NT_ style 2012-07-24 10:25:10 -05:00
ntlmssp.h cifs: dynamic allocation of ntlmssp blob 2016-07-12 08:47:06 -04:00
readdir.c cifs_dbg() outputs an uninitialized buffer in cifs_readdir() 2016-02-09 22:57:06 -05:00
rfc1002pdu.h [CIFS] whitespace cleanup 2007-06-05 18:30:44 +00:00
sess.c cifs: dynamic allocation of ntlmssp blob 2016-07-12 08:47:06 -04:00
smb1ops.c Remap reserved posix characters by default (part 3/3) 2014-10-16 15:20:20 -05:00
smb2file.c CIFS: Fix a possible memory corruption in push locks 2017-01-15 09:49:51 -05:00
smb2glob.h remove directory incorrectly tries to set delete on close on non-empty directories 2016-06-06 19:11:07 -04:00
smb2inode.c remove directory incorrectly tries to set delete on close on non-empty directories 2016-06-06 19:11:07 -04:00
smb2maperror.c Fix problem recognizing symlinks 2014-10-02 14:10:04 -05:00
smb2misc.c Allow conversion of characters in Mac remap range (part 2) 2014-10-16 15:20:20 -05:00
smb2ops.c CIFS: Fix a possible invalid memory access in smb2_query_symlink() 2016-08-22 12:23:20 -04:00
smb2pdu.c CIFS: Fix a possible memory corruption during reconnect 2017-01-15 09:49:51 -05:00
smb2pdu.h add defines for two new file attributes 2014-10-16 15:20:19 -05:00
smb2proto.h CIFS: Fix a possible memory corruption during reconnect 2017-01-15 09:49:51 -05:00
smb2status.h CIFS: Add SMB2 status codes 2012-07-24 10:25:13 -05:00
smb2transport.c CIFS: Use multicredits for SMB 2.1/3 writes 2014-08-02 01:23:03 -05:00
smbencrypt.c Remap reserved posix characters by default (part 3/3) 2014-10-16 15:20:20 -05:00
smberr.h cifs: map NT_STATUS_ERROR_WRITE_PROTECTED to -EROFS 2010-08-02 12:40:40 +00:00
smbfsctl.h enable fallocate punch hole ("fallocate -p") for SMB3 2014-08-17 18:12:38 -05:00
transport.c cifs: fix race between call_async() and reconnect() 2016-02-09 22:57:06 -05:00
winucase.c [CIFS] quiet sparse compile warning 2013-09-08 14:54:24 -05:00
xattr.c Remap reserved posix characters by default (part 3/3) 2014-10-16 15:20:20 -05:00