mirror of
https://github.com/spring-projects/spring-framework.git
synced 2026-09-24 15:49:26 +00:00
Do not support relative static resource paths
Closes gh-33687
This commit is contained in:
+1
@@ -643,6 +643,7 @@ class ResourceHttpRequestHandlerTests {
|
||||
testInvalidPath("../testsecret/secret.txt");
|
||||
testInvalidPath("test/../../testsecret/secret.txt");
|
||||
testInvalidPath(":/../../testsecret/secret.txt");
|
||||
testInvalidPath("/testsecret/test/../secret.txt");
|
||||
|
||||
Resource location = new UrlResource(ResourceHttpRequestHandlerTests.class.getResource("./test/"));
|
||||
this.handler.setLocations(List.of(location));
|
||||
|
||||
Reference in New Issue
Block a user