Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F5306
Sanitizer.patch
Public
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Authored By
•
bzimport
Nov 21 2014, 10:25 PM
2014-11-21 22:25:32 (UTC+0)
Size
581 B
Referenced Files
None
Subscribers
None
Sanitizer.patch
View Options
Index: Sanitizer.php
===================================================================
--- Sanitizer.php (revision 45716)
+++ Sanitizer.php (working copy)
@@ -40,10 +40,11 @@
* Allows some... latitude.
* Used in Sanitizer::fixTagAttributes and Sanitizer::decodeTagAttributes
*/
-$attrib = '[A-Za-z0-9]';
+$attrib_first = '[:A-Z_a-z]';
+$attrib = '[:A-Z_a-z-.0-9]';
$space = '[\x09\x0a\x0d\x20]';
define( 'MW_ATTRIBS_REGEX',
- "/(?:^|$space)($attrib+)
+ "/(?:^|$space)({$attrib_first}{$attrib}*)
($space*=$space*
(?:
# The attribute value: quoted or alone
File Metadata
Details
Attached
Mime Type
text/x-diff
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
4867
Default Alt Text
Sanitizer.patch (581 B)
Attached To
Mode
T19031: Sanitizer rejects valid xhtml attributes
Attached
Detach File
Event Timeline
Log In to Comment