-
Notifications
You must be signed in to change notification settings - Fork 878
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
Prevent loading brave scheme url from javascript #1196
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Will remove WIP after adding tests. |
simonhong
force-pushed
the
prevent_brave_scheme_loading_from_js
branch
3 times, most recently
from
January 8, 2019 09:09
3ac69f5
to
c5339e1
Compare
To fix this, brave scheme is registered to WebSecurityPolicy and RequestScheme of ChildProcessSecurityPolicy::SecurityState. Also, makes ProfileIOData::IsHandledProtocol consider brave scheme.
As brave scheme can be loaded only from brave scheme, it should use chrome scheme instead of brave scheme in anchor tag.. Otherwise, that brave webui loading is prevented in brave webui from renderer.
simonhong
force-pushed
the
prevent_brave_scheme_loading_from_js
branch
from
January 8, 2019 10:58
c5339e1
to
061aca7
Compare
simonhong
changed the title
WIP: Prevent loading brave scheme url from javascript
Prevent loading brave scheme url from javascript
Jan 8, 2019
Edited the PR description to not close brave/brave-browser#2777 but instead close brave/brave-browser#2861 |
bbondy
approved these changes
Jan 8, 2019
bbondy
added a commit
that referenced
this pull request
Jan 8, 2019
Prevent loading brave scheme url from javascript
bbondy
added a commit
that referenced
this pull request
Jan 8, 2019
Prevent loading brave scheme url from javascript
bbondy
added a commit
that referenced
this pull request
Jan 8, 2019
Prevent loading brave scheme url from javascript
This was referenced Jan 8, 2019
18 tasks
This was referenced Feb 19, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
To fix this, brave scheme is registered to WebSecurityPolicy and
RequestScheme of ChildProcessSecurityPolicy::SecurityState.
Also, makes ProfileIOData::IsHandledProtocol consider brave scheme.
As brave scheme can be loaded only from brave scheme,
it should use chrome scheme instead of brave scheme in anchor tag..
Otherwise, that brave webui loading is prevented in brave webui from renderer.
Fix brave/brave-browser#2861
Fix brave/brave-browser#2849
Submitter Checklist:
npm test brave_unit_tests && npm test brave_browser_tests
) ongit rebase master
(if needed).git rebase -i
to squash commits (if needed).Test Plan:
Test 1.
Test 2.
Change your search engine
page in welcome pageSettings
buttonTest 3.
Reviewer Checklist: