Package org.apache.myfaces.util
Class IllegalXmlCharacterFilterWriter
- java.lang.Object
-
- java.io.Writer
-
- java.io.FilterWriter
-
- org.apache.myfaces.util.IllegalXmlCharacterFilterWriter
-
- All Implemented Interfaces:
Closeable
,Flushable
,Appendable
,AutoCloseable
public class IllegalXmlCharacterFilterWriter extends FilterWriter
There are unicodes outside the ranges defined in the XML 1.0 specification that break XML parsers and therefore must be filtered out when writing partial responses. Otherwise this may lead to Denial of Service attacks.
-
-
Field Summary
-
Fields inherited from class java.io.FilterWriter
out
-
-
Constructor Summary
Constructors Constructor Description IllegalXmlCharacterFilterWriter(Writer out)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
write(char[] cbuf, int off, int len)
void
write(int c)
void
write(String str, int off, int len)
-
Methods inherited from class java.io.FilterWriter
close, flush
-
-
-
-
Constructor Detail
-
IllegalXmlCharacterFilterWriter
public IllegalXmlCharacterFilterWriter(Writer out)
-
-
Method Detail
-
write
public void write(int c) throws IOException
- Overrides:
write
in classFilterWriter
- Throws:
IOException
-
write
public void write(char[] cbuf, int off, int len) throws IOException
- Overrides:
write
in classFilterWriter
- Throws:
IOException
-
write
public void write(String str, int off, int len) throws IOException
- Overrides:
write
in classFilterWriter
- Throws:
IOException
-
-