File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed
java/com/thoughtworks/xstream/io/xml
test/com/thoughtworks/xstream/io/xml Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -67,7 +67,9 @@ public BEAStaxDriver(final NameCoder nameCoder) {
67
67
@ Override
68
68
protected XMLInputFactory createInputFactory () {
69
69
final XMLInputFactory instance = new MXParserFactory ();
70
- // instance.setProperty(XMLInputFactory.IS_SUPPORTING_EXTERNAL_ENTITIES, true);
70
+ instance .setProperty (XMLInputFactory .IS_SUPPORTING_EXTERNAL_ENTITIES , false );
71
+ // if (instance.isPropertySupported(XMLInputFactory.IS_SUPPORTING_EXTERNAL_ENTITIES))
72
+ // throw new IllegalStateException("Should not support extgernal entities now!");
71
73
return instance ;
72
74
}
73
75
Original file line number Diff line number Diff line change @@ -28,8 +28,7 @@ protected HierarchicalStreamReader createReader(final String xml) throws Excepti
28
28
29
29
@ Override
30
30
public void testIsXXEVulnerable () throws Exception {
31
- // Implementation wrongly claims not to handle external entities.
32
- // On top it ignores XMLInputFactory.IS_SUPPORTING_EXTERNAL_ENTITIES !!
31
+ // Implementation ignores XMLInputFactory.IS_SUPPORTING_EXTERNAL_ENTITIES set to false.
33
32
// super.testIsXXEVulnerable();
34
33
}
35
34
You can’t perform that action at this time.
0 commit comments