- // Only some HTML tags are understood with params by MediaWiki, the rest are ignored.
- // List the tags that accept params below, as well as what those params are.
- public static $data = array(
- "B" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "CAPTION" => array( "CLASS", "ID", "STYLE", "align", "lang", "dir", "title" ),
- "CENTER" => array( "CLASS", "STYLE", "ID", "lang", "dir", "title" ),
- "DIV" => array( "CLASS", "STYLE", "ID", "align", "lang", "dir", "title" ),
- "FONT" => array( "CLASS", "STYLE", "ID", "lang", "dir", "title", "face", "size", "color" ),
- "H1" => array( "STYLE", "CLASS", "ID", "align", "lang", "dir", "title" ),
- "H2" => array( "STYLE", "CLASS", "ID", "align", "lang", "dir", "title" ),
- "HR" => array( "STYLE", "CLASS", "ID", "WIDTH", "lang", "dir", "title", "size", "noshade" ),
- "LI" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", "type", "value" ),
- "TABLE" => array( "STYLE", "CLASS", "ID", "BGCOLOR", "WIDTH", "ALIGN", "BORDER", "CELLPADDING",
- "CELLSPACING", "lang", "dir", "title", "summary", "frame", "rules" ),
- "TD" => array( "STYLE", "CLASS", "ID", "BGCOLOR", "WIDTH", "ALIGN", "COLSPAN", "ROWSPAN",
- "VALIGN", "abbr", "axis", "headers", "scope", "nowrap", "height", "lang",
- "dir", "title", "char", "charoff" ),
- "TH" => array( "STYLE", "CLASS", "ID", "BGCOLOR", "WIDTH", "ALIGN", "COLSPAN", "ROWSPAN",
- "VALIGN", "abbr", "axis", "headers", "scope", "nowrap", "height", "lang",
- "dir", "title", "char", "charoff" ),
- "TR" => array( "CLASS", "STYLE", "ID", "BGCOLOR", "ALIGN", "VALIGN", "lang", "dir", "title", "char", "charoff" ),
- "UL" => array( "CLASS", "STYLE", "ID", "lang", "dir", "title", "type" ),
- "P" => array( "style", "class", "id", "align", "lang", "dir", "title" ),
- "blockquote" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", "cite" ),
- "span" => array( "CLASS", "ID", "STYLE", "align", "lang", "dir", "title" ),
- "code" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "tt" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "small" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "big" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "s" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "u" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "del" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", "datetime", "cite" ),
- "ins" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", "datetime", "cite" ),
- "sub" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "sup" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "ol" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", "type", "start" ),
- "br" => array( "CLASS", "ID", "STYLE", "title", "clear" ),
- "cite" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "var" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "dl" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "ruby" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "rt" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "rp" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "dt" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "dl" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "em" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "strong" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "i" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
- "thead" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", 'align', 'char', 'charoff', 'valign' ),
- "tfoot" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", 'align', 'char', 'charoff', 'valign' ),
- "tbody" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", 'align', 'char', 'charoff', 'valign' ),
- "colgroup" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", 'align', 'char', 'charoff', 'valign', 'span', 'width' ),
- "col" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", 'align', 'char', 'charoff', 'valign', 'span', 'width' ),
- "pre" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", "width" ),
-
- // extension tags that accept parameters:
- "sort" => array( "order", "class" ),
- "ref" => array( "name" ),
- "categorytree" => array( "hideroot", "mode", "style" ),
- "chemform" => array( "link", "wikilink", "query" ),
- "section" => array( "begin", "new" ),
-
- // older MW transclusion.
- "transclude" => array( "page" ),
- );
-
- // The types of the HTML that we will be testing were defined above
- // Note: this needs to be initialized later to be equal to: array_keys(wikiFuzz::$data);
- // as such, it also needs to also be publicly modifiable.
- public static $types;
-
-
- // Some attribute values.
- static private $other = array( "&", "=", ":", "?", "\"", "\n", "%n%n%n%n%n%n%n%n%n%n%n%n", "\\" );
- static private $ints = array(
- // various numbers
- "0", "-1", "127", "-7897", "89000", "808080", "90928345",
- "0xfffffff", "ffff",
-
- // Different ways of saying: '
- "'", // Long UTF-8 Unicode encoding
- "'", // dec version.
- "'", // hex version.
- "§", // malformed hex variant, MSB not zero.
-
- // Different ways of saying: "
- """, // Long UTF-8 Unicode encoding
- """,
- """, // hex version.
- "¢", // malformed hex variant, MSB not zero.
-
- // Different ways of saying: <
- "<",
- "<", // Long UTF-8 Unicode encoding without semicolon (Mediawiki wants the colon)
- "<", // Long UTF-8 Unicode encoding with semicolon
- "<",
- "<", // hex version.
- "¼", // malformed hex variant, MSB not zero.
- "<", // mid-length hex version
- "<", // slightly longer hex version, with capital "X"
-
- // Different ways of saying: >
- ">",
- ">", // Long UTF-8 Unicode encoding
- ">",
- ">", // hex version.
- "¾", // malformed variant, MSB not zero.
-
- // Different ways of saying: [
- "[", // Long UTF-8 Unicode encoding
- "[",
- "[", // hex version.
-
- // Different ways of saying: {{
- "{{", // Long UTF-8 Unicode encoding
- "{{",
- "{{", // hex version.
-
- // Different ways of saying: |
- "|", // Long UTF-8 Unicode encoding
- "|",
- "|", // hex version.
- "ü", // malformed hex variant, MSB not zero.
+ // Only some HTML tags are understood with params by MediaWiki, the rest are ignored.
+ // List the tags that accept params below, as well as what those params are.
+ public static $data = array(
+ "B" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "CAPTION" => array( "CLASS", "ID", "STYLE", "align", "lang", "dir", "title" ),
+ "CENTER" => array( "CLASS", "STYLE", "ID", "lang", "dir", "title" ),
+ "DIV" => array( "CLASS", "STYLE", "ID", "align", "lang", "dir", "title" ),
+ "FONT" => array( "CLASS", "STYLE", "ID", "lang", "dir", "title", "face", "size", "color" ),
+ "H1" => array( "STYLE", "CLASS", "ID", "align", "lang", "dir", "title" ),
+ "H2" => array( "STYLE", "CLASS", "ID", "align", "lang", "dir", "title" ),
+ "HR" => array( "STYLE", "CLASS", "ID", "WIDTH", "lang", "dir", "title", "size", "noshade" ),
+ "LI" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", "type", "value" ),
+ "TABLE" => array( "STYLE", "CLASS", "ID", "BGCOLOR", "WIDTH", "ALIGN", "BORDER", "CELLPADDING",
+ "CELLSPACING", "lang", "dir", "title", "summary", "frame", "rules" ),
+ "TD" => array( "STYLE", "CLASS", "ID", "BGCOLOR", "WIDTH", "ALIGN", "COLSPAN", "ROWSPAN",
+ "VALIGN", "abbr", "axis", "headers", "scope", "nowrap", "height", "lang",
+ "dir", "title", "char", "charoff" ),
+ "TH" => array( "STYLE", "CLASS", "ID", "BGCOLOR", "WIDTH", "ALIGN", "COLSPAN", "ROWSPAN",
+ "VALIGN", "abbr", "axis", "headers", "scope", "nowrap", "height", "lang",
+ "dir", "title", "char", "charoff" ),
+ "TR" => array( "CLASS", "STYLE", "ID", "BGCOLOR", "ALIGN", "VALIGN", "lang", "dir", "title", "char", "charoff" ),
+ "UL" => array( "CLASS", "STYLE", "ID", "lang", "dir", "title", "type" ),
+ "P" => array( "style", "class", "id", "align", "lang", "dir", "title" ),
+ "blockquote" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", "cite" ),
+ "span" => array( "CLASS", "ID", "STYLE", "align", "lang", "dir", "title" ),
+ "code" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "tt" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "small" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "big" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "s" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "u" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "del" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", "datetime", "cite" ),
+ "ins" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", "datetime", "cite" ),
+ "sub" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "sup" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "ol" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", "type", "start" ),
+ "br" => array( "CLASS", "ID", "STYLE", "title", "clear" ),
+ "cite" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "var" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "dl" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "ruby" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "rt" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "rp" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "dt" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "dl" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "em" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "strong" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "i" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title" ),
+ "thead" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", 'align', 'char', 'charoff', 'valign' ),
+ "tfoot" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", 'align', 'char', 'charoff', 'valign' ),
+ "tbody" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", 'align', 'char', 'charoff', 'valign' ),
+ "colgroup" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", 'align', 'char', 'charoff', 'valign', 'span', 'width' ),
+ "col" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", 'align', 'char', 'charoff', 'valign', 'span', 'width' ),
+ "pre" => array( "CLASS", "ID", "STYLE", "lang", "dir", "title", "width" ),
+
+ // extension tags that accept parameters:
+ "sort" => array( "order", "class" ),
+ "ref" => array( "name" ),
+ "categorytree" => array( "hideroot", "mode", "style" ),
+ "chemform" => array( "link", "wikilink", "query" ),
+ "section" => array( "begin", "new" ),
+
+ // older MW transclusion.
+ "transclude" => array( "page" ),
+ );
+
+ // The types of the HTML that we will be testing were defined above
+ // Note: this needs to be initialized later to be equal to: array_keys(wikiFuzz::$data);
+ // as such, it also needs to also be publicly modifiable.
+ public static $types;
+
+
+ // Some attribute values.
+ static private $other = array( "&", "=", ":", "?", "\"", "\n", "%n%n%n%n%n%n%n%n%n%n%n%n", "\\" );
+ static private $ints = array(
+ // various numbers
+ "0", "-1", "127", "-7897", "89000", "808080", "90928345",
+ "0xfffffff", "ffff",
+
+ // Different ways of saying: '
+ "'", // Long UTF-8 Unicode encoding
+ "'", // dec version.
+ "'", // hex version.
+ "§", // malformed hex variant, MSB not zero.
+
+ // Different ways of saying: "
+ """, // Long UTF-8 Unicode encoding
+ """,
+ """, // hex version.
+ "¢", // malformed hex variant, MSB not zero.
+
+ // Different ways of saying: <
+ "<",
+ "<", // Long UTF-8 Unicode encoding without semicolon (Mediawiki wants the colon)
+ "<", // Long UTF-8 Unicode encoding with semicolon
+ "<",
+ "<", // hex version.
+ "¼", // malformed hex variant, MSB not zero.
+ "<", // mid-length hex version
+ "<", // slightly longer hex version, with capital "X"
+
+ // Different ways of saying: >
+ ">",
+ ">", // Long UTF-8 Unicode encoding
+ ">",
+ ">", // hex version.
+ "¾", // malformed variant, MSB not zero.
+
+ // Different ways of saying: [
+ "[", // Long UTF-8 Unicode encoding
+ "[",
+ "[", // hex version.
+
+ // Different ways of saying: {{
+ "{{", // Long UTF-8 Unicode encoding
+ "{{",
+ "{{", // hex version.
+
+ // Different ways of saying: |
+ "|", // Long UTF-8 Unicode encoding
+ "|",
+ "|", // hex version.
+ "ü", // malformed hex variant, MSB not zero.