New issue
Advanced search Search tips

Issue 801142 link

Starred by 1 user

Issue metadata

Status: Verified
Owner:
Closed: Jan 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 1
Type: Bug



Sign in to add a comment

Null-dereference READ in AppListViewDelegate::OpenSearchResult

Project Member Reported by ClusterFuzz, Jan 11 2018

Issue description

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

Fuzzer: noel-image-surku
Job Type: linux_asan_chrome_chromeos
Platform Id: linux

Crash Type: Null-dereference READ
Crash Address: 0x0000000000d8
Crash State:
  AppListViewDelegate::OpenSearchResult
  app_list::SearchResultTileItemView::OnKeyPressed
  views::View::OnKeyEvent
  
Sanitizer: address (ASAN)

Regressed: https://clusterfuzz.com/revisions?job=linux_asan_chrome_chromeos&range=514498:517889

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

Additional requirements: Requires Gestures

Issue filed automatically.

See https://github.com/google/clusterfuzz-tools for more information.
 
Project Member

Comment 1 by ClusterFuzz, Jan 11 2018

Components: Internals>Views UI>Browser
Labels: Test-Predator-Auto-Components
Automatically applying components based on crash stacktrace and information from OWNERS files.

If this is incorrect, please apply the Test-Predator-Wrong-Components label.
Project Member

Comment 2 by ClusterFuzz, Jan 11 2018

Cc: weidongg@chromium.org newcomer@chromium.org
Labels: Test-Predator-Auto-CC
Automatically adding ccs based on suspected regression changelists:

cros fix incorrect UMA Histogram recording by newcomer@chromium.org - https://chromium.googlesource.com/chromium/src/+/c7b6f2a93417a42bfe042662a540b63df25dcf29

cros: Removing the old Bubble Launcher by newcomer@chromium.org - https://chromium.googlesource.com/chromium/src/+/5f27ab95f93f38869b44d96a104d100f02e70def

applist-focus: solve conflict of left and right key on Textfield by weidongg@chromium.org - https://chromium.googlesource.com/chromium/src/+/3c351b6426ad9f02347d099a5baec548e462beee

If this is incorrect, please apply the Test-Predator-Wrong-CLs label.
Not sure about this bug, but it looks like AppListView who owns AppListViewDelegate is desctructed when the user hit 'enter' on SearchResultTileItemView, which seems not possible?
What seems to be happening is the SearchResult* got deleted before the user hits enter. This could happen when the search result list is changing.

We can probably prevent this by if (!item_) return;

what do you think?
Sorry.
The search result was deleted b/c the list was changing.
Then the user hits enter, focus didn't move from the view (which hasn't been deleted yet) so we send a null search result.
Yes, I think you are right. Do you want to take this since you seem to have a solution.
Owner: newcomer@chromium.org
Status: Started (was: Untriaged)
Got it! :)
Project Member

Comment 8 by bugdroid1@chromium.org, Jan 12 2018

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

commit 5478ca083bc1563d05815781e55fb2bb759837cc
Author: Alex Newcomer <newcomer@chromium.org>
Date: Fri Jan 12 18:05:08 2018

cros: Fix null-dereference read in AppList  SearchResult

There is a chance that a search result will be deleted when
the search result list is changing. If the user hits enter
to launch a search result, we need to check to be sure that the
result still exists.

Bug:  801142 
Change-Id: I9c82356260e05512d0af15dc3e43412730a2ac0d
Reviewed-on: https://chromium-review.googlesource.com/861867
Reviewed-by: Xiyuan Xia <xiyuan@chromium.org>
Commit-Queue: Alex Newcomer <newcomer@chromium.org>
Cr-Commit-Position: refs/heads/master@{#528993}
[modify] https://crrev.com/5478ca083bc1563d05815781e55fb2bb759837cc/ui/app_list/views/search_result_tile_item_view.cc

Status: Fixed (was: Started)
Project Member

Comment 10 by ClusterFuzz, Jan 13 2018

ClusterFuzz has detected this issue as fixed in range 528992:528993.

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

Fuzzer: noel-image-surku
Job Type: linux_asan_chrome_chromeos
Platform Id: linux

Crash Type: Null-dereference READ
Crash Address: 0x0000000000d8
Crash State:
  AppListViewDelegate::OpenSearchResult
  app_list::SearchResultTileItemView::OnKeyPressed
  views::View::OnKeyEvent
  
Sanitizer: address (ASAN)

Regressed: https://clusterfuzz.com/revisions?job=linux_asan_chrome_chromeos&range=514498:517889
Fixed: https://clusterfuzz.com/revisions?job=linux_asan_chrome_chromeos&range=528992:528993

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

Additional requirements: Requires Gestures

See https://github.com/google/clusterfuzz-tools 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 11 by ClusterFuzz, Jan 13 2018

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

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

Sign in to add a comment