Laura Abbott
e9ec911158
sunrpc: Don't use stack buffer with scatterlist
...
[ Upstream commit 44090cc876926277329e1608bafc01b9f6da627f ]
Fedora got a bug report from NFS:
kernel BUG at include/linux/scatterlist.h:143!
...
RIP: 0010:sg_init_one+0x7d/0x90
..
make_checksum+0x4e7/0x760 [rpcsec_gss_krb5]
gss_get_mic_kerberos+0x26e/0x310 [rpcsec_gss_krb5]
gss_marshal+0x126/0x1a0 [auth_rpcgss]
? __local_bh_enable_ip+0x80/0xe0
? call_transmit_status+0x1d0/0x1d0 [sunrpc]
call_transmit+0x137/0x230 [sunrpc]
__rpc_execute+0x9b/0x490 [sunrpc]
rpc_run_task+0x119/0x150 [sunrpc]
nfs4_run_exchange_id+0x1bd/0x250 [nfsv4]
_nfs4_proc_exchange_id+0x2d/0x490 [nfsv4]
nfs41_discover_server_trunking+0x1c/0xa0 [nfsv4]
nfs4_discover_server_trunking+0x80/0x270 [nfsv4]
nfs4_init_client+0x16e/0x240 [nfsv4]
? nfs_get_client+0x4c9/0x5d0 [nfs]
? _raw_spin_unlock+0x24/0x30
? nfs_get_client+0x4c9/0x5d0 [nfs]
nfs4_set_client+0xb2/0x100 [nfsv4]
nfs4_create_server+0xff/0x290 [nfsv4]
nfs4_remote_mount+0x28/0x50 [nfsv4]
mount_fs+0x3b/0x16a
vfs_kern_mount.part.35+0x54/0x160
nfs_do_root_mount+0x7f/0xc0 [nfsv4]
nfs4_try_mount+0x43/0x70 [nfsv4]
? get_nfs_version+0x21/0x80 [nfs]
nfs_fs_mount+0x789/0xbf0 [nfs]
? pcpu_alloc+0x6ca/0x7e0
? nfs_clone_super+0x70/0x70 [nfs]
? nfs_parse_mount_options+0xb40/0xb40 [nfs]
mount_fs+0x3b/0x16a
vfs_kern_mount.part.35+0x54/0x160
do_mount+0x1fd/0xd50
ksys_mount+0xba/0xd0
__x64_sys_mount+0x21/0x30
do_syscall_64+0x60/0x1f0
entry_SYSCALL_64_after_hwframe+0x49/0xbe
This is BUG_ON(!virt_addr_valid(buf)) triggered by using a stack
allocated buffer with a scatterlist. Convert the buffer for
rc4salt to be dynamically allocated instead.
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1615258
Signed-off-by: Laura Abbott <labbott@redhat.com>
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-09-15 09:42:57 +02:00
..
2016-09-19 20:19:34 +02:00
2018-09-09 20:01:22 +02:00
2018-04-13 19:48:34 +02:00
2016-09-10 21:19:10 -07:00
2018-05-16 10:08:44 +02:00
2017-02-04 09:47:09 +01:00
2018-08-24 13:12:31 +02:00
2018-08-22 07:47:15 +02:00
2018-07-22 14:27:39 +02:00
2018-09-05 09:20:00 +02:00
2018-01-31 12:55:50 +01:00
2018-05-01 15:13:09 -07:00
2018-08-24 13:12:30 +02:00
2016-12-03 23:54:25 -05:00
2018-08-22 07:47:13 +02:00
2018-02-25 11:05:44 +01:00
2018-07-22 14:27:39 +02:00
2018-08-06 16:23:03 +02:00
2017-02-18 15:11:43 +01:00
2018-04-13 19:48:29 +02:00
2018-09-09 20:01:19 +02:00
2018-09-15 09:42:56 +02:00
2018-09-15 09:42:56 +02:00
2017-05-25 15:44:41 +02:00
2017-08-30 10:21:42 +02:00
2018-03-31 18:11:34 +02:00
2018-06-13 16:16:42 +02:00
2018-06-16 09:52:32 +02:00
2018-08-22 07:47:13 +02:00
2016-09-10 23:12:53 -07:00
2018-08-22 07:47:13 +02:00
2018-09-05 09:19:59 +02:00
2018-09-09 20:01:19 +02:00
2018-03-11 16:21:34 +01:00
2016-10-20 11:23:08 -04:00
2018-08-24 13:12:41 +02:00
2018-05-30 07:50:51 +02:00
2018-08-09 12:17:59 +02:00
2018-07-22 14:27:40 +02:00
2018-05-30 07:50:23 +02:00
2018-08-24 13:12:41 +02:00
2018-08-24 13:12:36 +02:00
2018-07-22 14:27:39 +02:00
2018-05-16 10:08:43 +02:00
2018-05-30 07:50:42 +02:00
2018-09-15 09:42:56 +02:00
2018-09-15 09:42:56 +02:00
2018-04-29 11:32:02 +02:00
2018-09-15 09:42:57 +02:00
2016-10-19 10:58:04 -04:00
2018-04-29 11:32:01 +02:00
2017-11-18 11:22:22 +01:00
2018-08-22 07:47:13 +02:00
2018-09-05 09:19:59 +02:00
2018-04-13 19:48:00 +02:00
2018-09-05 09:19:59 +02:00
2018-05-19 10:26:58 +02:00
2016-08-17 19:36:23 -04:00
2016-08-17 19:36:23 -04:00
2018-08-06 16:23:04 +02:00
2016-10-06 09:52:23 -07:00