New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 764320 link

Starred by 2 users

Issue metadata

Status: Verified
Owner:
Closed: Sep 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 1
Type: Bug-Security



Sign in to add a comment

Heap-use-after-free in _ZN7logging22MakeCheckOpValueStringIPcEENSt3__19enable_ifIXaasr4base8internal23S

Project Member Reported by ClusterFuzz, Sep 12 2017

Issue description

Detailed report: https://clusterfuzz.com/testcase?key=5041566636048384

Fuzzer: libFuzzer_net_http_server_fuzzer
Job Type: libfuzzer_chrome_asan_debug
Platform Id: linux

Crash Type: Heap-use-after-free READ 1
Crash Address: 0x608000002539
Crash State:
  _ZN7logging22MakeCheckOpValueStringIPcEENSt3__19enable_ifIXaasr4base8internal23S
  std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<ch
  std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<ch
  
Sanitizer: address (ASAN)

Recommended Security Severity: High

Regressed: https://clusterfuzz.com/revisions?job=libfuzzer_chrome_asan_debug&range=501057:501134

Reproducer Testcase: https://clusterfuzz.com/download?testcase_id=5041566636048384

Issue filed automatically.

See https://chromium.googlesource.com/chromium/src/+/master/testing/libfuzzer/reproducing.md for more information.
 

Comment 1 by mea...@chromium.org, Sep 12 2017

Components: Internals>Network
Status: Available (was: Untriaged)
I can repro locally as well. Can someone from the network team please take a look? Thanks.
Project Member

Comment 2 by sheriffbot@chromium.org, Sep 13 2017

Labels: M-62
Project Member

Comment 3 by sheriffbot@chromium.org, Sep 13 2017

Labels: ReleaseBlock-Stable
This is a serious security regression. If you are not able to fix this quickly, please revert the change that introduced it.

If this doesn't affect a release branch, or has not been properly classified for severity, please update the Security_Impact or Security_Severity labels, and remove the ReleaseBlock label. To disable this altogether, apply ReleaseBlock-NA.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Project Member

Comment 4 by sheriffbot@chromium.org, Sep 13 2017

Labels: Pri-1
Cc: cbentzel@chromium.org
cbentzel: Can you suggest a good owner for this?

Is the http_server used by anything other than test code?
Project Member

Comment 6 by sheriffbot@chromium.org, Sep 14 2017

Labels: -Security_Impact-Head Security_Impact-Beta
Cc: brettw@chromium.org lassey@chromium.org mmenke@chromium.org
Owner: morlovich@chromium.org
Status: Assigned (was: Available)
Temporarily assigning to morlovich since he wrote some fuzzers in this space.

I don't think http_server has many people actively working on it, so should probably be a grab.

Looking at clusterfuzz range, the only thing that looked close was brettw's circular_deque refactor: https://chromium.googlesource.com/chromium/src/+/c6a0c827068cf51a474ec7c2dd0228c22d337689
Yeah, I wrote this fuzzer.

queue change may be a good starting point, since it's used in at least one spot:


https://cs.chromium.org/chromium/src/net/server/http_connection.h?rcl=56f290842c6f2f23291baf3a1e05bc4a091a93a1&l=106
Uploaded https://chromium-review.googlesource.com/c/chromium/src/+/667730
Also I think this may be 63 only?

This is the version that omahaproxy has a beta/M62:
https://chromium.googlesource.com/chromium/src/+/refs/tags/62.0.3202.0/net/server/http_connection.h#106
.. so it's not affected. I feel like I should remove M-62, ReleaseBlock-Stable,Security_Impact-Beta and add M-63, and Security_Impact-Head?

I agree with that - looks like it's not an M62 issue.  The revision range by the fuzzer (Which may not be entirely accurate), also only indicates it's on M-63.
Labels: -Security_Impact-Beta -ReleaseBlock-Stable -M-62 Security_Impact-Head M-63
Project Member

Comment 14 by bugdroid1@chromium.org, Sep 15 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/03336b6cfacda28575e9f200b2eeae4fbabe6153

commit 03336b6cfacda28575e9f200b2eeae4fbabe6153
Author: Maks Orlovich <morlovich@chromium.org>
Date: Fri Sep 15 21:39:05 2017

HttpServer: adjust QueuedWriteIOBuffer to new queue

In particular, don't assume pointer stability.


Bug:  764320 
Change-Id: Ie260aa1cef4a42869ae2ab46601d9e1143f1d5d8
Reviewed-on: https://chromium-review.googlesource.com/667730
Reviewed-by: Matt Menke <mmenke@chromium.org>
Commit-Queue: Maks Orlovich <morlovich@chromium.org>
Cr-Commit-Position: refs/heads/master@{#502385}
[modify] https://crrev.com/03336b6cfacda28575e9f200b2eeae4fbabe6153/net/server/http_connection.cc
[modify] https://crrev.com/03336b6cfacda28575e9f200b2eeae4fbabe6153/net/server/http_connection.h
[modify] https://crrev.com/03336b6cfacda28575e9f200b2eeae4fbabe6153/net/server/http_connection_unittest.cc

Project Member

Comment 15 by ClusterFuzz, Sep 16 2017

ClusterFuzz has detected this issue as fixed in range 502309:502391.

Detailed report: https://clusterfuzz.com/testcase?key=5041566636048384

Fuzzer: libFuzzer_net_http_server_fuzzer
Job Type: libfuzzer_chrome_asan_debug
Platform Id: linux

Crash Type: Heap-use-after-free READ 1
Crash Address: 0x608000002539
Crash State:
  _ZN7logging22MakeCheckOpValueStringIPcEENSt3__19enable_ifIXaasr4base8internal23S
  std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<ch
  std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<ch
  
Sanitizer: address (ASAN)

Recommended Security Severity: High

Regressed: https://clusterfuzz.com/revisions?job=libfuzzer_chrome_asan_debug&range=501057:501134
Fixed: https://clusterfuzz.com/revisions?job=libfuzzer_chrome_asan_debug&range=502309:502391

Reproducer Testcase: https://clusterfuzz.com/download?testcase_id=5041566636048384

See https://chromium.googlesource.com/chromium/src/+/master/testing/libfuzzer/reproducing.md for more information.

If you suspect that the result above is incorrect, try re-doing that job on the test case report page.
Project Member

Comment 16 by ClusterFuzz, Sep 16 2017

Labels: ClusterFuzz-Verified
Status: Verified (was: Assigned)
ClusterFuzz testcase 5041566636048384 is verified as fixed, so closing issue as verified.

If this is incorrect, please add ClusterFuzz-Wrong label and re-open the issue.
Project Member

Comment 17 by sheriffbot@chromium.org, Sep 16 2017

Labels: -Restrict-View-SecurityTeam Restrict-View-SecurityNotify
Project Member

Comment 18 by sheriffbot@chromium.org, Dec 23 2017

Labels: -Restrict-View-SecurityNotify allpublic
This bug has been closed for more than 14 weeks. Removing security view restrictions.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Project Member

Comment 19 by sheriffbot@chromium.org, Mar 27 2018

Labels: -Security_Impact-Head -M-63 M-65 Security_Impact-Stable

Sign in to add a comment