Skip to content
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

Page closure uses methods possibly overridden by page. #10

Open
init-js opened this issue Aug 13, 2016 · 0 comments
Open

Page closure uses methods possibly overridden by page. #10

init-js opened this issue Aug 13, 2016 · 0 comments

Comments

@init-js
Copy link

init-js commented Aug 13, 2016

When the project is refactored to match Chrome's move from properties to getters on DOM objects, it should also be refactored to use methods local to the "within" closure.

It is currently possible for an adversarial page to modify prototype methods, such as RegExp.test to allow /deep/ selectors and get access to .delegate objects despite checks done inside shadowcrypt.

function allowDeep() {
    if (this.toString() === "/\/deep\/|>>>/") {
        return false;
    }
}
RegExp.prototype.test = allowDeep;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant