a random picture..computer related
Twe (Twe Whitelist Enforcer)
Language: php4
Twe is used to enforce pre defined html code.
Twe takes (evil) html as input and returns html matched against 
a flexible and easy to extend set of rules.

Example of usage:
Use Twe to allow html input for your webforum without 
opening yourself to cross side scripting attacks.

License: GNU Lesser General Public License, so feel free to copy and distribute as long as 
you dont violate the LGPL.

Documentation is comming soon. For now this QA section.

Q: What is Twe?
A: twe is takes a ruleset and html input and returns cleaned and matched html


Q: Twe?
A: 'Tantaus Whitelist Enforcer' or 'Twe Whitelist Enforcer' if you like recursions


Q: Who wrote Twe?
A: Sven Tantau.. but the cooler guy is Matthias Winkelmann from 'someon GmbH' 
who payed me for coding


Q: How to install?
A: Just copy the classes directory to your prefered location.


Q: And how to use this twe thing?
A: See example.php for an example usage.


Q: Naming?
A:

<span style="text-align: left;">foo</span>
  ^^^^  ^^^^^  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  tag   tag_attribute         tag_attribute_value

font-color is a style_attribute
#434434 is a style_attribute_value


Q: What happens inside:
A: Twe takes the content and a 
 rule_container takes one or more 
  tagsets with some 
   attributes with 
    methods and parameters set

    a special method is 'checksystyle' (for the 'style' attribute in a tag) which takes as argument:
     stylerules with one or more
      style_attributes with
       methodes and  parameters set
										
				
Q: Can I contact you if I want a special extension or a custom ruleset?
A: Yes.


Q: Documentation for the rulesets?
A: No. Not yet.


Q: How to contact you?!
A: Use the project page at http://twe.sven-tantau.de (not online yet) or write 
an email (twe@sven-tantau.de)

Kontakt Support This Project

IT-Dienstleistungen Sven Tantau - Drostestrasse 3 in 53819 Neunkirchen - Tel.: +49 177 7824828 - USt-Id-Nr.: DE203610693