Skip to content
Memory corruption Advisory Advanced CVE-2023-27934

Apple DCERPC call request uninitialized memory heap overflow vulnerability

A heap overflow vulnerability in Apple's DCERPC library allows a remote or local attacker to trigger use of uninitialized memory by sending a specially crafted network packet, potentially leading to arbitrary code execution.

Aleksandar Nikolic Follow

Originally disclosed on Cisco Talos

High 7.5 View original

A heap overflow vulnerability exists in the request processing functionality of DCERPC library as used in Apple macOS 12.6.1 that can lead to use of uninitialized memory. A specially-crafted network packet can cause use of uninitialized memory which can lead to heap overflow and arbitrary code execution.

Aleksandar Nikolic, on Cisco Talos

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Root cause

The code fails to initialize the iovector length field when processing a MAYBE call, leaving it with an uninitialized value that is later used as a loop bound, leading to a heap overflow.

Impact

A remote attacker could potentially achieve arbitrary code execution by controlling the uninitialized memory contents, though the report notes that this would require multiple simultaneous connections and precise timing.

What the attacker needed

Network access to SMB service or local UNIX socket access; authentication for network vector

The fix

The vulnerability was fixed by Apple on 2023-03-27.

How it was found

  1. Send a bind request packet to reach the proper state of the state machine.
  2. Send a subsequent RPC call request with the MAYBE flag set.
  3. The uninitialized num_elt value causes an out-of-bounds access in rpc__cn_call_end.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

This report describes a memory safety bug in a network service on macOS. When a particular type of request is sent, the program uses a value that was never set, which can cause it to read or write outside its intended memory, potentially letting an attacker run their own code.

What is Memory corruption?

Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.

More by Aleksandar Nikolic

View all

147 more disclosed reports, best first.

More from Cisco Talos

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Memory corruption

The lesson behind this report.

Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.