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

EmbedAPI: clean source (src) properly from inside a tooltip #9344

Open
humitos opened this issue Jun 16, 2022 · 3 comments
Open

EmbedAPI: clean source (src) properly from inside a tooltip #9344

humitos opened this issue Jun 16, 2022 · 3 comments
Assignees
Labels
Accepted Accepted issue on our roadmap Improvement Minor improvement to code

Comments

@humitos
Copy link
Member

humitos commented Jun 16, 2022

It may be good to expand clean_resources to also rewrite <source src=...> HTML tags.

Eric mentioned this in #9337 (comment)

This issue could serve also to do some extra research and try to find out more HTML tags that require HTML rewriting to make the tooltip content render properly.

@humitos humitos added Improvement Minor improvement to code Accepted Accepted issue on our roadmap labels Jun 16, 2022
@humitos humitos self-assigned this Jun 16, 2022
@benjaoming
Copy link
Contributor

Consider bleach for stripping the HTML to exactly the tags and attributes that should be allowed.

@humitos
Copy link
Member Author

humitos commented Jun 27, 2022

@benjaoming I didn't know bleach. I've read a little of the documentation but I'm not sure to follow how you would use it for the purpose of the issue. Can you explain a little more about how you would use bleach for this?

@benjaoming
Copy link
Contributor

It's not directly related to the issue -- bleach can ensure that we only have expected tags, attributes and CSS classes transferred. Probably belongs in a separate issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Accepted Accepted issue on our roadmap Improvement Minor improvement to code
Projects
Status: Planned
Development

No branches or pull requests

2 participants