Related Vulnerabilities: CVE-2022-0847  

A flaw was found in the way the "flags" member of the new pipe buffer structure was lacking proper initialization in copy_page_to_iter_pipe and push_pipe functions in the Linux kernel and could thus contain stale values. An unprivileged local user could use this flaw to write to pages in the page cache backed by read only files and as such escalate their privileges on the system.

Description

A flaw was found in the way the "flags" member of the new pipe buffer structure was lacking proper initialization in copy_page_to_iter_pipe and push_pipe functions in the Linux kernel and could thus contain stale values. An unprivileged local user could use this flaw to write to pages in the page cache backed by read only files and as such escalate their privileges on the system.

Statement

Red Hat Product Security is aware of this issue. Updates will be released as they become available. Note that PIPE_BUF_FLAG_CAN_MERGE flag attack vector is not available in Red Hat Enterprise Linux 8 and thus the currently known exploits leveraging this flag do not work. The underlying issue (lack of proper pipe_buffer structure initialization) is still present though and other novel ways leading to successful exploitation cannot be fully ruled out.

Red Hat Product Security is aware of this issue. Updates will be released as they become available.

Note that PIPE_BUF_FLAG_CAN_MERGE flag attack vector is not available in Red Hat Enterprise Linux 8 and thus the currently known exploits leveraging this flag do not work. The underlying issue (lack of proper pipe_buffer structure initialization) is still present though and other novel ways leading to successful exploitation cannot be fully ruled out.

Mitigation

Currently there is no mitigation available for this flaw. Customers should update to fixed packages, once they are available.

Additional Information

  • Bugzilla 2060795: CVE-2022-0847 kernel: improper initialization of the "flags" member of the new pipe_buffer
  • CWE-665->CWE-281: Improper Initialization leads to Improper Preservation of Permissions
  • FAQ: Frequently asked questions about CVE-2022-0847