We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 008e5f3 commit 448e25dCopy full SHA for 448e25d
opengrok-indexer/src/main/java/org/opengrok/indexer/web/Laundromat.java
@@ -80,8 +80,8 @@ public static String launderRevision(String value) {
80
* @return {@code null} if null or else {@code value} with path traversal
81
* path components {@code /../} removed.
82
*/
83
- public static String launderPath(String value) {
84
- Path path = Path.of(value);
+ public static String launderPath(@NotNull String value) {
+ Path path = Path.of(Laundromat.launderInput(value));
85
List<String> pathElements = new ArrayList<>();
86
for (int i = 0; i < path.getNameCount(); i++) {
87
if (path.getName(i).toString().equals("..")) {
0 commit comments