ezyang / ezyang/htmlpurifier

iframe does not contain src attribute

Open
#235 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
PHP
Stars
3.4k
Forks
361
Avg merge
3d 41m
Merged PRs (30d)
2

Description

Purify seems to get rid of the src attribute when using iframes. Not sure why.

I'm using HTML.SafeIFrame, tried different URI.safeIframeRegexp and in HTML.allowed I have iframe[src].

Any ideas?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the reported iframe case with HTML.SafeIFrame, the configured URI.safeIframeRegexp, and HTML.allowed set to iframe[src]. Compare the input and purified output to identify why src is removed; done when an allowed iframe retains its src while unsafe values remain filtered.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
security
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.