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

chrome://image calls should be URI-encoded #43367

Open
diracdeltas opened this issue Jan 17, 2025 · 0 comments
Open

chrome://image calls should be URI-encoded #43367

diracdeltas opened this issue Jan 17, 2025 · 0 comments

Comments

@diracdeltas
Copy link
Member

we have many cases, mainly in wallet, where we call things like:

chrome://image?${dapp.logo}

the URL parameter should always be encoded using encodeURIComponent to avoid an external URL being able to inject parameters to chrome://image, i.e. https://source.chromium.org/chromium/chromium/src/+/main:chrome/browser/ui/webui/sanitized_image_source.h;l=47-54?q=chrome:%2F%2Fimage&ss=chromium

see https://github.com/search?q=repo%3Abrave%2Fbrave-core+chrome%3A%2F%2Fimage&type=code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants