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

Issue 622196 link

Starred by 0 users

Issue metadata

Status: WontFix
Owner:
Last visit > 30 days ago
Closed: Aug 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 3
Type: Bug-Security



Sign in to add a comment

Stack-buffer-overflow in Hunspell::suggest

Project Member Reported by ClusterFuzz, Jun 22 2016

Issue description

Detailed report: https://cluster-fuzz.appspot.com/testcase?key=4516632898830336

Fuzzer: libfuzzer_hunspell_fuzzer
Job Type: libfuzzer_chrome_asan
Platform Id: linux

Crash Type: Stack-buffer-overflow WRITE {*}
Crash Address: 0x7f85eb7d0a70
Crash State:
  Hunspell::suggest
  LLVMFuzzerTestOneInput
  fuzzer::Fuzzer::ExecuteCallback
  
Recommended Security Severity: High

Regressed: https://cluster-fuzz.appspot.com/revisions?job=libfuzzer_chrome_asan&range=401002:401127

Minimized Testcase (0.58 Kb): https://cluster-fuzz.appspot.com/download/AMIfv964tNTjFpofUJAREsJgoEl3HlwGi9t0NuHpYKBO3AOEP_6BQ2571H61E3x5b9mghHSMfeH6E94up-EGWPjlGWBqBL070qL5B5j3yhzwwVXwlO1qyssFCvyK4T1zVb-ylq3F5aBUiWyFrGnHSNSOmQvvMYfvIQ?testcase_id=4516632898830336

Filer: mmoroz

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

Comment 1 by mmoroz@chromium.org, Jun 22 2016

Cc: mmoroz@chromium.org rouslan@chromium.org kcc@chromium.org aizatsky@chromium.org
Labels: Pri-1
Owner: groby@chromium.org
wow!

WRITE of size 243 at 0x7f85eb7d0a70 thread T0
SCARINESS: 60 (multi-byte-write-stack-buffer-overflow)
Project Member

Comment 2 by sheriffbot@chromium.org, Jun 22 2016

Labels: M-53
Project Member

Comment 3 by sheriffbot@chromium.org, Jun 22 2016

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

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

Comment 4 by ClusterFuzz, Jun 22 2016

Status: Assigned (was: Available)

Comment 5 by groby@chromium.org, Jun 22 2016

It's not really a regression. This exists since the beginning of time :)

And yes, the fuzzer shows that hunspell is extremely vulnerable to broken dictionaries. 

But 
a) We knew that. That's why it's segregated into the render process.
b) I've got a fairly difficult time imagining an attack scenario - you'll need to modify a local file, intercept a download from a google site via https, or have broken free of the sandbox to modify the download code in browser. All of these imply that you probably don't need a crash exploit any more.

Given this information, can we reclassify this? If it's really a releaseblock, we will, in all likelihood, need to turn hunspell off. Hardening hunspell against broken dictionaries is a non-trivial task. 

Comment 6 Deleted

Comment 7 by mmoroz@chromium.org, Jun 23 2016

Labels: -Pri-1 -M-53 Pri-3
Given that an incorrect dictionary has been used + that dictionary is not controlled by an attacker, I think we may low down the priority here. But might be good to get it fixed sometime later when we've got a chance.

I'm setting P-3 and removing M-label.

Btw, I have a CL to use .bdic as a dictionary (https://codereview.chromium.org/2089623002/).


Project Member

Comment 8 by sheriffbot@chromium.org, Jun 23 2016

Labels: M-53
Project Member

Comment 9 by sheriffbot@chromium.org, Jun 23 2016

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

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Cc: mbarbe...@chromium.org
I'm not sure that I know how to say to the Sheriffbot that we don't want this to be a blocker. CC'ing marbella@ for this. Also would like to know his opinion about the issue. 
Labels: -ReleaseBlock-Beta -Security_Impact-Head Security_Impact-Stable
In this case it's because the impact wasn't updated to stable after c#5. You can also set ReleaseBlock-NA as a last resort, but usually it means something else went wrong with the triage of the bug.

Based on the other comments and fact that this is Pri-3, I'm not sure we should even be tracking this as a security bug. I'll leave that up to someone else to decide.
Project Member

Comment 12 by ClusterFuzz, Jun 25 2016

ClusterFuzz has detected this issue as fixed in range 401846:401864.

Detailed report: https://cluster-fuzz.appspot.com/testcase?key=4516632898830336

Fuzzer: libfuzzer_hunspell_fuzzer
Job Type: libfuzzer_chrome_asan
Platform Id: linux

Crash Type: Stack-buffer-overflow WRITE {*}
Crash Address: 0x7f85eb7d0a70
Crash State:
  Hunspell::suggest
  LLVMFuzzerTestOneInput
  fuzzer::Fuzzer::ExecuteCallback
  
Recommended Security Severity: High

Regressed: https://cluster-fuzz.appspot.com/revisions?job=libfuzzer_chrome_asan&range=401002:401127
Fixed: https://cluster-fuzz.appspot.com/revisions?job=libfuzzer_chrome_asan&range=401846:401864

Minimized Testcase (0.58 Kb): https://cluster-fuzz.appspot.com/download/AMIfv964tNTjFpofUJAREsJgoEl3HlwGi9t0NuHpYKBO3AOEP_6BQ2571H61E3x5b9mghHSMfeH6E94up-EGWPjlGWBqBL070qL5B5j3yhzwwVXwlO1qyssFCvyK4T1zVb-ylq3F5aBUiWyFrGnHSNSOmQvvMYfvIQ?testcase_id=4516632898830336

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 13 by ClusterFuzz, Jun 25 2016

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

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

Comment 14 by ClusterFuzz, Jun 25 2016

Labels: Merge-Triage M-51 M-52
Adding Merge-Triage label for tracking purposes.

Once your fix had sufficient bake time (on canary, dev as appropriate), please nominate your fix for merge by adding the Merge-Request-XX label, where XX is the Chrome milestone.

When your merge is approved by the release manager, please start merging with higher milestone label first. Make sure to re-request merge for every milestone in the label list. You can get branch information on omahaproxy.appspot.com.

Your fix is very close to the branch point. After the branch happens, please make sure to check if your fix is in.

- Your friendly ClusterFuzz
Project Member

Comment 15 by sheriffbot@chromium.org, Jun 25 2016

Labels: -Restrict-View-SecurityTeam Restrict-View-SecurityNotify
CF marked this as Fixed because it cannot be reproduced with a new version of the fuzzer, now it uses .bdic contents as a dictionary.

Comment 17 by aarya@google.com, Jun 26 2016

Labels: -ClusterFuzz-Verified ClusterFuzz-Wrong
Status: Assigned (was: Verified)
Project Member

Comment 18 by ClusterFuzz, Jun 26 2016

Status: Fixed (was: Assigned)
Please mark security bugs as fixed as soon as the fix lands, and before requesting merges.

- Your friendly ClusterFuzz

Comment 19 by aarya@google.com, Jun 26 2016

Labels: -Merge-Triage
Status: Assigned (was: Fixed)
Project Member

Comment 20 by sheriffbot@chromium.org, Jul 7 2016

groby: Uh oh! This issue still open and hasn't been updated in the last 14 days. This is a serious vulnerability, and we want to ensure that there's progress. Could you please leave an update with the current status and any potential blockers?

If you're not the right owner for this issue, could you please remove yourself as soon as possible or help us find the right one?

If the issue is fixed or you can't reproduce it, please close the bug. If you've started working on a fix, please set the status to Started.

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

Comment 21 by groby@chromium.org, Jul 12 2016

Labels: Disable-Nags
Status: Fixed (was: Assigned)
aarya@: I'm not sure this is ClusterFuzz-Wrong. The original fuzzing step had a bug, which mmoroz@ fixed.

Also, not sure why this is re-assigned to me - there's nothing to be done, as far as I can tell. There is no fix to be merged. 
groby@, it has been assigned to you as per c#7.

Technically ClusterFuzz is correct here, but I assume we want to keep this open and hope to fix one day.

Comment 23 by groby@chromium.org, Jul 12 2016

We can keep it open as a someday maybe, but I don't see this happening. The cost is extremely high, and the vulnerability is extremely low. 

Cost: The fix would be rewriting major parts of hunspell. The assumption that the dictionary is "correct" permeates pretty much the entire code base.

Vulnerability: 
* Dictionaries are downloaded in the browser process from a fixed google.com address via https
* This particular bug is in the suggest path, which is only activated on user gesture.

I'd argue that if you achieve any of the preconditions necessary to trigger this, you already have a viable exploit, without needing hunspell. (This is part of the reason why we isolated hunspell in the render process, IIRC - it's a large legacy code base with many issues).


If you'd still like to reopen, feel free to do so, but please mark it as available instead - unless my security assessment is wrong and there is a viable exploit path.
Status: Available (was: Fixed)
Re-opening per #22 and #23
Project Member

Comment 25 by sheriffbot@chromium.org, Jul 20 2016

Status: Assigned (was: Available)
Project Member

Comment 26 by sheriffbot@chromium.org, Jul 21 2016

Labels: -M-51
Status: WontFix (was: Assigned)
WontFixing as per #23.
Project Member

Comment 28 by sheriffbot@chromium.org, Nov 16 2016

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
Components: -UI>Browser>Spellcheck UI>Browser>Language>Spellcheck
Labels: -ClusterFuzz-Wrong
We have made a bunch of changes on ClusterFuzz side, so resetting ClusterFuzz-Wrong label.

Sign in to add a comment