fix(02): resolve symlinks before fixture and vars path checks (WR-07)

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Jakub Zych
2026-09-17 14:44:23 +02:00
parent 0ac9dc45d0
commit f7b81b9dd7
4 changed files with 57 additions and 3 deletions

View File

@@ -192,6 +192,9 @@ func validateFixturePath(p string) error {
if clean == ".." || strings.HasPrefix(clean, "../") {
return fmt.Errorf("fixture %q escapes the fixture directory", p)
}
if _, err := resolvePath(p); err != nil {
return fmt.Errorf("fixture %q: %w", p, err)
}
return nil
}