Skip to content

Commit f6fcc95

Browse files
update repo for Ibouk
1 parent 3c26b42 commit f6fcc95

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

config/eval.conf

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ server {
1414
}
1515

1616
location /upload {
17-
allow_methods POST;
17+
allow_methods POST DELETE;
1818
allow_uploads on;
1919
}
2020

@@ -34,5 +34,6 @@ server {
3434
location /cgi-bin/ {
3535
allow_methods GET POST;
3636
cgi_handler .bla /bin/sh;
37+
allow_uploads on;
3738
}
3839
}

src/router/router.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,13 +68,15 @@ const RouteConfig& Router::find_best_route(const std::string& request_path) cons
6868
// This seems to be valid in some cases but we ignore it right now.
6969
static bool is_cgi_request(const HttpRequest& request, const RouteConfig& route)
7070
{
71+
LOG(DEBUG) << "shared.ext" << route.shared.cgi.extension;
7172
if (route.shared.cgi.extension.empty())
7273
return false;
7374

7475
size_t dot = request.path.find_last_of(".");
7576
if (dot == std::string::npos)
7677
return false;
77-
78+
std::string ext = request.path.substr(dot);
79+
LOG(DEBUG) << "ext = " << ext;
7880
return request.path.substr(dot) == route.shared.cgi.extension;
7981
}
8082

0 commit comments

Comments
 (0)