gitweb: Require project for almost all actions
[gitweb.git] / gitweb / gitweb.perl
index 5f597f71e05376268d55742f288888d30b93c240..7fd2e19446a27d89dd970c9ccc5dc68ea95f646e 100755 (executable)
@@ -352,6 +352,10 @@ sub evaluate_path_info {
 if (!defined($actions{$action})) {
        die_error(undef, "Unknown action");
 }
+if ($action !~ m/^(opml|project_list|project_index)$/ &&
+    !$project) {
+       die_error(undef, "Project needed");
+}
 $actions{$action}->();
 exit;