In WSO2 APIM, We can use regular expression filtering to prevent xss and sql,xml,html injections.
I found that we cannot use "</" and "/>" and even "<"semicolon"/" and "/>"semicolon"".
<property name="regex" expression="get-property('regex')" value=".*'.*|.*ALTER.*|.*ALTER TABLE.*|.*ALTER VIEW.*|
.*CREATE DATABASE.*|.*CREATE PROCEDURE.*|.*CREATE SCHEMA.*|.*create table.*|.*CREATE VIEW.*|.*DELETE.*|.
*DROP DATABASE.*|.*DROP PROCEDURE.*|.*DROP.*|.*SELECT.*|.*/>.*|.*</.*|.*/>.*|.*</.*|.*Exception in thread.*|.*#include.*|.*#exec.*|.*#echo.*|.*#config.*|/?(ancestor(-or-self)?|descendant(-or-self)?|following(-sibling))"/>
Probably, the reason is that, All body is casted to xml envelope. I put the link of code in the end.
Do you have any idea to prevent html, script, xml, sql injection in WSO2 apim?
The code of regex filtering is here.