mirror of
https://github.com/gohugoio/hugo.git
synced 2025-08-20 21:31:32 +02:00
Block symlink dir traversal for /static
This is in line with how it behaved before, but it was lifted a little for the project mount for Hugo Modules, but that could create hard-to-detect loops.
This commit is contained in:
@@ -52,7 +52,7 @@ func TestPagesCapture(t *testing.T) {
|
||||
writeFile("pages/page2.md")
|
||||
writeFile("pages/page.png")
|
||||
|
||||
ps, err := helpers.NewPathSpec(hugofs.NewFrom(fs, cfg), cfg)
|
||||
ps, err := helpers.NewPathSpec(hugofs.NewFrom(fs, cfg), cfg, loggers.NewErrorLogger())
|
||||
assert.NoError(err)
|
||||
sourceSpec := source.NewSourceSpec(ps, fs)
|
||||
|
||||
|
Reference in New Issue
Block a user