Skip to content

Commit e753259

Browse files
authored
fix: Create credentials in folder (#1019)
1 parent 375944c commit e753259

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/com/cloudbees/plugins/credentials/CredentialsStoreAction.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -586,7 +586,7 @@ public String getRelativePath() {
586586
}
587587
// Validate the relative path as a security hardening
588588
// There is no known attack vector here, but just in case as it does control what the form action is.
589-
if (!relativePath.startsWith("/")) {
589+
if (!(relativePath.startsWith("/") || relativePath.startsWith("../"))) {
590590
return null;
591591
}
592592
// Prevent protocol-relative URLs

0 commit comments

Comments
 (0)