Skip to content
Memory corruption Advisory Advanced CVE-2024-9955

Use after free in Web Authentication (CVE-2024-9955)

A use-after-free flaw in Chromium's WebAuthn Enclave Authenticator occurs when a WebSocket connection is established and pending data is sent, but the connection drops during the send, causing the object to delete itself and then access a member variable. An attacker could potentially trigger a browser crash or memory corruption, though the report only demonstrates a crash in a test environment.

anonymous Follow

Originally disclosed on Chrome VRP

Bounty$6,000 Medium View original
  • Fix shipped in 17 days

VULNERABILITY DETAILS

In WebAuthn, the Enclave Authenticator uses WebSockets to communicate with server. Every time when performing a transaction with the enclave, a websocket connection would be initialized. In function EnclaveWebSocketClient::OnConnectionEstablished, if there is pending data to send, it calls InternalWrite and then resets pending_write_data_ [1]. However, InternalWrite may call to ClosePipe and delete itself [2], which results in UAF when accessing the member variable pending_write_data_.

This is because EnclaveWebSocketClient::OnConnectionEstablished calls WebSockets.StartReceiving before sending data through the writable data pipe [3]. The mojo call StartReceiving tells the Network Service to read more frame from the remote side, and if the connection has been closed (e.g. due to network error or server response), it will drop the channel and reset all data pipe [4]. In this case, EnclaveWebSocketClient will fail to send message and destroy itself.

C++
void EnclaveWebSocketClient::OnConnectionEstablished(...) {
  websocket_->StartReceiving();      // ===> [3]

  state_ = State::kOpen;

  if (pending_write_data_) {
    InternalWrite(*pending_write_data_);
    pending_write_data_ = std::nullopt;      // ===> [1] UAF here
  }
}

void EnclaveWebSocketClient::InternalWrite(base::span<const uint8_t> data) {
  CHECK(state_ == State::kOpen);

  websocket_->SendMessage(network::mojom::WebSocketMessageType::BINARY,
                          data.size());
  MojoResult result = writable_->WriteAllData(data);
  if (result != MOJO_RESULT_OK) {
    FIDO_LOG(ERROR) << "Failed to write to WebSocket.";
    ClosePipe(SocketStatus::kError);      // ===> [2] delete this
  }
}

void WebSocket::WebSocketEventHandler::OnDropChannel(
    bool was_clean,
    uint16_t code,
    const std::string& reason) {
  impl_->client_->OnDropChannel(was_clean, code, reason);
  impl_->Reset();      // ===> [4]
}

[1] https://source.chromium.org/chromium/chromium/src/+/main:device/fido/enclave/enclave_websocket_client.cc;l=208;drc=9ffdf5bc515eeb4e7f308a74477f0b28cc96f029

[2] https://source.chromium.org/chromium/chromium/src/+/main:device/fido/enclave/enclave_websocket_client.cc;l=156;drc=f522344e45882da4c7f7cb1b3a0a7bd747d654bb

[3] https://source.chromium.org/chromium/chromium/src/+/main:device/fido/enclave/enclave_websocket_client.cc;l=202;drc=9ffdf5bc515eeb4e7f308a74477f0b28cc96f029

[4] https://source.chromium.org/chromium/chromium/src/+/main:services/network/websocket.cc;l=317;drc=f522344e45882da4c7f7cb1b3a0a7bd747d654bb

VERSION

Chrome Version: beta + dev

REPRODUCTION CASE

It requires a signed-in user calls navigator.credentials related JS API to trigger this, however signing in to custom build Chromium is normally restricted and I don't find a way to fake a signed-in user without a large code patch. So I reuse the browser test code for a easy reproduction in local asan environment.

Tested on Chromium version 131.0.6735.0, Linux platform

  1. Apply the attached patch.diff
  2. Run ninja -C out/Asan browser_tests out/Asan/browser_tests --gtest_filter=EnclaveAuthenticatorWithPinBrowserTest.RegisterDeviceWithGpmPin_MakeCredential_Success

FOR CRASHES, PLEASE INCLUDE THE FOLLOWING ADDITIONAL INFORMATION

Type of crash: browser Crash State: see asan.log for details

Bisection

This was introduced in https://chromium.googlesource.com/chromium/src/+/9934f322060c9808cff85f64af8448c4f608826f

Fix Suggestion

Use a stack-alloc variable to hold value of pending_write_data_ and clear pending_write_data_ before calling InternalWrite.

Diff
diff --git a/device/fido/enclave/enclave_websocket_client.cc b/device/fido/enclave/enclave_websocket_client.cc
index b3d42475d53ee..4bb2d9c5cc05c 100644
--- a/device/fido/enclave/enclave_websocket_client.cc
+++ b/device/fido/enclave/enclave_websocket_client.cc
@@ -204,8 +204,8 @@ void EnclaveWebSocketClient::OnConnectionEstablished(
   state_ = State::kOpen;
 
   if (pending_write_data_) {
-    InternalWrite(*pending_write_data_);
-    pending_write_data_ = std::nullopt;
+    auto pending_write_data = std::exchange(pending_write_data_, std::nullopt).value();
+    InternalWrite(pending_write_data);
   }
 }

The original report as published on the Chromium issue tracker, by anonymous. Images and videos are our own copies; raw HTML is shown as text. View it on Chromium issue tracker.

Written with AI from the full original report and checked against it passage by passage; anything it could not back up was removed or toned down. The original is the record. 4 min read.

Context

This is a use-after-free in Chrome's Web Authentication implementation, specifically in the Enclave Authenticator. The Enclave Authenticator uses WebSockets to talk to a server, and every time a transaction is performed with the enclave a new WebSocket connection is initialised. The bug lives in the client-side code that manages that connection, in EnclaveWebSocketClient.

The report was filed through the Chrome VRP, rated medium severity, and paid a bounty of 6000.00 USD. It was disclosed on 2024-10-15. The researcher is listed as anonymous.

Setup

The crash requires a signed-in user calling a navigator.credentials related JavaScript API to trigger. Signing in to a custom Chromium build is normally restricted, and the researcher did not find a way to fake a signed-in user without a large code patch. Instead the browser test code was reused for an easy reproduction in a local ASan environment.

The testing was done on Chromium version 131.0.6735.0 on Linux. The report lists the affected version as "beta + dev".

Finding it

The researcher looked at the connection setup path in EnclaveWebSocketClient. In EnclaveWebSocketClient::OnConnectionEstablished, if there is pending data to send, the code calls InternalWrite and then resets pending_write_data_. The problem is that InternalWrite may call ClosePipe and delete the object itself, so the subsequent access to the member variable pending_write_data_ is a use-after-free.

The reason InternalWrite can destroy the object is the ordering in OnConnectionEstablished: it calls WebSockets.StartReceiving before sending data through the writable data pipe. The mojo call StartReceiving tells the Network Service to read more frames from the remote side. If the connection has already been closed, for example due to a network error or a server response, the channel is dropped and all data pipes are reset. In that case EnclaveWebSocketClient fails to send the message and destroys itself.

The relevant code, as quoted in the report:

C++
void EnclaveWebSocketClient::OnConnectionEstablished(...) {
  websocket_->StartReceiving();      // ===> [3]

  state_ = State::kOpen;

  if (pending_write_data_) {
    InternalWrite(*pending_write_data_);
    pending_write_data_ = std::nullopt;      // ===> [1] UAF here
  }
}

void EnclaveWebSocketClient::InternalWrite(base::span<const uint8_t> data) {
  CHECK(state_ == State::kOpen);

  websocket_->SendMessage(network::mojom::WebSocketMessageType::BINARY,
                          data.size());
  MojoResult result = writable_->WriteAllData(data);
  if (result != MOJO_RESULT_OK) {
    FIDO_LOG(ERROR) << "Failed to write to WebSocket.";
    ClosePipe(SocketStatus::kError);      // ===> [2] delete this
  }
}

void WebSocket::WebSocketEventHandler::OnDropChannel(
    bool was_clean,
    uint16_t code,
    const std::string& reason) {
  impl_->client_->OnDropChannel(was_clean, code, reason);
  impl_->Reset();      // ===> [4]
}

The report annotates four points in the source:

  1. The line pending_write_data_ = std::nullopt; in OnConnectionEstablished, where the freed member is accessed.
  2. The ClosePipe(SocketStatus::kError) call in InternalWrite, which deletes the object.
  3. The websocket_->StartReceiving() call in OnConnectionEstablished, which runs before the write.
  4. The impl_->Reset() call in OnDropChannel, which resets the data pipes when the channel is dropped.

The report also links the corresponding lines in the Chromium source tree for each of these points.

Exploitation

The crash is triggered by a signed-in user calling a navigator.credentials related JavaScript API. Because signing in to a custom build is restricted, the researcher reproduced it through the browser test suite instead.

Step 1: Apply the test patch

Apply the attached patch.diff to the Chromium checkout.

Step 2: Build the browser tests with ASan

Bash
ninja -C out/Asan browser_tests

Step 3: Run the specific test

Bash
out/Asan/browser_tests --gtest_filter=EnclaveAuthenticatorWithPinBrowserTest.RegisterDeviceWithGpmPin_MakeCredential_Success

The crash type is listed as browser, and the crash state is in asan.log.

Root cause

The ordering in OnConnectionEstablished is the mistake. StartReceiving is called before the pending data is written. That mojo call asks the Network Service to read more frames from the remote side, and if the connection has already been closed, the channel is dropped and all data pipes are reset. The write then fails, InternalWrite calls ClosePipe, and the object is deleted. Control returns to OnConnectionEstablished, which still touches pending_write_data_ on the now-freed object.

A bisection points to the commit that introduced the issue:

Text
https://chromium.googlesource.com/chromium/src/+/[redacted]

Impact

The report lists the crash type as browser, triggered when a signed-in user calls a navigator.credentials related JavaScript API and the WebSocket connection is closed at the moment the pending data is written. The report does not go further into what an attacker could achieve beyond the crash; the severity assigned by the program is medium.

Fix

The suggested fix is to use a stack-allocated variable to hold the value of pending_write_data_ and clear pending_write_data_ before calling InternalWrite:

Diff
diff --git a/device/fido/enclave/enclave_websocket_client.cc b/device/fido/enclave/enclave_websocket_client.cc
index b3d42475d53ee..4bb2d9c5cc05f 100644
--- a/device/fido/enclave/enclave_websocket_client.cc
+++ b/device/fido/enclave/enclave_websocket_client.cc
@@ -204,8 +204,8 @@ void EnclaveWebSocketClient::OnConnectionEstablished(
   state_ = State::kOpen;

   if (pending_write_data_) {
-    InternalWrite(*pending_write_data_);
-    pending_write_data_ = std::nullopt;
+    auto pending_write_data = std::exchange(pending_write_data_, std::nullopt).value();
+    InternalWrite(pending_write_data);
   }
 }

The suggested change clears the member before the call that may destroy the object and holds the data in a local variable, so no member access happens after a potential free.

Variants to test

  • Look for other callbacks that call a method which can delete the object and then touch a member afterwards. A positive result is a member access after a call that can invoke ClosePipe, Reset or a similar teardown path.
  • Look for other places where a mojo StartReceiving or similar call is made before a write on the same pipe. A positive result is a write failure that triggers teardown while the caller still holds a reference to the object.
  • Look for other std::optional members that are reset after a call that can destroy the owning object. A positive result is a use-after-free reported by ASan in the same pattern.
  • Look for other WebSocket clients that call OnDropChannel and reset their pipes while a pending write is in flight. A positive result is a crash when the remote side closes the connection during the write.

Written with AI from the full original report and checked against it passage by passage; anything it could not back up was removed or toned down. The original is the record. 13 min read.

What happened, in plain words

Chrome has a feature for signing in without a password, called Web Authentication (often shortened to WebAuthn). Part of that feature, the Enclave Authenticator, talks to a server over a network connection. The code that manages this connection had a bug: in certain situations it used a piece of memory after that memory had already been thrown away. In programming this is called a use-after-free. The result is a crash of the browser.

The bug was found by a security researcher and reported through Google's Chrome Vulnerability Rewards Program (VRP), a scheme that pays people for reporting security problems in Chrome. The report was rated medium severity and paid a bounty of 6000.00 USD. It was disclosed on 2024-10-15, and the researcher is listed as anonymous.

Below I walk through what the feature does, what the bug is, how the researcher reproduced it, and how it was fixed, explaining each technical idea from scratch along the way.

Background concepts

Before the details, a few ideas that come up again and again.

  • Web Authentication (WebAuthn): a standard way for websites to let you sign in using something you have, such as a security key or your phone, instead of a password. The browser provides the plumbing; the website asks the browser to perform a sign-in step.
  • Enclave Authenticator: a part of Chrome's WebAuthn support. The word "enclave" suggests a protected area; in this report it is simply the component that performs authentication transactions with a server. The report says it uses WebSockets to communicate with that server.
  • WebSocket: a network connection that stays open in both directions, so the browser and a server can keep sending messages to each other. Think of it as a phone call that stays connected, rather than sending a letter and waiting for a reply.
  • API: an interface that one piece of software offers to another. When the report says a JavaScript API, it means a function a web page can call in the browser, such as navigator.credentials, which is the entry point web pages use for credential operations.
  • Mojo: Chrome's internal messaging system. Different parts of Chrome run as separate processes, and Mojo is how they pass messages and data between each other. A mojo call is one such internal message.
  • Network Service: a separate process inside Chrome that handles network traffic. The browser part asks it to open connections and send or receive data.
  • Data pipe: a channel for streaming bytes between two parts of Chrome. One side writes, the other reads. The report mentions a writable data pipe, the side this code writes into.
  • Use-after-free (UAF): a class of bug where a program frees a chunk of memory (says "I am done with this") and then later reads or writes it as if it were still valid. The memory may already belong to something else, so the result can be a crash or, in the worst case, something an attacker can influence. Here the outcome described is a crash.
  • ASan (AddressSanitizer): a tool built into a special debug version of a program that watches memory use and reports mistakes such as use-after-free, with a log of what happened. The report refers to an asan.log for crash details.
  • Bisection: a technique for finding which code change introduced a bug, by narrowing down between a version that worked and one that did not, similar to halving a range of possibilities repeatedly.

Context

The bug is a use-after-free in Chrome's Web Authentication implementation, specifically in the Enclave Authenticator. The Enclave Authenticator uses WebSockets to talk to a server, and every time a transaction is performed with the enclave a new WebSocket connection is initialised. The bug lives in the client-side code that manages that connection, in a class called EnclaveWebSocketClient.

A class, in object-oriented programming, is a blueprint for an object: a bundle of data (member variables) and functions (methods) that operate on it. EnclaveWebSocketClient is the object that owns one WebSocket connection and keeps track of what to send over it.

Setup

The crash requires a signed-in user calling a navigator.credentials related JavaScript API to trigger. Signing in to a custom Chromium build is normally restricted, and the researcher did not find a way to fake a signed-in user without a large code patch. Instead the browser test code was reused for an easy reproduction in a local ASan environment.

A few words on that: Chromium is the open-source project Chrome is built from. You can compile your own copy, but some features only work for accounts that are properly signed in, and faking that state is deliberately hard. Rather than fight that, the researcher used the project's existing automated tests, which already set up the needed conditions, and ran them in a build instrumented with ASan so memory errors are caught and logged.

The testing was done on Chromium version 131.0.6735.0 on Linux. The report lists the affected version as "beta + dev", the pre-release channels of Chrome.

Finding it

The researcher looked at the connection setup path in EnclaveWebSocketClient. In EnclaveWebSocketClient::OnConnectionEstablished, if there is pending data to send, the code calls InternalWrite and then resets pending_write_data_. The problem is that InternalWrite may call ClosePipe and delete the object itself, so the subsequent access to the member variable pending_write_data_ is a use-after-free.

In plain terms: OnConnectionEstablished is a function that runs when the connection has just been set up. It checks whether there is data waiting to be sent (pending_write_data_). If so, it sends that data with InternalWrite, then clears the waiting slot. But InternalWrite can, on failure, call ClosePipe, which tears the object down and frees it. After that, the line that clears the waiting slot is touching memory that no longer belongs to the object. That is the use-after-free.

The reason InternalWrite can destroy the object is the ordering in OnConnectionEstablished: it calls WebSockets.StartReceiving before sending data through the writable data pipe. The mojo call StartReceiving tells the Network Service to read more frames from the remote side. If the connection has already been closed, for example due to a network error or a server response, the channel is dropped and all data pipes are reset. In that case EnclaveWebSocketClient fails to send the message and destroys itself.

A frame here is one unit of data on a WebSocket connection. StartReceiving is the instruction to the Network Service to begin reading incoming frames. The catch is that asking to receive can immediately reveal that the other side has gone away, which triggers the teardown path while the code is still in the middle of sending.

The relevant code, as quoted in the report:

C++
void EnclaveWebSocketClient::OnConnectionEstablished(...) {
  websocket_->StartReceiving();      // ===> [3]

  state_ = State::kOpen;

  if (pending_write_data_) {
    InternalWrite(*pending_write_data_);
    pending_write_data_ = std::nullopt;      // ===> [1] UAF here
  }
}

void EnclaveWebSocketClient::InternalWrite(base::span<const uint8_t> data) {
  CHECK(state_ == State::kOpen);

  websocket_->SendMessage(network::mojom::WebSocketMessageType::BINARY,
                          data.size());
  MojoResult result = writable_->WriteAllData(data);
  if (result != MOJO_RESULT_OK) {
    FIDO_LOG(ERROR) << "Failed to write to WebSocket.";
    ClosePipe(SocketStatus::kError);      // ===> [2] delete this
  }
}

void WebSocket::WebSocketEventHandler::OnDropChannel(
    bool was_clean,
    uint16_t code,
    const std::string& reason) {
  impl_->client_->OnDropChannel(was_clean, code, reason);
  impl_->Reset();      // ===> [4]
}

Line by line, in plain words:

  1. void EnclaveWebSocketClient::OnConnectionEstablished(...) starts the function that runs once the connection is up. The ... stands for parameters the report does not show.
  2. websocket_->StartReceiving(); asks the Network Service to start reading incoming frames. The arrow means "call this method on the object pointed to". This is marked [3].
  3. state_ = State::kOpen; records that the connection is now open.
  4. if (pending_write_data_) { checks whether there is data waiting to be sent. pending_write_data_ is an optional value: it either holds data or is empty.
  5. InternalWrite(*pending_write_data_); sends that waiting data. The * reads the value out of the optional.
  6. pending_write_data_ = std::nullopt; clears the waiting slot, marking it empty. This is marked [1], the use-after-free: if the previous line freed the object, this line touches freed memory.
  7. void EnclaveWebSocketClient::InternalWrite(base::span<const uint8_t> data) starts the function that actually sends bytes. A span is a view over a sequence of bytes; uint8_t is an unsigned 8-bit number, i.e. a byte.
  8. CHECK(state_ == State::kOpen); is an assertion: if the state is not open, the program aborts. It is a safety check, not a fix for this bug.
  9. websocket_->SendMessage(network::mojom::WebSocketMessageType::BINARY, data.size()); tells the WebSocket layer to send a binary message of the given size.
  10. MojoResult result = writable_->WriteAllData(data); writes the bytes into the data pipe and stores the result code.
  11. if (result != MOJO_RESULT_OK) { checks whether the write failed.
  12. FIDO_LOG(ERROR) << "Failed to write to WebSocket."; writes an error to the log. FIDO is the family of standards WebAuthn belongs to.
  13. ClosePipe(SocketStatus::kError); closes the pipe with an error status. This is marked [2]: it is the call that deletes the object.
  14. void WebSocket::WebSocketEventHandler::OnDropChannel(...) starts the handler that runs when the connection is dropped. The parameters are whether it was a clean close, a numeric code, and a reason string.
  15. impl_->client_->OnDropChannel(was_clean, code, reason); passes the news on to the client object.
  16. impl_->Reset(); resets the internal state, including the data pipes. This is marked [4].

The report annotates four points in the source:

  1. The line pending_write_data_ = std::nullopt; in OnConnectionEstablished, where the freed member is accessed.
  2. The ClosePipe(SocketStatus::kError) call in InternalWrite, which deletes the object.
  3. The websocket_->StartReceiving() call in OnConnectionEstablished, which runs before the write.
  4. The impl_->Reset() call in OnDropChannel, which resets the data pipes when the channel is dropped.

The report also links the corresponding lines in the Chromium source tree for each of these points.

Exploitation

The crash is triggered by a signed-in user calling a navigator.credentials related JavaScript API. Because signing in to a custom build is restricted, the researcher reproduced it through the browser test suite instead.

Step 1: Apply the test patch

Apply the attached patch.diff to the Chromium checkout. A patch is a file describing changes to source code; applying it modifies your local copy. A checkout is your downloaded copy of the project's source.

Step 2: Build the browser tests with ASan

Bash
ninja -C out/Asan browser_tests

This builds the browser test program in a directory called out/Asan, which is configured to use AddressSanitizer. ninja is the build tool Chromium uses; -C out/Asan tells it to work in that directory, and browser_tests is the target to build.

Step 3: Run the specific test

Bash
out/Asan/browser_tests --gtest_filter=EnclaveAuthenticatorWithPinBrowserTest.RegisterDeviceWithGpmPin_MakeCredential_Success

This runs the freshly built test binary and uses a filter to run only one test, the one whose name matches EnclaveAuthenticatorWithPinBrowserTest.RegisterDeviceWithGpmPin_MakeCredential_Success. Running a single test keeps the output focused and makes the crash easy to see.

The crash type is listed as browser, meaning the browser process itself crashed, and the crash state is in asan.log.

Root cause

The ordering in OnConnectionEstablished is the mistake. StartReceiving is called before the pending data is written. That mojo call asks the Network Service to read more frames from the remote side, and if the connection has already been closed, the channel is dropped and all data pipes are reset. The write then fails, InternalWrite calls ClosePipe, and the object is deleted. Control returns to OnConnectionEstablished, which still touches pending_write_data_ on the now-freed object.

A useful comparison: imagine posting a letter and, before you finish, the post office tells you the address no longer exists. You throw away your notebook, then try to cross out the entry you just wrote in it. The notebook is gone; touching it is the mistake. The fix is to copy the entry out first, or cross it out before making the call that might throw the notebook away.

A bisection points to the commit that introduced the issue:

Text
https://chromium.googlesource.com/chromium/src/+/[redacted]

A commit is a recorded change in the source code history. The bisection points to this commit as the one that introduced the issue.

Impact

The report lists the crash type as browser, triggered when a signed-in user calls a navigator.credentials related JavaScript API and the WebSocket connection is closed at the moment the pending data is written. The report does not go further into what an attacker could achieve beyond the crash; the severity assigned by the program is medium.

Fix

The suggested fix is to use a stack-allocated variable to hold the value of pending_write_data_ and clear pending_write_data_ before calling InternalWrite:

Diff
diff --git a/device/fido/enclave/enclave_websocket_client.cc b/device/fido/enclave/enclave_websocket_client.cc
index b3d42475d53ee..4bb2d9c5cc05f 100644
--- a/device/fido/enclave/enclave_websocket_client.cc
+++ b/device/fido/enclave/enclave_websocket_client.cc
@@ -204,8 +204,8 @@ void EnclaveWebSocketClient::OnConnectionEstablished(
   state_ = State::kOpen;

   if (pending_write_data_) {
-    InternalWrite(*pending_write_data_);
-    pending_write_data_ = std::nullopt;
+    auto pending_write_data = std::exchange(pending_write_data_, std::nullopt).value();
+    InternalWrite(pending_write_data);
   }
 }

What this diff means, line by line:

  1. The diff --git line names the file being changed.
  2. The index line identifies the old and new versions of the file.
  3. The --- and +++ lines mark the old and new file paths.
  4. The @@ -204,8 +204,8 @@ line says the change is around line 204, with eight lines of context on each side.
  5. The unchanged context lines show the state assignment and the if check.
  6. The two lines starting with - are removed: the old order, where the data was sent and then the slot cleared.
  7. The line starting with + replaces them: std::exchange puts the current value of pending_write_data_ into a new local variable and sets the member to empty in one step. A local variable lives on the stack, a small area of memory tied to the current function call, so it stays valid even if the object is freed.
  8. The next + line sends the copied data. Because the member was already cleared and the data is held locally, nothing touches the object after it may have been freed.

The suggested change clears the member before the call that may destroy the object and holds the data in a local variable, so no member access happens after a potential free.

Variants to test

These are patterns worth checking elsewhere in similar code:

  • Look for other callbacks that call a method which can delete the object and then touch a member afterwards. A positive result is a member access after a call that can invoke ClosePipe, Reset or a similar teardown path.
  • Look for other places where a mojo StartReceiving or similar call is made before a write on the same pipe. A positive result is a write failure that triggers teardown while the caller still holds a reference to the object.
  • Look for other std::optional members that are reset after a call that can destroy the owning object. A positive result is a use-after-free reported by ASan in the same pattern.
  • Look for other WebSocket clients that call OnDropChannel and reset their pipes while a pending write is in flight. A positive result is a crash when the remote side closes the connection during the write.

Glossary

  • API: an interface one piece of software offers to another, such as a function a web page can call in the browser.
  • ASan (AddressSanitizer): a debugging tool that detects memory errors such as use-after-free and logs them.
  • Beta and dev channels: pre-release versions of Chrome used for testing before a stable release.
  • Bisection: narrowing down which code change introduced a bug by testing between a working and a broken version.
  • Browser process: the main process of Chrome that coordinates the rest; a crash here is a browser crash.
  • Callback: a function that is called when something happens, such as a connection being established or dropped.
  • Checkout: a local copy of a project's source code.
  • Chromium: the open-source project that Chrome is built from.
  • Class: a blueprint for an object, bundling data and the functions that work on it.
  • Commit: a recorded change in source code history.
  • Data pipe: a channel for streaming bytes between parts of a program.
  • Enclave Authenticator: the Chrome component that performs WebAuthn transactions with a server.
  • FIDO: the family of standards that WebAuthn belongs to.
  • Frame: one unit of data sent over a WebSocket connection.
  • JavaScript API: a function exposed to web pages by the browser, such as navigator.credentials.
  • Member variable: data stored inside an object, such as pending_write_data_.
  • Mojo: Chrome's internal messaging system between its processes.
  • Network Service: the separate Chrome process that handles network traffic.
  • Patch: a file describing changes to source code.
  • Span: a view over a sequence of bytes or other values.
  • Stack-allocated variable: a local variable whose memory is tied to the current function call and stays valid for its duration.
  • std::optional: a C++ type that either holds a value or is empty.
  • Teardown path: code that shuts down and frees an object.
  • Use-after-free (UAF): using memory after it has been freed, which can cause a crash or worse.
  • Web Authentication (WebAuthn): a standard for signing in without passwords using security keys or devices.
  • WebSocket: a two-way network connection that stays open between a browser and a server.
  • Writable data pipe: the side of a data pipe that data is written into.

More by anonymous

View all

2,270 more disclosed reports, best first.

More from Google Chrome

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.