mirror of
https://github.com/gogs/gogs.git
synced 2025-12-22 00:00:07 +01:00
http: clean request path from Git endpoints (#7022)
This commit is contained in:
@@ -27,6 +27,10 @@ func TestClean(t *testing.T) {
|
||||
path: "/../a/b/../c/../readme.txt",
|
||||
wantVal: "a/readme.txt",
|
||||
},
|
||||
{
|
||||
path: "../../objects/info/..",
|
||||
wantVal: "objects",
|
||||
},
|
||||
{
|
||||
path: "/a/readme.txt",
|
||||
wantVal: "a/readme.txt",
|
||||
|
||||
Reference in New Issue
Block a user