@@ -58,7 +58,7 @@ public void setUp() {
5858
5959 @ Test
6060 public void filterWithExactAllowedPath () throws Exception {
61- System .setProperty ("ControlFilterTests" , "runsAfterControlFilter " );
61+ System .setProperty ("ControlFilterTests" , "bypassPreventsStreamExploitation " );
6262 when (config .getInitParameter ("redirectPath" )).thenReturn ("/foo" );
6363 when (config .getInitParameter ("allowedPaths" )).thenReturn ("/foo:/bar" );
6464 when (req .getRequestURI ()).thenReturn ("/servlet/bar" );
@@ -72,7 +72,7 @@ public void filterWithExactAllowedPath() throws Exception {
7272
7373 @ Test
7474 public void filterWithAllowedSubPath () throws Exception {
75- System .setProperty ("ControlFilterTests" , "runsAfterControlFilter " );
75+ System .setProperty ("ControlFilterTests" , "bypassPreventsStreamExploitation " );
7676 when (config .getInitParameter ("redirectPath" )).thenReturn ("/foo" );
7777 when (config .getInitParameter ("allowedPaths" )).thenReturn ("/foo:/bar" );
7878 when (req .getRequestURI ()).thenReturn ("/servlet/bar/baz" );
@@ -86,7 +86,7 @@ public void filterWithAllowedSubPath() throws Exception {
8686
8787 @ Test
8888 public void filterWithRedirection () throws Exception {
89- System .setProperty ("ControlFilterTests" , "runsAfterControlFilter " );
89+ System .setProperty ("ControlFilterTests" , "bypassPreventsStreamExploitation " );
9090 when (config .getInitParameter ("redirectPath" )).thenReturn ("/foo" );
9191 when (config .getInitParameter ("allowedPaths" )).thenReturn ("/bar:/baz" );
9292 when (req .getRequestURI ()).thenReturn ("/missing/path" );
@@ -99,7 +99,7 @@ public void filterWithRedirection() throws Exception {
9999
100100 @ Test
101101 public void filterWithURIredirection () throws Exception {
102- System .setProperty ("ControlFilterTests" , "runsAfterControlFilter " );
102+ System .setProperty ("ControlFilterTests" , "bypassPreventsStreamExploitation " );
103103 when (config .getInitParameter ("redirectPath" )).thenReturn ("http://example.org/foo" );
104104 when (config .getInitParameter ("allowedPaths" )).thenReturn ("/foo:/bar" );
105105 when (req .getRequestURI ()).thenReturn ("/baz" );
@@ -112,7 +112,7 @@ public void filterWithURIredirection() throws Exception {
112112
113113 @ Test
114114 public void bailsOutWithVariousErrorCodes () throws Exception {
115- System .setProperty ("ControlFilterTests" , "runsAfterControlFilter " );
115+ System .setProperty ("ControlFilterTests" , "bypassPreventsStreamExploitation " );
116116 when (config .getInitParameter ("allowedPaths" )).thenReturn ("/foo" );
117117 when (req .getRequestURI ()).thenReturn ("/baz" );
118118
@@ -143,7 +143,7 @@ public void bailsOutWithVariousErrorCodes() throws Exception {
143143
144144 @ Test
145145 public void redirectAllAllowed () throws Exception {
146- System .setProperty ("ControlFilterTests" , "runsAfterControlFilter " );
146+ System .setProperty ("ControlFilterTests" , "bypassPreventsStreamExploitation " );
147147 when (config .getInitParameter ("redirectPath" )).thenReturn ("/bar" );
148148 when (config .getInitParameter ("forceRedirectAll" )).thenReturn ("Y" );
149149 when (config .getInitParameter ("allowedPaths" )).thenReturn ("/foo" );
@@ -157,7 +157,7 @@ public void redirectAllAllowed() throws Exception {
157157
158158 @ Test
159159 public void redirectAllNotAllowed () throws Exception {
160- System .setProperty ("ControlFilterTests" , "runsAfterControlFilter " );
160+ System .setProperty ("ControlFilterTests" , "bypassPreventsStreamExploitation " );
161161 when (config .getInitParameter ("redirectPath" )).thenReturn ("/bar" );
162162 when (config .getInitParameter ("forceRedirectAll" )).thenReturn ("Y" );
163163 when (config .getInitParameter ("allowedPaths" )).thenReturn ("/foo" );
@@ -171,7 +171,7 @@ public void redirectAllNotAllowed() throws Exception {
171171
172172 @ Test
173173 public void redirectAllRecursive () throws Exception {
174- System .setProperty ("ControlFilterTests" , "runsAfterControlFilter " );
174+ System .setProperty ("ControlFilterTests" , "bypassPreventsStreamExploitation " );
175175 when (config .getInitParameter ("redirectPath" )).thenReturn ("/foo" );
176176 when (config .getInitParameter ("forceRedirectAll" )).thenReturn ("Y" );
177177 when (config .getInitParameter ("allowedPaths" )).thenReturn ("/foo" );
0 commit comments