CVE-2022-50341 json
cifs: fix oops during encryption
published 2025-09-16 13 mo ago modified 2026-08-05 3 mo ago also EUVD-2022-55621
- cvss
- 7.8
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 0.1%
- EPSS 0.1% chance of exploitation in 30 days, percentile 1%
- public exploits
- 0
- none known
Summary
In the Linux kernel, the following vulnerability has been resolved:
cifs: fix oops during encryption
When running xfstests against Azure the following oops occurred on an arm64 system
Unable to handle kernel write to read-only memory at virtual address ffff0001221cf000 Mem abort info: ESR = 0x9600004f EC = 0x25: DABT (current EL), IL = 32 bits SET = 0, FnV = 0 EA = 0, S1PTW = 0 FSC = 0x0f: level 3 permission fault Data abort info: ISV = 0, ISS = 0x0000004f CM = 0, WnR = 1 swapper pgtable: 4k pages, 48-bit VAs, pgdp=00000000294f3000 [ffff0001221cf000] pgd=18000001ffff8003, p4d=18000001ffff8003, pud=18000001ff82e003, pmd=18000001ff71d003, pte=00600001221cf787 Internal error: Oops: 9600004f [#1] PREEMPT SMP ... pstate: 80000005 (Nzcv daif -PAN -UAO -TCO BTYPE=--) pc : __memcpy+0x40/0x230 lr : scatterwalk_copychunks+0xe0/0x200 sp : ffff800014e92de0 x29: ffff800014e92de0 x28: ffff000114f9de80 x27: 0000000000000008 x26: 0000000000000008 x25: ffff800014e92e78 x24: 0000000000000008 x23: 0000000000000001 x22: 0000040000000000 x21: ffff000000000000 x20: 0000000000000001 x19: ffff0001037c4488 x18: 0000000000000014 x17: 235e1c0d6efa9661 x16: a435f9576b6edd6c x15: 0000000000000058 x14: 0000000000000001 x13: 0000000000000008 x12: ffff000114f2e590 x11: ffffffffffffffff x10: 0000040000000000 x9 : ffff8000105c3580 x8 : 2e9413b10000001a x7 : 534b4410fb86b005 x6 : 534b4410fb86b005 x5 : ffff0001221cf008 x4 : ffff0001037c4490 x3 : 0000000000000001 x2 : 0000000000000008 x1 : ffff0001037c4488 x0 : ffff0001221cf000 Call trace: __memcpy+0x40/0x230 scatterwalk_map_and_copy+0x98/0x100 crypto_ccm_encrypt+0x150/0x180 crypto_aead_encrypt+0x2c/0x40 crypt_message+0x750/0x880 smb3_init_transform_rq+0x298/0x340 smb_send_rqst.part.11+0xd8/0x180 smb_send_rqst+0x3c/0x100 compound_send_recv+0x534/0xbc0 smb2_query_info_compound+0x32c/0x440 smb2_set_ea+0x438/0x4c0 cifs_xattr_set+0x5d4/0x7c0
This is because in scatterwalk_copychunks(), we attempted to write to a buffer (@sign) that was allocated in the stack (vmalloc area) by crypt_message() and thus accessing its remaining 8 (x2) bytes ended up crossing a page boundary.
To simply fix it, we could just pass @sign kmalloc'd from crypt_message() and then we're done. Luckily, we don't seem to pass any other vmalloc'd buffers in smb_rqst::rq_iov...
Instead, let's map the correct pages and offsets from vmalloc buffers as well in cifs_sg_set_buf() and then avoiding such oopses.
Patch / fix
- Linux Linux 5.4.229, 5.10.163, 5.15.87, 6.0.16, 6.1.1, 6.2
- linux Debian 14, Debian 13, Debian 12 6.1.4-1
debian advisories DEBIAN-CVE-2022-50341
- linux Ubuntu 20.04 LTS 5.4.0-144.161
- linux Ubuntu 22.04 LTS 5.15.0-69.76
- linux-aws Ubuntu 20.04 LTS 5.4.0-1097.105
- linux-aws Ubuntu 22.04 LTS 5.15.0-1033.37
- linux-gcp Ubuntu 20.04 LTS 5.4.0-1101.110
- linux-gcp Ubuntu 22.04 LTS 5.15.0-1031.38
- linux-gke Ubuntu 22.04 LTS 5.15.0-1030.35
- linux-ibm Ubuntu 20.04 LTS 5.4.0-1045.50
ubuntu advisories UBUNTU-CVE-2022-50341
Ubuntu security data © Canonical Ltd., from https://github.com/canonical/ubuntu-security-notices via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0
- kernel RHEL 8 4.18.0-553.27.1.el8_10
- perf RHEL 8 4.18.0-553.27.1.el8_10
- bpftool RHEL 8 4.18.0-553.27.1.el8_10
- kernel-core RHEL 8 4.18.0-553.27.1.el8_10
- kernel-tools RHEL 8 4.18.0-553.27.1.el8_10
- python3-perf RHEL 8 4.18.0-553.27.1.el8_10
- kernel-modules RHEL 8 4.18.0-553.27.1.el8_10
- kernel-zfcpdump RHEL 8 4.18.0-553.27.1.el8_10
red hat advisories RHSA-2026:2664RHSA-2026:1886RHSA-2025:22910RHSA-2025:22914RHSA-2025:22087RHSA-2025:22072
- kernel AlmaLinux 8 4.18.0-553.27.1.el8_10
- perf AlmaLinux 8 4.18.0-553.27.1.el8_10
- bpftool AlmaLinux 8 4.18.0-553.27.1.el8_10
- kernel-core AlmaLinux 8 4.18.0-553.27.1.el8_10
- kernel-tools AlmaLinux 8 4.18.0-553.27.1.el8_10
- python3-perf AlmaLinux 8 4.18.0-553.27.1.el8_10
- kernel-modules AlmaLinux 8 4.18.0-553.27.1.el8_10
- kernel-zfcpdump AlmaLinux 8 4.18.0-553.27.1.el8_10
almalinux advisories ALSA-2024:8856
- git.kernel.org/stable/c/e8e2861cc3258dbe407d01ea8c59bb5a53132301 commit
- git.kernel.org/stable/c/fe6ea044c4f05706cb71040055b1c70c6c8275e0 commit
- git.kernel.org/stable/c/bf0543b93740916ee91956f9a63da6fc0d79daaa commit
- git.kernel.org/stable/c/a13e51760703f71c25d5fc1f4a62dfa4b0cc80e9 commit
- git.kernel.org/stable/c/e8d16a54842d609fd4a3ed2d81d4333d6329aa94 commit
- git.kernel.org/stable/c/f7f291e14dde32a07b1f0aa06921d28f875a7b54 commit
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2022-50341 updated cvss 7.0
kernel: cifs: fix oops during encryption
-
Red Hat Enterprise Linux 6 perf, kernel, python-perf, kernel-kdump, kernel-firmware, kernel-bootwrapper, +1 moreaffected: workaround, no fix planned “Out of support scope”
-
Red Hat Enterprise Linux 8 kernel-rt, kernel-rt-kvm, kernel-rt-core, kernel-rt-modules, kernel-rt-debug-kvm, kernel-rt-debug-core, +6 more Red Hat Enterprise Linux 9 rv, perf, rtla, kernel, bpftool, libperf, +83 moreaffected: workaround, no fix available
-
Red Hat CodeReady Linux Builder EUS (v.9.2) kernel-debuginfo-common-s390x 5.14.0-284.95.1.el9_2, kernel-debuginfo-common-x86_64 5.14.0-284.95.1.el9_2, kernel-debuginfo-common-aarch64 5.14.0-284.95.1.el9_2, kernel-debuginfo-common-ppc64le 5.14.0-284.95.1.el9_2fixed: vendor fix RHSA-2024:10772
-
Red Hat Enterprise Linux AppStream E4S (v.9.0) perf 5.14.0-70.155.1.el9_0, kernel-devel-matched 5.14.0-70.155.1.el9_0, kernel-debug-devel-matched 5.14.0-70.155.1.el9_0, kernel-debuginfo-common-s390x 5.14.0-70.155.1.el9_0, kernel-zfcpdump-devel-matched 5.14.0-70.155.1.el9_0, kernel-debuginfo-common-x86_64 5.14.0-70.155.1.el9_0, +2 morefixed: vendor fix RHSA-2025:22066
-
Red Hat Enterprise Linux AppStream EUS (v.9.2) perf 5.14.0-284.95.1.el9_2, rtla 5.14.0-284.95.1.el9_2, kernel-devel-matched 5.14.0-284.95.1.el9_2, kernel-64k-devel-matched 5.14.0-284.95.1.el9_2, kernel-debug-devel-matched 5.14.0-284.95.1.el9_2, kernel-debuginfo-common-s390x 5.14.0-284.95.1.el9_2, +5 morefixed: vendor fix RHSA-2024:10772
-
Red Hat Enterprise Linux BaseOS (v. 8) perf 4.18.0-553.27.1.el8_10, kernel 4.18.0-553.27.1.el8_10, bpftool 4.18.0-553.27.1.el8_10, kernel-core 4.18.0-553.27.1.el8_10, kernel-tools 4.18.0-553.27.1.el8_10, python3-perf 4.18.0-553.27.1.el8_10, +15 morefixed: vendor fix RHSA-2024:8856
-
Red Hat Enterprise Linux BaseOS AUS (v. 8.2) perf 4.18.0-193.185.1.el8_2, kernel 4.18.0-193.185.1.el8_2, bpftool 4.18.0-193.185.1.el8_2, kernel-core 4.18.0-193.185.1.el8_2, kernel-tools 4.18.0-193.185.1.el8_2, python3-perf 4.18.0-193.185.1.el8_2, +8 morefixed: vendor fix RHSA-2026:2664
-
Red Hat Enterprise Linux BaseOS AUS (v.8.4) perf 4.18.0-305.184.1.el8_4, kernel 4.18.0-305.184.1.el8_4, bpftool 4.18.0-305.184.1.el8_4, kernel-core 4.18.0-305.184.1.el8_4, kernel-tools 4.18.0-305.184.1.el8_4, python3-perf 4.18.0-305.184.1.el8_4, +8 morefixed: vendor fix RHSA-2026:1886
show 12 moreshow fewer
-
Red Hat Enterprise Linux BaseOS AUS (v.8.6) perf 4.18.0-372.170.1.el8_6, kernel 4.18.0-372.170.1.el8_6, bpftool 4.18.0-372.170.1.el8_6, kernel-core 4.18.0-372.170.1.el8_6, kernel-tools 4.18.0-372.170.1.el8_6, python3-perf 4.18.0-372.170.1.el8_6, +8 more Red Hat Enterprise Linux BaseOS E4S (v.8.6) perf 4.18.0-372.170.1.el8_6, kernel 4.18.0-372.170.1.el8_6, bpftool 4.18.0-372.170.1.el8_6, kernel-core 4.18.0-372.170.1.el8_6, kernel-tools 4.18.0-372.170.1.el8_6, python3-perf 4.18.0-372.170.1.el8_6, +15 morefixed: vendor fix RHSA-2025:22006
-
Red Hat Enterprise Linux BaseOS E4S (v.8.8) perf 4.18.0-477.120.1.el8_8, kernel 4.18.0-477.120.1.el8_8, bpftool 4.18.0-477.120.1.el8_8, kernel-core 4.18.0-477.120.1.el8_8, kernel-tools 4.18.0-477.120.1.el8_8, python3-perf 4.18.0-477.120.1.el8_8, +9 morefixed: vendor fix RHSA-2025:22072
-
Red Hat Enterprise Linux BaseOS E4S (v.9.0) kernel 5.14.0-70.155.1.el9_0, bpftool 5.14.0-70.155.1.el9_0, kernel-core 5.14.0-70.155.1.el9_0, kernel-tools 5.14.0-70.155.1.el9_0, python3-perf 5.14.0-70.155.1.el9_0, kernel-modules 5.14.0-70.155.1.el9_0, +14 morefixed: vendor fix RHSA-2025:22066
-
Red Hat Enterprise Linux BaseOS EUS (v.9.2) bpftool 7.0.0-284.95.1.el9_2, kernel 5.14.0-284.95.1.el9_2, kernel-64k 5.14.0-284.95.1.el9_2, kernel-core 5.14.0-284.95.1.el9_2, kernel-tools 5.14.0-284.95.1.el9_2, python3-perf 5.14.0-284.95.1.el9_2, +28 morefixed: vendor fix RHSA-2024:10772
-
Red Hat Enterprise Linux BaseOS EUS EXTENSION (v.8.4) perf 4.18.0-305.184.1.el8_4, kernel 4.18.0-305.184.1.el8_4, bpftool 4.18.0-305.184.1.el8_4, kernel-core 4.18.0-305.184.1.el8_4, kernel-tools 4.18.0-305.184.1.el8_4, python3-perf 4.18.0-305.184.1.el8_4, +8 morefixed: vendor fix RHSA-2026:1886
-
Red Hat Enterprise Linux BaseOS TUS (v.8.6) perf 4.18.0-372.170.1.el8_6, kernel 4.18.0-372.170.1.el8_6, bpftool 4.18.0-372.170.1.el8_6, kernel-core 4.18.0-372.170.1.el8_6, kernel-tools 4.18.0-372.170.1.el8_6, python3-perf 4.18.0-372.170.1.el8_6, +8 morefixed: vendor fix RHSA-2025:22006
-
Red Hat Enterprise Linux BaseOS TUS (v.8.8) perf 4.18.0-477.120.1.el8_8, kernel 4.18.0-477.120.1.el8_8, bpftool 4.18.0-477.120.1.el8_8, kernel-core 4.18.0-477.120.1.el8_8, kernel-tools 4.18.0-477.120.1.el8_8, python3-perf 4.18.0-477.120.1.el8_8, +8 morefixed: vendor fix RHSA-2025:22072
-
Red Hat Enterprise Linux CRB (v. 8) kernel-debuginfo-common-x86_64 4.18.0-553.27.1.el8_10, kernel-debuginfo-common-aarch64 4.18.0-553.27.1.el8_10, kernel-debuginfo-common-ppc64le 4.18.0-553.27.1.el8_10fixed: vendor fix RHSA-2024:8856
-
Red Hat Enterprise Linux for Real Time (v. 7 ELS) kernel-rt 3.10.0-1160.143.1.rt56.1295.el7, kernel-rt-trace 3.10.0-1160.143.1.rt56.1295.el7, kernel-rt-debuginfo-common-x86_64 3.10.0-1160.143.1.rt56.1295.el7fixed: vendor fix RHSA-2025:22914
-
Red Hat Enterprise Linux NFV E4S (v.9.0) kernel-rt 5.14.0-70.155.1.rt21.227.el9_0, kernel-rt-kvm 5.14.0-70.155.1.rt21.227.el9_0, kernel-rt-core 5.14.0-70.155.1.rt21.227.el9_0, kernel-rt-modules 5.14.0-70.155.1.rt21.227.el9_0, kernel-rt-debug-kvm 5.14.0-70.155.1.rt21.227.el9_0, kernel-rt-debug-core 5.14.0-70.155.1.rt21.227.el9_0, +4 more Red Hat Enterprise Linux Real Time E4S (v.9.0) kernel-rt 5.14.0-70.155.1.rt21.227.el9_0, kernel-rt-core 5.14.0-70.155.1.rt21.227.el9_0, kernel-rt-modules 5.14.0-70.155.1.rt21.227.el9_0, kernel-rt-debug-core 5.14.0-70.155.1.rt21.227.el9_0, kernel-rt-debug-modules 5.14.0-70.155.1.rt21.227.el9_0, kernel-rt-modules-extra 5.14.0-70.155.1.rt21.227.el9_0, +2 morefixed: vendor fix RHSA-2025:22087
-
Red Hat Enterprise Linux Server (v. 7 ELS) perf 3.10.0-1160.143.1.el7, kernel 3.10.0-1160.143.1.el7, bpftool 3.10.0-1160.143.1.el7, python-perf 3.10.0-1160.143.1.el7, kernel-kdump 3.10.0-1160.143.1.el7, kernel-tools 3.10.0-1160.143.1.el7, +7 more Red Hat Enterprise Linux Server Optional (v. 7 ELS) kernel-debuginfo-common-ppc64 3.10.0-1160.143.1.el7, kernel-debuginfo-common-x86_64 3.10.0-1160.143.1.el7, kernel-debuginfo-common-ppc64le 3.10.0-1160.143.1.el7fixed: vendor fix RHSA-2025:22910
-
Red Hat Enterprise Linux 10 kernelnot affected: vulnerable code not present
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
CISA SSVC
- Exploitation
- none
- Automatable
- no
- Technical impact
- partial
- Assessed
- 9 mo ago
Exploit prediction
0.11% chance of exploitation in the next 30 days, higher than 1% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CNA | 3.1 | 7.8 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
| CISA ADP | 3.1 | 5.5 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H |
| NVD | 3.1 | 5.5 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H |
| CNA | 3.1 | 5.5 | CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H |
Affected products
- Linux Linux
Classification
- Technology feeds
References
-
git.kernel.org
/stable/c/e8e2861cc3258dbe407d01ea8c59bb5a53132301
patch
-
git.kernel.org
/stable/c/fe6ea044c4f05706cb71040055b1c70c6c8275e0
patch
-
git.kernel.org
/stable/c/bf0543b93740916ee91956f9a63da6fc0d79daaa
patch
-
git.kernel.org
/stable/c/a13e51760703f71c25d5fc1f4a62dfa4b0cc80e9
patch
-
git.kernel.org
/stable/c/e8d16a54842d609fd4a3ed2d81d4333d6329aa94
patch
-
git.kernel.org
/stable/c/f7f291e14dde32a07b1f0aa06921d28f875a7b54
patch
Sources
- CVE List CVE-2022-50341
- NVD CVE-2022-50341
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.