1
我正在使用Struts 1和JSP开发应用程序。我必须写XSS保护。我投入像这样的:Bean:写入过滤器不起作用
<input id="name" name="name" class="someClass" type="text"
value="<bean:write name="personForm" property="name"/>">
,我读了保护XSS攻击我一定要在绿豆加属性过滤器:编写和过滤器应该是真实的。所以我现在的代码看起来像是
<input id="name" name="name" class="someClass" type="text"
value="<bean:write name="personForm" property="name" filter="true"/>">
但是我仍然可以提交脚本。你知道为什么会发生这种情况吗?