Fix CVE-2026-71227
Fix infinite loop denial of service in libkcapi _kcapi_aio_read_all() due to unhandled io_getevents() timeout return Resolves: RHEL-224976 Signed-off-by: Zoltan Fridrich <zfridric@redhat.com>
This commit is contained in:
parent
3a085e4cca
commit
351138c3d0
22
008-CVE-2026-71227.patch
Normal file
22
008-CVE-2026-71227.patch
Normal file
@ -0,0 +1,22 @@
|
||||
diff --git a/lib/kcapi-kernel-if.c b/lib/kcapi-kernel-if.c
|
||||
index 8a12c09..a54cdaa 100644
|
||||
--- a/lib/kcapi-kernel-if.c
|
||||
+++ b/lib/kcapi-kernel-if.c
|
||||
@@ -436,6 +436,8 @@ int _kcapi_aio_read_all(struct kcapi_handle *handle, size_t toread,
|
||||
|
||||
if (rc < 0)
|
||||
return err == 0 ? rc : err;
|
||||
+ if (rc == 0)
|
||||
+ return err == 0 ? -ETIMEDOUT : err;
|
||||
|
||||
for (i = 0; i < rc; i++) {
|
||||
struct iocb *cb;
|
||||
@@ -509,7 +511,7 @@ int _kcapi_aio_read_iov(struct kcapi_handle *handle,
|
||||
timeout.tv_sec = 0;
|
||||
timeout.tv_nsec = 10000;
|
||||
ret = _kcapi_aio_read_all(handle, iovlen, &timeout);
|
||||
- if (ret < 0)
|
||||
+ if (ret < 0 && ret != -ETIMEDOUT)
|
||||
return ret;
|
||||
}
|
||||
|
||||
@ -140,6 +140,7 @@ Patch4: 004-hasher-target-option.patch
|
||||
Patch5: 005-fips-mode-tests.patch
|
||||
Patch6: 006-aead-tag-verification.patch
|
||||
Patch7: 007-CVE-2026-71226.patch
|
||||
Patch8: 008-CVE-2026-71227.patch
|
||||
|
||||
BuildRequires: bash
|
||||
BuildRequires: coreutils
|
||||
@ -530,6 +531,9 @@ popd
|
||||
- CVE-2026-71226: Fix memory corruption via uncanceled AIO requests
|
||||
on error in libkcapi's one-shot AIO path
|
||||
Resolves: RHEL-224815
|
||||
- CVE-2026-71227: Fix infinite loop denial of service in libkcapi
|
||||
_kcapi_aio_read_all() due to unhandled io_getevents() timeout return
|
||||
Resolves: RHEL-224976
|
||||
|
||||
* Fri Dec 01 2023 Zoltan Fridrich <zfridric@redhat.com> - 1.4.0-2
|
||||
- Backport fixes for kcapi-hasher target option
|
||||
|
||||
Loading…
Reference in New Issue
Block a user