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

Issue 654807 link

Starred by 3 users

Issue metadata

Status: Assigned
Owner:
Last visit > 30 days ago
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 1
Type: Bug

Blocked on:
issue chrome-os-partner:52689



Sign in to add a comment

Crash on Stable 8530.96.0 => shill::HTTPRequest::ReadFromServer-87be9517

Project Member Reported by keta...@chromium.org, Oct 11 2016

Issue description

Report IDe669f59b00000000
Product, version -> ChromeOS, 8530.96.0
Magic Signature__memmove_ssse3edit bugs&comments
Stable Signatureshill::HTTPRequest::ReadFromServer-87be9517edit bugs&comments
Report TimeTue, 11 Oct 2016 16:41:12 GMT
Client IDB42237E76EC94BC187FF8043EAA4093B


Thread 0 CRASHED [SIGSEGV @ 0x00000000 ] MAGIC SIGNATURE THREAD
0x00007f1637368208	(libc-2.19.so + 0x00143208 )	__memmove_ssse3
0x00007f16384cd7a3	(shill -stl_algobase.h:378 )	shill::HTTPRequest::ReadFromServer
0x00007f16384ce251	(shill -bind_internal.h:186 )	base::internal::Invoker<base::IndexSequence<0ul>, base::internal::BindState<base::internal::RunnableAdapter<void (shill::HTTPRequest::*)(shill::InputData*)>, void(shill::HTTPRequest*, shill::InputData*), base::WeakPtr<shill::HTTPRequest> >, base::internal::InvokeHelper<true, void, base::internal::RunnableAdapter<void (shill::HTTPRequest::*)(shill::InputData*)> >, void(shill::InputData*)>::Run
0x00007f16381a77ea	(libshill-net-395517.so -callback.h:397 )	shill::IOInputHandler::OnFileCanReadWithoutBlocking
0x00007f1637f6201d	(libbase-core-395517.so -message_pump_libevent.cc:346 )	base::MessagePumpLibevent::OnLibeventNotification
0x00007f1636cef0b3	(libevent_core-2.0.so.5.1.9 -event.c:1368 )	event_base_loop
0x00007f1637f61d30	(libbase-core-395517.so -message_pump_libevent.cc:256 )	base::MessagePumpLibevent::Run
0x00007f1637f84fa7	(libbase-core-395517.so -run_loop.cc:35 )	base::RunLoop::Run
0x00007f16380f9145	(libbrillo-core-395517.so -base_message_loop.cc:212 )	brillo::BaseMessageLoop::Run
0x00007f16380c083f	(libbrillo-core-395517.so -daemon.cc:29 )	brillo::Daemon::Run
0x00007f16382550f2	(shill -shill_main.cc:253 )	main
0x00007f1637244fb5	(libc-2.19.so -libc-start.c:292 )	__libc_start_main
0x00007f1638255767	(shill + 0x00043767 )	_start
0x00007ffc0f9e8517	


Sameer, there are close to 3633 reports for this shill crash on 8530.96.0. Who should take a look at this one?
https://crash.corp.google.com/browse?q=product.name%3D%27ChromeOS%27%20AND%20product.version%3D%278530.96.0%27%20AND%20stable_signature%3D%27shill%3A%3AHTTPRequest%3A%3AReadFromServer-87be9517%27&ignore_case=false&enable_rewrite=true&omit_field_name=&omit_field_value=&omit_field_opt=%3D#samplereports
 
Cc: cernekee@chromium.org

Comment 2 by snanda@chromium.org, Oct 12 2016

Cc: semenzato@chromium.org
Owner: kirtika@chromium.org

Comment 3 Deleted

Blockedon: -52689 chrome-os-partner:52689
Same issue as: https://code.google.com/p/chrome-os-partner/issues/detail?id=52689
Tracking there as that has previous context. 

Labels: M-55 M-54 Merge-Request-54 Merge-Request-55
I have a fix here: https://chromium-review.googlesource.com/#/c/399398/
Luigi's comment here provides good context: https://code.google.com/p/chrome-os-partner/issues/detail?id=52689#c24

Requesting merge for both 54 and 55 since this bug now has 21k+ crashes in the field. 

Comment 6 by dimu@chromium.org, Oct 15 2016

Labels: -Merge-Request-54 Merge-Review-54 Hotlist-Merge-Review
[Automated comment] Less than 2 weeks to go before stable on M54, manual review required.

Comment 7 by dimu@chromium.org, Oct 15 2016

Labels: -Merge-Request-55 Merge-Approved-55 Hotlist-Merge-Approved
Your change meets the bar and is auto-approved for M55 (branch: 2883)

Comment 8 by dimu@chromium.org, Oct 15 2016

Labels: -Merge-Request-54 Merge-Review-54 Hotlist-Merge-Review
[Automated comment] Less than 2 weeks to go before stable on M54, manual review required.
Project Member

Comment 9 by bugdroid1@chromium.org, Oct 17 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/aosp/platform/system/connectivity/shill/+/2213b35c05d12a7b90eb6880cc9748d3b410b79a

commit 2213b35c05d12a7b90eb6880cc9748d3b410b79a
Author: Kirtika Ruchandani <kirtika@google.com>
Date: Fri Oct 14 19:49:19 2016

HTTPRequest: Be resilient to bad data in input cb

IOInputHandler's implementation calls the input callback
if InputData has length < 0 (read failed).
So, make the HTTPRequest terminate early if data->len < 0.
This is a stop-gap fix for M54, until we fix IOInputHandler's
behavior. Add a unit-test to ensure we don't crash on bad data.

BUG=654807
TEST=shill unit-tests

Change-Id: I98d38a5a359f3a81534a677762b17acf1d8ad35b
Reviewed-on: https://chromium-review.googlesource.com/399398
Commit-Ready: Kirtika Ruchandani <kirtika@chromium.org>
Tested-by: Kirtika Ruchandani <kirtika@chromium.org>
Reviewed-by: Kevin Cernekee <cernekee@chromium.org>

[modify] https://crrev.com/2213b35c05d12a7b90eb6880cc9748d3b410b79a/http_request.cc
[modify] https://crrev.com/2213b35c05d12a7b90eb6880cc9748d3b410b79a/http_request_unittest.cc

Project Member

Comment 10 by bugdroid1@chromium.org, Oct 17 2016

Labels: merge-merged-release-R55-8872.B
The following revision refers to this bug:
  https://chromium.googlesource.com/aosp/platform/system/connectivity/shill/+/65545b09cc6660830019f77fe5709a81f355487f

commit 65545b09cc6660830019f77fe5709a81f355487f
Author: Kirtika Ruchandani <kirtika@google.com>
Date: Fri Oct 14 19:49:19 2016

HTTPRequest: Be resilient to bad data in input cb

IOInputHandler's implementation calls the input callback
if InputData has length < 0 (read failed).
So, make the HTTPRequest terminate early if data->len < 0.
This is a stop-gap fix for M54, until we fix IOInputHandler's
behavior. Add a unit-test to ensure we don't crash on bad data.

BUG=654807
TEST=shill unit-tests

Change-Id: I98d38a5a359f3a81534a677762b17acf1d8ad35b

[modify] https://crrev.com/65545b09cc6660830019f77fe5709a81f355487f/http_request.cc
[modify] https://crrev.com/65545b09cc6660830019f77fe5709a81f355487f/http_request_unittest.cc

Labels: -Merge-Review-54 Merge-Approved-54
Approved for M54
Kirtika, please add any validation that may be ran to validate all is good

Cc: tienchang@chromium.org
+tienchang@ for networking testing 

Comment 13 by kirtika@google.com, Oct 17 2016

Tien, we will need extensive chrome-side testing for this. Are you aware of any Chrome-side tests that cycle through many http request/download cases? 


Project Member

Comment 14 by bugdroid1@chromium.org, Oct 17 2016

Labels: merge-merged-release-R54-8743.B
The following revision refers to this bug:
  https://chromium.googlesource.com/aosp/platform/system/connectivity/shill/+/eb30c227ca70c7eb6cf541f9e60716d592d1a2a3

commit eb30c227ca70c7eb6cf541f9e60716d592d1a2a3
Author: Kirtika Ruchandani <kirtika@google.com>
Date: Fri Oct 14 19:49:19 2016

HTTPRequest: Be resilient to bad data in input cb

IOInputHandler's implementation calls the input callback
if InputData has length < 0 (read failed).
So, make the HTTPRequest terminate early if data->len < 0.
This is a stop-gap fix for M54, until we fix IOInputHandler's
behavior. Add a unit-test to ensure we don't crash on bad data.

BUG=654807
TEST=shill unit-tests

Change-Id: I98d38a5a359f3a81534a677762b17acf1d8ad35b

[modify] https://crrev.com/eb30c227ca70c7eb6cf541f9e60716d592d1a2a3/http_request.cc
[modify] https://crrev.com/eb30c227ca70c7eb6cf541f9e60716d592d1a2a3/http_request_unittest.cc

FWIK, there is no end-to-end test that focuses on Chrome-side cycles through HTTP requests, but we do cycle through the top sites every FullRelease testing (https://testtracker.googleplex.com/testplans/testcase/detail/37144?id=375&revision=188). How else can we help verify this change?
Project Member

Comment 16 by bugdroid1@chromium.org, Oct 18 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/aosp/platform/system/connectivity/shill/+/4a77ef07d730cfd5f3461d779028ab0a60e295f9

commit 4a77ef07d730cfd5f3461d779028ab0a60e295f9
Author: Kirtika Ruchandani <kirtika@google.com>
Date: Sat Oct 15 22:09:51 2016

IOInputHandler: Don't call input cb with bad data

Fix bug in IOInputHandler where it proceeds to call input_callback
after detecting that the input length is negative.
Make users of IOInputHandler resilient to bad data -
- ICMPSession: Protect against corrupt data in replies
- CryptoUtilProxy: Protect against bad data in HandleShimOutput
- VPN: Add input validation in the input handler callbacks

BUG=chromium:654807
TEST=shill unit-tests
Change-Id: I5c7596df345974153bfe71df441ceb4094fb860e
Reviewed-on: https://chromium-review.googlesource.com/399541
Commit-Ready: Kirtika Ruchandani <kirtika@chromium.org>
Tested-by: Kirtika Ruchandani <kirtika@chromium.org>
Reviewed-by: Kevin Cernekee <cernekee@chromium.org>

[modify] https://crrev.com/4a77ef07d730cfd5f3461d779028ab0a60e295f9/crypto_util_proxy.cc
[modify] https://crrev.com/4a77ef07d730cfd5f3461d779028ab0a60e295f9/net/io_input_handler.cc
[modify] https://crrev.com/4a77ef07d730cfd5f3461d779028ab0a60e295f9/icmp_session.cc

Project Member

Comment 17 by bugdroid1@chromium.org, Oct 18 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/aosp/platform/system/connectivity/shill/+/4a77ef07d730cfd5f3461d779028ab0a60e295f9

commit 4a77ef07d730cfd5f3461d779028ab0a60e295f9
Author: Kirtika Ruchandani <kirtika@google.com>
Date: Sat Oct 15 22:09:51 2016

IOInputHandler: Don't call input cb with bad data

Fix bug in IOInputHandler where it proceeds to call input_callback
after detecting that the input length is negative.
Make users of IOInputHandler resilient to bad data -
- ICMPSession: Protect against corrupt data in replies
- CryptoUtilProxy: Protect against bad data in HandleShimOutput
- VPN: Add input validation in the input handler callbacks

BUG=chromium:654807
TEST=shill unit-tests
Change-Id: I5c7596df345974153bfe71df441ceb4094fb860e
Reviewed-on: https://chromium-review.googlesource.com/399541
Commit-Ready: Kirtika Ruchandani <kirtika@chromium.org>
Tested-by: Kirtika Ruchandani <kirtika@chromium.org>
Reviewed-by: Kevin Cernekee <cernekee@chromium.org>

[modify] https://crrev.com/4a77ef07d730cfd5f3461d779028ab0a60e295f9/crypto_util_proxy.cc
[modify] https://crrev.com/4a77ef07d730cfd5f3461d779028ab0a60e295f9/net/io_input_handler.cc
[modify] https://crrev.com/4a77ef07d730cfd5f3461d779028ab0a60e295f9/icmp_session.cc

Project Member

Comment 18 by sheriffbot@chromium.org, Oct 19 2016

This issue has been approved for a merge. Please merge the fix to any appropriate branches as soon as possible!

If all merges have been completed, please remove any remaining Merge-Approved labels from this issue.

Thanks for your time! To disable nags, add the Disable-Nags label.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Labels: -M-53 -Merge-Approved-54 -Merge-Approved-55 Merge-Merged
Status: Fixed (was: Started)
I'm pretty sure that M-53 isn't going to get any change, so removing that and marking that this change has been merged.
Status: Verified (was: Fixed)
This looks good. Ran curl script for about 100 iterations.
Samus R55-8872.15.0
Cyan  R54-8743.69.0
Labels: -Hotlist-Merge-Review
Merge here seems obsolete.

Sign in to add a comment