Issue metadata
Sign in to add a comment
|
Use-of-uninitialized-value in blink::InlineTextBox::GetSelectionState |
||||||||||||||||||||||
Issue descriptionDetailed report: https://clusterfuzz.com/testcase?key=5239140198383616 Fuzzer: inferno_layout_test_unmodified Job Type: linux_msan_chrome Platform Id: linux Crash Type: Use-of-uninitialized-value Crash Address: Crash State: blink::InlineTextBox::GetSelectionState blink::InlineTextBoxPainter::Paint blink::InlineTextBox::Paint Sanitizer: memory (MSAN) Recommended Security Severity: Medium Regressed: https://clusterfuzz.com/revisions?job=linux_msan_chrome&range=496838:496881 Reproducer Testcase: https://clusterfuzz.com/download?testcase_id=5239140198383616 Issue filed automatically. See https://github.com/google/clusterfuzz-tools for more information.
,
Sep 26 2017
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
,
Sep 26 2017
,
Sep 26 2017
Predator Result: Fix bug of sequential display item matching broken by subsequence by wangxianzhu@chromium.org Changed files PaintController.cpp, PaintController.h, PaintControllerTest.cpp, with the same CrashedDirectory(third_party/WebKit/Source/core/paint) as InlineFlowBoxPainter.cpp (in frame#3), RootInlineBoxPainter.cpp (in frame#5), InlineTextBoxPainter.cpp (in frame#1) Changed files PaintController.cpp, PaintController.h, PaintControllerTest.cpp, with the same CrashedComponent(Blink>Paint) as InlineFlowBoxPainter.cpp (in frame#3), RootInlineBoxPainter.cpp (in frame#5), InlineTextBoxPainter.cpp (in frame#1)
,
Sep 26 2017
I'm confused by the report which says that the following code accesses uninitialized value:
if (start && end) {
^^^
Both |start| and |end| are just initialized above the code.
I added fprintf(stderr, ...) statements around the code to see which variable is uninitialized:
fprintf(stderr, "A %d %d %d\n", start, end, state);
if (start && end) {
state = SelectionState::kStartAndEnd;
fprintf(stderr, "B %d %d %d\n", start, end, state);
} else if (start) {
state = SelectionState::kStart;
fprintf(stderr, "C %d %d %d\n", start, end, state);
} else {
fprintf(stderr, "D %d %d %d\n", start, end, state);
if (end) {
^^^it reported use-of-uinitialized-value here
I also tried __msan_print_shadow(this, sizeof(this)) and __msan_print_shadow(&selection, sizeof(selection)). The former printed some uninitialized bits in |this| (InlineTextBox), but the bits are all paddings which is not accessed by any code. The latter printed no uninitialized value.
inferno@ is there anything I can do for this bug?
,
Sep 26 2017
Vitaly, thoughts here on MSAN report ?
,
Sep 26 2017
Report is at "selection.LayoutSelectionEnd().value() > start_ &&" It might be initialized with uninitialized value. Try to run with msan_track_origins=2
,
Sep 26 2017
,
Sep 26 2017
It's a nullopt dereferece: selection.LayoutSelectionEnd() can be nullopt. We should check for nullopt before using its value. Related CLs: https://chromium-review.googlesource.com/566268 https://chromium-review.googlesource.com/577986
,
Sep 27 2017
,
Oct 1 2017
Automatically applying components based on information from OWNERS files. If this seems incorrect, please apply the Test-Predator-Wrong-Components label.
,
Oct 1 2017
,
Oct 4 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/cfb338179e3d6b8da5b16a1ba1570aeb03480b47 commit cfb338179e3d6b8da5b16a1ba1570aeb03480b47 Author: Yoichi Osato <yoichio@chromium.org> Date: Wed Oct 04 05:28:17 2017 Avoid crash in InlineTextBox::GetSelectionState() FrameSelection::LayoutSelectionStart/End() is typed Optional<int> and we should not call it when selection is empty. However, LayoutObject::SelectionState and FrameSelection often fall into inconsistency: SelectionState is kStart but no selection. I'm working to clean SelectionState marking on Layout tree but this hits Use-of-uninitialized-value issue. As fix the security issue, this CL sets optional value |0| for selection offset. Introduce LayoutSelection::SelectionStart()/End() to TouchAdjustment: https://chromium-review.googlesource.com/c/chromium/src/+/566268 Bug: 768716 Change-Id: Ic634a3904b967258db8e1cd0ca8140a3e94c496d Reviewed-on: https://chromium-review.googlesource.com/686031 Commit-Queue: Yoichi Osato <yoichio@chromium.org> Reviewed-by: Koji Ishii <kojii@chromium.org> Reviewed-by: Yoshifumi Inoue <yosin@chromium.org> Cr-Commit-Position: refs/heads/master@{#506311} [modify] https://crrev.com/cfb338179e3d6b8da5b16a1ba1570aeb03480b47/third_party/WebKit/Source/core/layout/line/InlineTextBox.cpp
,
Oct 4 2017
,
Oct 4 2017
,
Oct 5 2017
ClusterFuzz has detected this issue as fixed in range 506303:506326. Detailed report: https://clusterfuzz.com/testcase?key=5239140198383616 Fuzzer: inferno_layout_test_unmodified Job Type: linux_msan_chrome Platform Id: linux Crash Type: Use-of-uninitialized-value Crash Address: Crash State: blink::InlineTextBox::GetSelectionState blink::InlineTextBoxPainter::Paint blink::InlineTextBox::Paint Sanitizer: memory (MSAN) Recommended Security Severity: Medium Regressed: https://clusterfuzz.com/revisions?job=linux_msan_chrome&range=496838:496881 Fixed: https://clusterfuzz.com/revisions?job=linux_msan_chrome&range=506303:506326 Reproducer Testcase: https://clusterfuzz.com/download?testcase_id=5239140198383616 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.
,
Oct 5 2017
ClusterFuzz testcase 5239140198383616 is verified as fixed, so closing issue as verified. If this is incorrect, please add ClusterFuzz-Wrong label and re-open the issue.
,
Nov 3 2017
,
Jan 10 2018
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
,
Mar 27 2018
|
|||||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||||
Comment 1 by sheriffbot@chromium.org
, Sep 26 2017