-
Notifications
You must be signed in to change notification settings - Fork 879
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix loading brave crash url doesn't cause renderer crash #2229
Conversation
b66ef31
to
fc2dcfb
Compare
@bsclifton @rebron the above fixes the |
if (url.SchemeIs(url::kJavaScriptScheme)) | ||
return true; | ||
|
||
+#if defined(BRAVE_CHROMIUM_BUILD) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm confused, this is not the change we talked about
const char kBraveUIShorthangURL[] = "brave://shorthang/"; | ||
|
||
bool IsBraveRendererDebugURL(const GURL& url) { | ||
if (url == kBraveUICheckCrashURL || url == kBraveUIBadCastCrashURL || |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think this is the change we want anyway, but why would we do all this when we could just convert chrome -> brave and call IsRendererDebugURL
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
see comments
@@ -0,0 +1,40 @@ | |||
/* Copyright (c) 2019 The Brave Authors. All rights reserved. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is not a test of url_utils, it's a test of the navigation controller
53fa1ee
to
ef0c479
Compare
Will merge when buildbot completes its build |
4b1ebaa
to
46e6647
Compare
@bridiver Can you approve again? To make buildbot green, I rebased and still can't get all green because of not related with this PR(signing issue). (https://staging.ci.brave.com/job/brave-browser-build-pr/job/fix_brave_crash_url/8/execution/node/410/log/) |
Send converted debug url to renderer.
…arts With this, IsRendererDebugURL() can check with converted url.
46e6647
to
f24b048
Compare
… exist Because it was only added from #2229 which is only in 0.64.x Auditors: @bsclifton Related to ab02110
Send converted debug url to renderer instead of user typed url.
Also convert to chrome scheme more earlier when browser initiated navigation starts.
With this earlier converting, IsRendererDebugURL() can check with converted url.
Fix brave/brave-browser#4111
Submitter Checklist:
npm test brave_unit_tests && npm test brave_browser_tests && npm run test-security
) onnpm run lint
)git rebase master
(if needed).git rebase -i
to squash commits (if needed).Test Plan:
npm test brave_browser_tests --filter=BraveSchemeLoadBrowserTest.CrashURLTest
Reviewer Checklist: