Ticket #10151 (new enhancement)

Opened 8 months ago

Last modified 10 hours ago

HTML5 <video> elements stripped in kses.php

Reported by: GChriss Owned by: ryan
Priority: normal Milestone: Future Release
Component: Security Version: 2.8
Severity: normal Keywords: needs-patch
Cc: blizzard@…, robert@…

Description

WordPress currently strips the  new HTML5 <video> element as it is unrecognized. The attached patch allows <video> passthrough in postings and comments.

Hopefully this patch (or a derivative) could be incorporated into WordPress proper.

Attachments

wordpress_html5_video_patch.txt Download (1.4 KB) - added by GChriss 8 months ago.
Patch to kses.php to enable HTML5 <video> passthrough

Change History

Patch to kses.php to enable HTML5 <video> passthrough

  • keywords needs-patch added
  • owner set to ryan
  • type changed from defect (bug) to enhancement
  • component changed from Comments to Security
  • milestone changed from Unassigned to 2.9

I'm 100% certain we don't wan't porn and spamercials in comments.

  • keywords <video>, video, HTML5 removed

<video> should be preserved only in postings IMO... allow posting videos in comment is dangerous.

No <audio>? No <source>?

nacin3 months ago
  • milestone changed from 2.9 to Future Release
  • cc blizzard@… added

This probably needs to support the source elements as well, so we can build in fallbacks for safari, firefox, IE, etc. You need the source element to be able to do that.

Our biggest problem is that the wysiwyg editor strips out <video> tags which makes it hard for people to edit posts without a lot of technical experience. Will this bug help with that? (I'm not sure what role kses.php plays in that.)

azaozz6 weeks ago

It's not hard to stop TinyMCE stripping <video>, <audio> and other new HTML 5.0 tags. The problem is what would the browsers show in the contentEditable iframe and would that bring any security problems. KSES is the backend HTML safety filter.

  • cc robert@… added
Note: See TracTickets for help on using tickets.