fix: refine CGI path validation to exclude relative paths
This commit is contained in:
parent
77e09f43ed
commit
82c421f458
@ -181,7 +181,7 @@ std::string AConfig::getCGIPath(const std::string &extension) const
|
||||
}
|
||||
auto exts = directive->getValue().try_get<std::vector<std::string>>().value();
|
||||
auto cgiPath = exts.back();
|
||||
if (cgiPath.starts_with("."))
|
||||
if (cgiPath.starts_with(".") && !cgiPath.starts_with("./"))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user