[3.1.1] Disable percent height/width attributes for img
[htmlpurifier.git] / NEWS
blobc0f131e85abdcc38f647492a018bd9b7da8f9343
1 NEWS ( CHANGELOG and HISTORY )                                     HTMLPurifier
2 |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
4 = KEY ====================
5     # Breaks back-compat
6     ! Feature
7     - Bugfix
8       + Sub-comment
9     . Internal change
10 ==========================
12 3.1.1, unknown release date
13 ! More robust imagecrash protection with height/width CSS with %CSS.MaxImgLength.
14 - Disable percent height/width attributes for img
15 . Added HTMLPurifier_UnitConverter and HTMLPurifier_Length for convenient
16   handling of CSS-style lengths. HTMLPurifier_AttrDef_CSS_Length now uses
17   this class.
18 . API of HTMLPurifier_AttrDef_CSS_Length changed from __construct($disable_negative)
19   to __construct($min, $max). __construct(true) is equivalent to
20   __construct('0').
21 . Added HTMLPurifier_AttrDef_Switch class
23 3.1.0, released 2008-05-18
24 # Unnecessary references to objects (vestiges of PHP4) removed from method
25   signatures.  The following methods do not need references when assigning from
26   them and will result in E_STRICT errors if you try:
27     + HTMLPurifier_Config->get*Definition() [* = HTML, CSS]
28     + HTMLPurifier_ConfigSchema::instance()
29     + HTMLPurifier_DefinitionCacheFactory::instance()
30     + HTMLPurifier_DefinitionCacheFactory->create()
31     + HTMLPurifier_DoctypeRegistry->register()
32     + HTMLPurifier_DoctypeRegistry->get()
33     + HTMLPurifier_HTMLModule->addElement()
34     + HTMLPurifier_HTMLModule->addBlankElement()
35     + HTMLPurifier_LanguageFactory::instance()
36 # Printer_ConfigForm's get*() functions were static-ified
37 # %HTML.ForbiddenAttributes requires attribute declarations to be in the
38   form of tag@attr, NOT tag.attr (which will throw an error and won't do
39   anything). This is for forwards compatibility with XML; you'd do best
40   to migrate an %HTML.AllowedAttributes directives to this syntax too.
41 ! Allow index to be false for config from form creation
42 ! Added HTMLPurifier::VERSION constant
43 ! Commas, not dashes, used for serializer IDs. This change is forwards-compatible
44   and allows for version numbers like "3.1.0-dev".
45 ! %HTML.Allowed deals gracefully with whitespace anywhere, anytime!
46 ! HTML Purifier's URI handling is a lot more robust, with much stricter
47   validation checks and better percent encoding handling.
48 ! Bootstrap autoloader deals more robustly with classes that don't exist,
49   preventing class_exists($class, true) from barfing.
50 - InterchangeBuilder now alphabetizes its lists
51 - Validation error in configdoc output fixed
52 - Iconv and other encoding errors muted even with custom error handlers that
53   do not honor error_reporting
54 - Add protection against imagecrash attack with CSS height/width
55 - HTMLPurifier::instance() created for consistency, is equivalent to getInstance()
56 - Fixed and revamped broken ConfigForm smoketest
57 - Bug with bool/null fields in Printer_ConfigForm fixed
58 - Bug with global forbidden attributes fixed
59 - Improved error messages for allowed and forbidden HTML elements and attributes
60 - Missing (or null) in configdoc documentation restored
61 - If DOM throws and exception during parsing with PH5P (occurs in newer versions
62   of DOM), HTML Purifier punts to DirectLex
63 - Fatal error with unserialization of ScriptRequired
64 - Created directories are now chmod'ed properly
65 - Fixed bug with fallback languages in LanguageFactory
66 - Standalone testing setup properly with autoload
67 . Out-of-date documentation revised
68 . UTF-8 encoding check optimization as suggested by Diego
69 . HTMLPurifier_Error removed in favor of exceptions
70 . More copy() function removed; should use clone instead
71 . More extensive unit tests for HTMLDefinition
72 . assertPurification moved to central harness
73 . HTMLPurifier_Generator accepts $config and $context parameters during
74   instantiation, not runtime
75 . Double-quotes outside of attribute values are now unescaped
77 3.1.0rc1, released 2008-04-22
78 # Autoload support added. Internal require_once's removed in favor of an
79   explicit require list or autoloading. To use HTML Purifier,
80   you must now either use HTMLPurifier.auto.php
81   or HTMLPurifier.includes.php; setting the include path and including
82   HTMLPurifier.php is insufficient--in such cases include HTMLPurifier.autoload.php
83   as well to register our autoload handler (or modify your autoload function
84   to check HTMLPurifier_Bootstrap::getPath($class)). You can also use
85   HTMLPurifier.safe-includes.php for a less performance friendly but more
86   user-friendly library load.
87 # HTMLPurifier_ConfigSchema static functions are officially deprecated. Schema
88   information is stored in the ConfigSchema directory, and the
89   maintenance/generate-schema-cache.php generates the schema.ser file, which
90   is now instantiated. Support for userland schema changes coming soon!
91 # HTMLPurifier_Config will now throw E_USER_NOTICE when you use a directive
92   alias; to get rid of these errors just modify your configuration to use
93   the new directive name.
94 # HTMLPurifier->addFilter is deprecated; built-in filters can now be
95   enabled using %Filter.$filter_name or by setting your own filters using
96   %Filter.Custom
97 # Directive-level safety properties superceded in favor of module-level
98   safety. Internal method HTMLModule->addElement() has changed, although 
99   the externally visible HTMLDefinition->addElement has *not* changed.
100 ! Extra utility classes for testing and non-library operations can
101   be found in extras/. Specifically, these are FSTools and ConfigDoc.
102   You may find a use for these in your own project, but right now they
103   are highly experimental and volatile.
104 ! Integration with PHPT allows for automated smoketests
105 ! Limited support for proprietary HTML elements, namely <marquee>, sponsored
106   by Chris. You can enable them with %HTML.Proprietary if your client
107   demands them.
108 ! Support for !important CSS cascade modifier. By default, this will be stripped
109   from CSS, but you can enable it using %CSS.AllowImportant
110 ! Support for display and visibility CSS properties added, set %CSS.AllowTricky
111   to true to use them.
112 ! HTML Purifier now has its own Exception hierarchy under HTMLPurifier_Exception.
113   Developer error (not enduser error) can cause these to be triggered.
114 ! Experimental kses() wrapper introduced with HTMLPurifier.kses.php
115 ! Finally %CSS.AllowedProperties for tweaking allowed CSS properties without
116   mucking around with HTMLPurifier_CSSDefinition
117 ! ConfigDoc output has been enhanced with version and deprecation info.
118 ! %HTML.ForbiddenAttributes and %HTML.ForbiddenElements implemented.
119 - Autoclose now operates iteratively, i.e. <span><span><div> now has
120   both span tags closed.
121 - Various HTMLPurifier_Config convenience functions now accept another parameter
122   $schema which defines what HTMLPurifier_ConfigSchema to use besides the
123   global default.
124 - Fix bug with trusted script handling in libxml versions later than 2.6.28.
125 - Fix bug in ExtractStyleBlocks with comments in style tags
126 - Fix bug in comment parsing for DirectLex
127 - Flush output now displayed when in command line mode for unit tester
128 - Fix bug with rgb(0, 1, 2) color syntax with spaces inside shorthand syntax
129 - HTMLPurifier_HTMLDefinition->addAttribute can now be called multiple times
130   on the same element without emitting errors.
131 - Fixed fatal error in PH5P lexer with invalid tag names
132 . Plugins now get their own changelogs according to project conventions.
133 . Convert tokens to use instanceof, reducing memory footprint and
134   improving comparison speed.
135 . Dry runs now supported in SimpleTest; testing facilities improved
136 . Bootstrap class added for handling autoloading functionality
137 . Implemented recursive glob at FSTools->globr
138 . ConfigSchema now has instance methods for all corresponding define* 
139   static methods.
140 . A couple of new historical maintenance scripts were added.
141 . HTMLPurifier/HTMLModule/Tidy/XHTMLAndHTML4.php split into two files
142 . tests/index.php can now be run from any directory.
143 . HTMLPurifier_Token subclasses split into seperate files
144 . HTMLPURIFIER_PREFIX now is defined in Bootstrap.php, NOT HTMLPurifier.php
145 . HTMLPURIFIER_PREFIX can now be defined outside of HTML Purifier
146 . New --php=php flag added, allows PHP executable to be specified (command
147   line only!)
148 . htmlpurifier_add_test() preferred method to translate test files in to
149   classes, because it handles PHPT files too.
150 . Debugger class is deprecated and will be removed soon.
151 . Command line argument parsing for testing scripts revamped, now --opt value
152   format is supported.
153 . Smoketests now cleanup after magic quotes
154 . Generator now can output comments (however, comments are still stripped
155   from HTML Purifier output)
156 . HTMLPurifier_ConfigSchema->validate() deprecated in favor of
157   HTMLPurifier_VarParser->parse()
158 . Integers auto-cast into float type by VarParser.
159 . HTMLPURIFIER_STRICT removed; no validation is performed on runtime, only 
160   during cache generation
161 . Reordered script calls in maintenance/flush.php
162 . Command line scripts now honor exit codes
163 . When --flush fails in unit testers, abort tests and print message
164 . Improved documentation in docs/dev-flush.html about the maintenance scripts
165 . copy() methods removed in favor of clone keyword
167 3.0.0, released 2008-01-06
168 # HTML Purifier is PHP 5 only! The 2.1.x branch will be maintained
169   until PHP 4 is completely deprecated, but no new features will be added
170   to it.
171   + Visibility declarations added
172   + Constructor methods renamed to __construct()
173   + PHP4 reference cruft removed (in progress)
174 ! CSS properties are now case-insensitive
175 ! DefinitionCacheFactory now can register new implementations
176 ! New HTMLPurifier_Filter_ExtractStyleBlocks for extracting <style> from
177   documents and cleaning their contents up. Requires the CSSTidy library
178   <http://csstidy.sourceforge.net/>. You can access the blocks with the
179   'StyleBlocks' Context variable ($purifier->context->get('StyleBlocks')).
180   The output CSS can also be "scoped" for a specific element, use:
181   %Filter.ExtractStyleBlocksScope
182 ! Experimental support for some proprietary CSS attributes allowed:
183   opacity (and all of the browser-specific equivalents) and scrollbar colors.
184   Enable by setting %CSS.Proprietary to true.
185 - Colors missing # but in hex form will be corrected
186 - CSS Number algorithm improved
187 - Unit testing and multi-testing now on steroids: command lines,
188   XML output, and other goodies now added.
189 . Unit tests for Injector improved
190 . New classes:
191   + HTMLPurifier_AttrDef_CSS_AlphaValue
192   + HTMLPurifier_AttrDef_CSS_Filter
193 . Multitest now has a file docblock
195 2.1.3, released 2007-11-05
196 ! tests/multitest.php allows you to test multiple versions by running
197   tests/index.php through multiple interpreters using `phpv` shell
198   script (you must provide this script!)
199 - Fixed poor include ordering for Email URI AttrDefs, causes fatal errors
200   on some systems.
201 - Injector algorithm further refined: off-by-one error regarding skip 
202   counts for dormant injectors fixed
203 - Corrective blockquote definition now enabled for HTML 4.01 Strict
204 - Fatal error when <img> tag (or any other element with required attributes)
205   has 'id' attribute fixed, thanks NykO18 for reporting
206 - Fix warning emitted when a non-supported URI scheme is passed to the
207   MakeAbsolute URIFilter, thanks NykO18 (again)
208 - Further refine AutoParagraph injector. Behavior inside of elements
209   allowing paragraph tags clarified: only inline content delimeted by
210   double newlines (not block elements) are paragraphed.
211 - Buggy treatment of end tags of elements that have required attributes
212   fixed (does not manifest on default tag-set)
213 - Spurious internal content reorganization error suppressed
214 - HTMLDefinition->addElement now returns a reference to the created
215   element object, as implied by the documentation
216 - Phorum mod's HTML Purifier help message expanded (unreleased elsewhere)
217 - Fix a theoretical class of infinite loops from DirectLex reported
218   by Nate Abele
219 - Work around unnecessary DOMElement type-cast in PH5P that caused errors
220   in PHP 5.1
221 - Work around PHP 4 SimpleTest lack-of-error complaining for one-time-only
222   HTMLDefinition errors, this may indicate problems with error-collecting
223   facilities in PHP 5
224 - Make ErrorCollectorEMock work in both PHP 4 and PHP 5
225 - Make PH5P work with PHP 5.0 by removing unnecessary array parameter typedef
226 . %Core.AcceptFullDocuments renamed to %Core.ConvertDocumentToFragment 
227   to better communicate its purpose
228 . Error unit tests can now specify the expectation of no errors. Future
229   iterations of the harness will be extremely strict about what errors
230   are allowed
231 . Extend Injector hooks to allow for more powerful injector routines
232 . HTMLDefinition->addBlankElement created, as according to the HTMLModule
233   method
234 . Doxygen configuration file updated, with minor improvements
235 . Test runner now checks for similarly named files in conf/ directory too.
236 . Minor cosmetic change to flush-definition-cache.php: trailing newline is
237   outputted
238 . Maintenance script for generating PH5P patch added, original PH5P source
239   file also added under version control
240 . Full unit test runner script title made more descriptive with PHP version
241 . Updated INSTALL file to state that 4.3.7 is the earliest version we
242   are actively testing
244 2.1.2, released 2007-09-03
245 ! Implemented Object module for trusted users
246 ! Implemented experimental HTML5 parsing mode using PH5P. To use, add
247   this to your code:
248         require_once 'HTMLPurifier/Lexer/PH5P.php';
249         $config->set('Core', 'LexerImpl', 'PH5P');
250   Note that this Lexer introduces some classes not in the HTMLPurifier
251   namespace.  Also, this is PHP5 only.
252 ! CSS property border-spacing implemented
253 - Fix non-visible parsing error in DirectLex with empty tags that have
254   slashes inside attribute values.
255 - Fix typo in CSS definition: border-collapse:seperate; was incorrectly
256   accepted as valid CSS. Usually non-visible, because this styling is the
257   default for tables in most browsers. Thanks Brett Zamir for pointing
258   this out.
259 - Fix validation errors in configuration form
260 - Hammer out a bunch of edge-case bugs in the standalone distribution
261 - Inclusion reflection removed from URISchemeRegistry; you must manually
262   include any new schema files you wish to use
263 - Numerous typo fixes in documentation thanks to Brett Zamir
264 . Unit test refactoring for one logical test per test function
265 . Config and context parameters in ComplexHarness deprecated: instead, edit
266   the $config and $context member variables
267 . HTML wrapper in DOMLex now takes DTD identifiers into account; doesn't
268   really make a difference, but is good for completeness sake
269 . merge-library.php script refactored for greater code reusability and
270   PHP4 compatibility
272 2.1.1, released 2007-08-04
273 - Fix show-stopper bug in %URI.MakeAbsolute functionality
274 - Fix PHP4 syntax error in standalone version
275 . Add prefix directory to include path for standalone, this prevents
276   other installations from clobbering the standalone's URI schemes
277 . Single test methods can be invoked by prefixing with __only
279 2.1.0, released 2007-08-02
280 # flush-htmldefinition-cache.php superseded in favor of a generic
281   flush-definition-cache.php script, you can clear a specific cache
282   by passing its name as a parameter to the script
283 ! Phorum mod implemented for HTML Purifier
284 ! With %Core.AggressivelyFixLt, <3 and similar emoticons no longer
285   trigger HTML removal in PHP5 (DOMLex). This directive is not necessary
286   for PHP4 (DirectLex).
287 ! Standalone file now available, which greatly reduces the amount of
288   includes (although there are still a few files that reside in the
289   standalone folder)
290 ! Relative URIs can now be transformed into their absolute equivalents
291   using %URI.Base and %URI.MakeAbsolute
292 ! Ruby implemented for XHTML 1.1
293 ! You can now define custom URI filtering behavior, see enduser-uri-filter.html
294   for more details
295 ! UTF-8 font names now supported in CSS
296 - AutoFormatters emit friendly error messages if tags or attributes they
297   need are not allowed
298 - ConfigForm's compactification of directive names is now configurable
299 - AutoParagraph autoformatter algorithm refined after field-testing
300 - XHTML 1.1 now applies XHTML 1.0 Strict cleanup routines, namely
301   blockquote wrapping
302 - Contents of <style> tags removed by default when tags are removed
303 . HTMLPurifier_Config->getSerial() implemented, this is extremely useful
304   for output cache invalidation
305 . ConfigForm printer now can retrieve CSS and JS files as strings, in
306   case HTML Purifier's directory is not publically accessible
307 . Introduce new text/itext configuration directive values: these represent
308   longer strings that would be more appropriately edited with a textarea
309 . Allow newlines to act as separators for lists, hashes, lookups and
310   %HTML.Allowed
311 . ConfigForm generates textareas instead of text inputs for lists, hashes,
312   lookups, text and itext fields
313 . Hidden element content removal genericized: %Core.HiddenElements can
314   be used to customize this behavior, by default <script> and <style> are
315   hidden
316 . Added HTMLPURIFIER_PREFIX constant, should be used instead of dirname(__FILE__)
317 . Custom ChildDef added to default include list
318 . URIScheme reflection improved: will not attempt to include file if class
319   already exists. May clobber autoload, so I need to keep an eye on it
320 . ConfigSchema heavily optimized, will only collect information and validate
321   definitions when HTMLPURIFIER_SCHEMA_STRICT is true.
322 . AttrDef_URI unit tests and implementation refactored
323 . benchmarks/ directory now protected from public view with .htaccess file;
324   run the tests via command line
325 . URI scheme is munged off if there is no authority and the scheme is the
326   default one
327 . All unit tests inherit from HTMLPurifier_Harness, not UnitTestCase
328 . Interface for URIScheme changed
329 . Generic URI object to hold components of URI added, most systems involved
330   in URI validation have been migrated to use it
331 . Custom filtering for URIs factored out to URIDefinition interface for
332   maximum extensibility
334 2.0.1, released 2007-06-27
335 ! Tag auto-closing now based on a ChildDef heuristic rather than a
336   manually set auto_close array; some behavior may change
337 ! Experimental AutoFormat functionality added: auto-paragraph and
338   linkify your HTML input by setting %AutoFormat.AutoParagraph and
339   %AutoFormat.Linkify to true
340 ! Newlines normalized internally, and then converted back to the
341   value of PHP_EOL. If this is not desired, set your newline format
342   using %Output.Newline.
343 ! Beta error collection, messages are implemented for the most generic
344   cases involving Lexing or Strategies
345 - Clean up special case code for <script> tags
346 - Reorder includes for DefinitionCache decorators, fixes a possible
347   missing class error
348 - Fixed bug where manually modified definitions were not saved via cache
349   (mostly harmless, except for the fact that it would be a little slower)
350 - Configuration objects with different serials do not clobber each
351   others when revision numbers are unequal
352 - Improve Serializer DefinitionCache directory permissions checks
353 - DefinitionCache no longer throws errors when it encounters old
354   serial files that do not conform to the current style
355 - Stray xmlns attributes removed from configuration documentation
356 - configForm.php smoketest no longer has XSS vulnerability due to
357   unescaped print_r output
358 - Printer adheres to configuration's directives on output format
359 - Fix improperly named form field in ConfigForm printer
360 . Rewire some test-cases to swallow errors rather than expect them
361 . HTMLDefinition printer updated with some of the new attributes
362 . DefinitionCache keys reordered to reflect precedence: version number,
363   hash, then revision number
364 . %Core.DefinitionCache renamed to %Cache.DefinitionImpl
365 . Interlinking in configuration documentation added using
366   Injector_PurifierLinkify
367 . Directives now keep track of aliases to themselves
368 . Error collector now requires a severity to be passed, use PHP's internal
369   error constants for this
370 . HTMLPurifier_Config::getAllowedDirectivesForForm implemented, allows
371   much easier selective embedding of configuration values
372 . Doctype objects now accept public and system DTD identifiers
373 . %HTML.Doctype is now constrained by specific values, to specify a custom
374   doctype use new %HTML.CustomDoctype
375 . ConfigForm truncates long directives to keep the form small, and does
376   not re-output namespaces
378 2.0.0, released 2007-06-20
379 # Completely refactored HTMLModuleManager, decentralizing safety
380   information
381 # Transform modules changed to Tidy modules, which offer more flexibility
382   and better modularization
383 # Configuration object now finalizes itself when a read operation is
384   performed on it, ensuring that its internal state stays consistent.
385   To revert this behavior, you can set the $autoFinalize member variable 
386   off, but it's not recommended.
387 # New compact syntax for AttrDef objects that can be used to instantiate
388   new objects via make()
389 # Definitions (esp. HTMLDefinition) are now cached for a significant
390   performance boost. You can disable caching by setting %Core.DefinitionCache
391   to null. You CANNOT edit raw definitions without setting the corresponding
392   DefinitionID directive (%HTML.DefinitionID for HTMLDefinition).
393 # Contents between <script> tags are now completely removed if <script>
394   is not allowed
395 # Prototype-declarations for Lexer removed in favor of configuration
396   determination of Lexer implementations.
397 ! HTML Purifier now works in PHP 4.3.2.
398 ! Configuration form-editing API makes tweaking HTMLPurifier_Config a
399   breeze!
400 ! Configuration directives that accept hashes now allow new string
401   format: key1:value1,key2:value2
402 ! ConfigDoc now factored into OOP design
403 ! All deprecated elements now natively supported
404 ! Implement TinyMCE styled whitelist specification format in
405   %HTML.Allowed
406 ! Config object gives more friendly error messages when things go wrong
407 ! Advanced API implemented: easy functions for creating elements (addElement)
408   and attributes (addAttribute) on HTMLDefinition
409 ! Add native support for required attributes
410 - Deprecated and removed EnableRedundantUTF8Cleaning. It didn't even work!
411 - DOMLex will not emit errors when a custom error handler that does not
412   honor error_reporting is used
413 - StrictBlockquote child definition refrains from wrapping whitespace
414   in tags now.
415 - Bug resulting from tag transforms to non-allowed elements fixed
416 - ChildDef_Custom's regex generation has been improved, removing several
417   false positives
418 . Unit test for ElementDef created, ElementDef behavior modified to
419   be more flexible
420 . Added convenience functions for HTMLModule constructors
421 . AttrTypes now has accessor functions that should be used instead
422   of directly manipulating info
423 . TagTransform_Center deprecated in favor of generic TagTransform_Simple
424 . Add extra protection in AttrDef_URI against phantom Schemes
425 . Doctype object added to HTMLDefinition which describes certain aspects
426   of the operational document type
427 . Lexer is now pre-emptively included, with a conditional include for the
428   PHP5 only version.
429 . HTMLDefinition and CSSDefinition have a common parent class: Definition.
430 . DirectLex can now track line-numbers
431 . Preliminary error collector is in place, although no code actually reports
432   errors yet
433 . Factor out most of ValidateAttributes to new AttrValidator class
435 1.6.1, released 2007-05-05
436 ! Support for more deprecated attributes via transformations:
437   + hspace and vspace in img
438   + size and noshade in hr
439   + nowrap in td
440   + clear in br
441   + align in caption, table, img and hr
442   + type in ul, ol and li
443 ! DirectLex now preserves text in which a < bracket is followed by
444   a non-alphanumeric character. This means that certain emoticons
445   are now preserved.
446 ! %Core.RemoveInvalidImg is now operational, when set to false invalid
447   images will hang around with an empty src
448 ! target attribute in a tag supported, use %Attr.AllowedFrameTargets
449   to enable
450 ! CSS property white-space now allows nowrap (supported in all modern
451   browsers) but not others (which have spotty browser implementations)
452 ! XHTML 1.1 mode now sort-of works without any fatal errors, and
453   lang is now moved over to xml:lang.
454 ! Attribute transformation smoketest available at smoketests/attrTransform.php
455 ! Transformation of font's size attribute now handles super-large numbers
456 - Possibly fatal bug with __autoload() fixed in module manager
457 - Invert HTMLModuleManager->addModule() processing order to check
458   prefixes first and then the literal module
459 - Empty strings get converted to empty arrays instead of arrays with
460   an empty string in them.
461 - Merging in attribute lists now works.
462 . Demo script removed: it has been added to the website's repository
463 . Basic.php script modified to work out of the box
464 . Refactor AttrTransform classes to reduce duplication
465 . AttrTransform_TextAlign axed in favor of a more general
466   AttrTransform_EnumToCSS, refer to HTMLModule/TransformToStrict.php to
467   see how the new equivalent is implemented
468 . Unit tests now use exclusively assertIdentical
470 1.6.0, released 2007-04-01
471 ! Support for most common deprecated attributes via transformations:
472   + bgcolor in td, th, tr and table
473   + border in img
474   + name in a and img
475   + width in td, th and hr
476   + height in td, th
477 ! Support for CSS attribute 'height' added
478 ! Support for rel and rev attributes in a tags added, use %Attr.AllowedRel
479   and %Attr.AllowedRev to activate
480 - You can define ID blacklists using regular expressions via
481   %Attr.IDBlacklistRegexp
482 - Error messages are emitted when you attempt to "allow" elements or
483   attributes that HTML Purifier does not support
484 - Fix segfault in unit test. The problem is not very reproduceable and
485   I don't know what causes it, but a six line patch fixed it.
487 1.5.0, released 2007-03-23
488 ! Added a rudimentary I18N and L10N system modeled off MediaWiki. It
489   doesn't actually do anything yet, but keep your eyes peeled.
490 ! docs/enduser-utf8.html explains how to use UTF-8 and HTML Purifier
491 ! Newly structured HTMLDefinition modeled off of XHTML 1.1 modules.
492   I am loathe to release beta quality APIs, but this is exactly that;
493   don't use the internal interfaces if you're not willing to do migration
494   later on.
495 - Allow 'x' subtag in language codes
496 - Fixed buggy chameleon-support for ins and del
497 . Added support for IDREF attributes (i.e. for)
498 . Renamed HTMLPurifier_AttrDef_Class to HTMLPurifier_AttrDef_Nmtokens
499 . Removed context variable ParentType, replaced with IsInline, which
500   is false when you're not inline and an integer of the parent that
501   caused you to become inline when you are (so possibly zero)
502 . Removed ElementDef->type in favor of ElementDef->descendants_are_inline
503   and HTMLDefinition->content_sets
504 . StrictBlockquote now reports what elements its supposed to allow,
505   rather than what it does allow
506 . Removed HTMLDefinition->info_flow_elements in favor of
507   HTMLDefinition->content_sets['Flow']
508 . Removed redundant "exclusionary" definitions from DTD roster
509 . StrictBlockquote now requires a construction parameter as if it
510   were an Required ChildDef, this is the "real" set of allowed elements
511 . AttrDef partitioned into HTML, CSS and URI segments
512 . Modify Youtube filter regexp to be multiline
513 . Require both PHP5 and DOM extension in order to use DOMLex, fixes
514   some edge cases where a DOMDocument class exists in a PHP4 environment
515   due to DOM XML extension.
517 1.4.1, released 2007-01-21
518 ! docs/enduser-youtube.html updated according to new functionality
519 - YouTube IDs can have underscores and dashes
521 1.4.0, released 2007-01-21
522 ! Implemented list-style-image, URIs now allowed in list-style
523 ! Implemented background-image, background-repeat, background-attachment
524   and background-position CSS properties. Shorthand property background
525   supports all of these properties.
526 ! Configuration documentation looks nicer
527 ! Added %Core.EscapeNonASCIICharacters to workaround loss of Unicode
528   characters while %Core.Encoding is set to a non-UTF-8 encoding.
529 ! Support for configuration directive aliases added
530 ! Config object can now be instantiated from ini files
531 ! YouTube preservation code added to the core, with two lines of code
532   you can add it as a filter to your code. See smoketests/preserveYouTube.php
533   for sample code.
534 ! Moved SLOW to docs/enduser-slow.html and added code examples
535 - Replaced version check with functionality check for DOM (thanks Stephen
536   Khoo)
537 . Added smoketest 'all.php', which loads all other smoketests via frames
538 . Implemented AttrDef_CSSURI for url(http://google.com) style declarations
539 . Added convenient single test selector form on test runner
541 1.3.2, released 2006-12-25
542 ! HTMLPurifier object now accepts configuration arrays, no need to manually
543   instantiate a configuration object
544 ! Context object now accessible to outside
545 ! Added enduser-youtube.html, explains how to embed YouTube videos. See
546   also corresponding smoketest preserveYouTube.php.
547 ! Added purifyArray(), which takes a list of HTML and purifies it all
548 ! Added static member variable $version to HTML Purifier with PHP-compatible
549   version number string.
550 - Fixed fatal error thrown by upper-cased language attributes
551 - printDefinition.php: added labels, added better clarification
552 . HTMLPurifier_Config::create() added, takes mixed variable and converts into
553   a HTMLPurifier_Config object.
555 1.3.1, released 2006-12-06
556 ! Added HTMLPurifier.func.php stub for a convenient function to call the library
557 - Fixed bug in RemoveInvalidImg code that caused all images to be dropped
558   (thanks to .mario for reporting this)
559 . Standardized all attribute handling variables to attr, made it plural
561 1.3.0, released 2006-11-26
562 # Invalid images are now removed, rather than replaced with a dud
563   <img src="" alt="Invalid image" />. Previous behavior can be restored
564   with new directive %Core.RemoveInvalidImg set to false.
565 ! (X)HTML Strict now supported
566   + Transparently handles inline elements in block context (blockquote)
567 ! Added GET method to demo for easier validation, added 50kb max input size
568 ! New directive %HTML.BlockWrapper, for block-ifying inline elements
569 ! New directive %HTML.Parent, allows you to only allow inline content
570 ! New directives %HTML.AllowedElements and %HTML.AllowedAttributes to let
571   users narrow the set of allowed tags
572 ! <li value="4"> and <ul start="2"> now allowed in loose mode
573 ! New directives %URI.DisableExternalResources and %URI.DisableResources
574 ! New directive %Attr.DisableURI, which eliminates all hyperlinking
575 ! New directive %URI.Munge, munges URI so you can use some sort of redirector
576   service to avoid PageRank leaks or warn users that they are exiting your site.
577 ! Added spiffy new smoketest printDefinition.php, which lets you twiddle with
578   the configuration settings and see how the internal rules are affected.
579 ! New directive %URI.HostBlacklist for blocking links to bad hosts.
580   xssAttacks.php smoketest updated accordingly.
581 - Added missing type to ChildDef_Chameleon
582 - Remove Tidy option from demo if there is not Tidy available
583 . ChildDef_Required guards against empty tags
584 . Lookup table HTMLDefinition->info_flow_elements added
585 . Added peace-of-mind variable initialization to Strategy_FixNesting
586 . Added HTMLPurifier->info_parent_def, parent child processing made special
587 . Added internal documents briefly summarizing future progression of HTML
588 . HTMLPurifier_Config->getBatch($namespace) added
589 . More lenient casting to bool from string in HTMLPurifier_ConfigSchema
590 . Refactored ChildDef classes into their own files
592 1.2.0, released 2006-11-19
593 # ID attributes now disabled by default. New directives:
594   + %HTML.EnableAttrID - restores old behavior by allowing IDs
595   + %Attr.IDPrefix - %Attr.IDBlacklist alternative that munges all user IDs
596     so that they don't collide with your IDs
597   + %Attr.IDPrefixLocal - Same as above, but for when there are multiple
598     instances of user content on the page
599   + Profuse documentation on how to use these available in docs/enduser-id.txt
600 ! Added MODx plugin <http://modxcms.com/forums/index.php/topic,6604.0.html>
601 ! Added percent encoding normalization
602 ! XSS attacks smoketest given facelift
603 ! Configuration documentation now has table of contents
604 ! Added %URI.DisableExternal, which prevents links to external websites.  You
605   can also use %URI.Host to permit absolute linking to subdomains
606 ! Non-accessible resources (ex. mailto) blocked from embedded URIs (img src)
607 - Type variable in HTMLDefinition was not being set properly, fixed
608 - Documentation updated
609   + TODO added request Phalanger
610   + TODO added request Native compression
611   + TODO added request Remove redundant tags
612   + TODO added possible plaintext formatter for HTML Purifier documentation
613   + Updated ConfigDoc TODO
614   + Improved inline comments in AttrDef/Class.php, AttrDef/CSS.php
615     and AttrDef/Host.php
616   + Revamped documentation into HTML, along with misc updates
617 - HTMLPurifier_Context doesn't throw a variable reference error if you attempt
618   to retrieve a non-existent variable
619 . Switched to purify()-wide Context object registry
620 . Refactored unit tests to minimize duplication
621 . XSS attack sheet updated
622 . configdoc.xml now has xml:space attached to default value nodes
623 . Allow configuration directives to permit null values
624 . Cleaned up test-cases to remove unnecessary swallowErrors()
626 1.1.2, released 2006-09-30
627 ! Add HTMLPurifier.auto.php stub file that configures include_path
628 - Documentation updated
629   + INSTALL document rewritten
630   + TODO added semi-lossy conversion
631   + API Doxygen docs' file exclusions updated
632   + Added notes on HTML versus XML attribute whitespace handling
633   + Noted that HTMLPurifier_ChildDef_Custom isn't being used
634   + Noted that config object's definitions are cached versions
635 - Fixed lack of attribute parsing in HTMLPurifier_Lexer_PEARSax3
636 - ftp:// URIs now have their typecodes checked
637 - Hooked up HTMLPurifier_ChildDef_Custom's unit tests (they weren't being run)
638 . Line endings standardized throughout project (svn:eol-style standardized)
639 . Refactored parseData() to general Lexer class
640 . Tester named "HTML Purifier" not "HTMLPurifier"
642 1.1.1, released 2006-09-24
643 ! Configuration option to optionally Tidy up output for indentation to make up
644   for dropped whitespace by DOMLex (pretty-printing for the entire application
645   should be done by a page-wide Tidy)
646 - Various documentation updates
647 - Fixed parse error in configuration documentation script
648 - Fixed fatal error in benchmark scripts, slightly augmented
649 - As far as possible, whitespace is preserved in-between table children
650 - Sample test-settings.php file included
652 1.1.0, released 2006-09-16
653 ! Directive documentation generation using XSLT
654 ! XHTML can now be turned off, output becomes <br>
655 - Made URI validator more forgiving: will ignore leading and trailing
656   quotes, apostrophes and less than or greater than signs.
657 - Enforce alphanumeric namespace and directive names for configuration.
658 - Table child definition made more flexible, will fix up poorly ordered elements
659 . Renamed ConfigDef to ConfigSchema
661 1.0.1, released 2006-09-04
662 - Fixed slight bug in DOMLex attribute parsing
663 - Fixed rejection of case-insensitive configuration values when there is a
664   set of allowed values.  This manifested in %Core.Encoding.
665 - Fixed rejection of inline style declarations that had lots of extra
666   space in them.  This manifested in TinyMCE.
668 1.0.0, released 2006-09-01
669 ! Shorthand CSS properties implemented: font, border, background, list-style
670 ! Basic color keywords translated into hexadecimal values
671 ! Table CSS properties implemented
672 ! Support for charsets other than UTF-8 (defined by iconv)
673 ! Malformed UTF-8 and non-SGML character detection and cleaning implemented
674 - Fixed broken numeric entity conversion
675 - API documentation completed
676 . (HTML|CSS)Definition de-singleton-ized
678 1.0.0beta, released 2006-08-16
679 ! First public release, most functionality implemented. Notable omissions are:
680   + Shorthand CSS properties
681   + Table CSS properties
682   + Deprecated attribute transformations