New issue
Advanced search Search tips

Issue 813630 link

Starred by 1 user

Issue metadata

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



Sign in to add a comment

DCHECK failure in !has_rest_ in scopes.cc

Project Member Reported by ClusterFuzz, Feb 19 2018

Issue description

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

Fuzzer: libFuzzer_v8_script_parser_fuzzer
Job Type: libfuzzer_chrome_asan_debug
Platform Id: linux

Crash Type: DCHECK failure
Crash Address: 
Crash State:
  !has_rest_ in scopes.cc
  v8::internal::DeclarationScope::DeclareParameter
  DeclareFormalParameters
  
Sanitizer: address (ASAN)

Regressed: https://clusterfuzz.com/revisions?job=libfuzzer_chrome_asan_debug&range=499534:499545

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

Issue filed automatically.

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

Comment 1 by ClusterFuzz, Feb 19 2018

Components: Blink>JavaScript>Language Blink>JavaScript>Parser
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.

Comment 2 by marja@chromium.org, Feb 20 2018

Owner: marja@chromium.org
Umm, can't access the test case... seeing if setting me as an owner helps.

Comment 3 by marja@chromium.org, Feb 20 2018

Ok that helped. The minified test case claims to be:

// C(a, b) { s }
function g(...args) { reonincontintecontinckftinteoninteconecontinteconcintecnteconintecootintecoftinteconintecontintecontonintecontintecoftinteconinteonteintectinteconiecontitinteeconintecotinteconcontint;s;sent=htod;sent;sent;sent=htod;sent;sent;sent=htod;sent;sent;se=htod;t;sent;s=htod;sent;sent;t=htod;sent;s;sent=hd;senecoftinteconeconftinteconincontieconintecontintecoftinteconinteconticoftintecontecontinteconcontiecoftinteconintecontinteconcontin;sent;htod;se;nstent;d;sent;sent;sent=ht;sent;sent;htod;sent;sent;seod;set;sent;sent=htod;sent;sent;sent=htod;nt;sent=htod;s;sent;ent;sent=htod;sent;sent;sentd;sent;sent;s        ;sent;sent;sent=htod;continteecnteconftintececontieceintecoftinteconintecontintecontecontinteconinteccontteconintececoncotecontconintecootintecofteconinteconconctecofteconintecntinteoneteconintecontinteconcontin;sent;sent=htod;se;sent;sent=d;sent;sent;set=htod;sent;sent;d;sent;sent;sent=htod;sent;sent;sentod;sent;sent;tod;senconcontineoftintecnteconfticoecontieconintecontintecoftinteecontintecoftinteconintecontieecoftintecoinetinteconntin;sent;sent=htod;se;nt;sen=thtod;e;sent;sent=htod;sent;sent;sent=htod;sent;sent;sentd;sent;sent;senttod;sent;sent;        d;sent;sent=htod;sent;st;sulfle/!}ll0e0.^~



But I can't repro, at least not with d8.
Project Member

Comment 4 by sheriffbot@chromium.org, Feb 20 2018

Labels: M-64
Project Member

Comment 5 by sheriffbot@chromium.org, Feb 20 2018

Labels: Pri-1
Project Member

Comment 6 by sheriffbot@chromium.org, Feb 20 2018

Status: Assigned (was: Untriaged)

Comment 7 by kenrb@chromium.org, Mar 1 2018

marja@: Did you try to repro on an ASAN build, which might make a difference?

Also, are there clear implication of that DCHECK failing? It's not clear the severity on this bug is correct.

Comment 8 by marja@chromium.org, Mar 5 2018

Yeah, I can't repro with asan either.

I'm also not sure about the severity. It's a syntax error, so, the script won't be executed. Looking at the DCHECK, if we carry on at that point, looks like we would reintroduce a rest parameter, but, if we don't compile the script anyway, it looks relatively harmless.

Btw, looking at the repro case, I don't see how that would cause that DCHECK to fire, since there's no second rest parameter anywhere and when we introduce the rest parameter, everything's still syntactically correct... I wonder whether there's something I was missing when trying to extract the repro case.
Project Member

Comment 9 by sheriffbot@chromium.org, Mar 7 2018

Labels: -M-64 M-65
Project Member

Comment 10 by sheriffbot@chromium.org, Mar 20 2018

marja: 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 11 by marja@chromium.org, Mar 21 2018

Cc: adamk@chromium.org

Comment 12 by marja@chromium.org, Mar 21 2018

Contrary to the status quo before, now I can actually repro this with v8_script_parser_fuzzer. Investigating...

Comment 13 by marja@chromium.org, Mar 21 2018

Labels: -Security_Impact-Stable -Security_Severity-High
OMG, this is the "aborting preparsing" feature again. Looks like the has_rest_ is just not reset properly. Fix underway.

I don't think this is security critical, so removing the labels.
Project Member

Comment 15 by bugdroid1@chromium.org, Mar 21 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/v8/v8.git/+/4f506dbeec3fad4c7bcdda68c3ff701dbc52f055

commit 4f506dbeec3fad4c7bcdda68c3ff701dbc52f055
Author: Marja Hölttä <marja@chromium.org>
Date: Wed Mar 21 09:04:07 2018

[parser] Fix aborting preparsing of a function with a rest param.

BUG= chromium:813630 

Change-Id: I9eeaeb8830533c178c8073f48f036f9af8887a55
Reviewed-on: https://chromium-review.googlesource.com/972901
Reviewed-by: Adam Klein <adamk@chromium.org>
Commit-Queue: Marja Hölttä <marja@chromium.org>
Cr-Commit-Position: refs/heads/master@{#52095}
[modify] https://crrev.com/4f506dbeec3fad4c7bcdda68c3ff701dbc52f055/src/ast/scopes.cc
[add] https://crrev.com/4f506dbeec3fad4c7bcdda68c3ff701dbc52f055/test/mjsunit/regress/regress-crbug-813630.js

Comment 16 by marja@chromium.org, Mar 21 2018

Status: Fixed (was: Assigned)
Marking fixed. As it's just a tracking variable that we failed to update properly (the actual parameters are cleared properly), I don't think this has any actual impact. I don't think merges are needed here.
Project Member

Comment 17 by sheriffbot@chromium.org, Mar 21 2018

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

Comment 18 by ClusterFuzz, Mar 22 2018

ClusterFuzz has detected this issue as fixed in range 544721:544735.

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

Fuzzer: libFuzzer_v8_script_parser_fuzzer
Job Type: libfuzzer_chrome_asan_debug
Platform Id: linux

Crash Type: DCHECK failure
Crash Address: 
Crash State:
  !has_rest_ in scopes.cc
  v8::internal::DeclarationScope::DeclareParameter
  DeclareFormalParameters
  
Sanitizer: address (ASAN)

Regressed: https://clusterfuzz.com/revisions?job=libfuzzer_chrome_asan_debug&range=499534:499545
Fixed: https://clusterfuzz.com/revisions?job=libfuzzer_chrome_asan_debug&range=544721:544735

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

See https://chromium.googlesource.com/chromium/src/+/master/testing/libfuzzer/reference.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 19 by ClusterFuzz, Mar 22 2018

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

If this is incorrect, please add ClusterFuzz-Wrong label and re-open the issue.
Labels: -Type-Bug-Security Type-Bug
Flipping to "bug" per c21
Project Member

Comment 21 by sheriffbot@chromium.org, Jun 27 2018

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

Sign in to add a comment