Bug #3977

TextValidator is insecure

Added by Robert Lemke over 12 years ago. Updated over 9 years ago.

Should have
Target version:
Start date:
Due date:
% Done:


Estimated time:
6.00 h
PHP Version:
Has patch:


The TextValidator currently allows strings like

%3cspan style="color: #BBBBBB;"%3ea nice text%3c/span%3e

It seems like we can't solve this completely with filter_var because then characters like percent, semikolon, quotes etc. can't be used in a text. In general the test case lacks realistic string which should pass the validator.


TextValidatorTest.php.patch (4.8 KB) TextValidatorTest.php.patch Patch for the unit test Karsten Dambekalns, 2010-01-20 12:11

Related issues

Related to TYPO3.Flow - Bug #2851: TextValidator is insecureResolvedAndreas Förthner2009-03-16


Updated by Robert Lemke about 12 years ago

  • Target version deleted (1.0 alpha 3)

Updated by Robert Lemke almost 12 years ago

  • Target version set to 1.0 alpha 8

Updated by Karsten Dambekalns almost 12 years ago

Attached a patch for the unit test that makes adding new valid and invalid input easier.


Updated by Robert Lemke over 11 years ago

  • Status changed from New to Accepted
  • Assignee set to Robert Lemke
  • % Done changed from 0 to 20
  • Estimated time set to 6.00 h

Updated by Robert Lemke over 11 years ago

  • Start date deleted (2009-03-16)

Updated by Karsten Dambekalns over 11 years ago

  • Target version changed from 1.0 alpha 8 to 1.0 alpha 9

Updated by Robert Lemke over 11 years ago

  • Target version deleted (1.0 alpha 9)

Updated by Bastian Waidelich almost 10 years ago

  • Has patch set to No

IMO TextValidator should be removed as it depends on the context whether a string is insecure or not (also see comment at #6121)


Updated by Christian Müller over 9 years ago

  • Status changed from Accepted to Rejected
  • Assignee deleted (Robert Lemke)

The test improvements are in review now, I will close this, we could decide to deprecate the TextValidator at some point. I added also some longer comment to the TextValidator to point out that it won't make sure the validated string is secure in all possible output environments.

Also available in: Atom PDF