|
@@ -266,17 +266,17 @@ begin
|
|
exit;
|
|
exit;
|
|
end;
|
|
end;
|
|
FN:=MapFileName(RFN);
|
|
FN:=MapFileName(RFN);
|
|
- if (FN='') or not FileExists(FN) then
|
|
|
|
|
|
+ if (FN='') or not AllowFile(FN) then
|
|
begin
|
|
begin
|
|
- AResponse.Code:=404;
|
|
|
|
- AResponse.CodeText:='Not found';
|
|
|
|
|
|
+ AResponse.Code:=403;
|
|
|
|
+ AResponse.CodeText:='Forbidden';
|
|
AResponse.SendContent;
|
|
AResponse.SendContent;
|
|
exit;
|
|
exit;
|
|
end;
|
|
end;
|
|
- if not AllowFile(FN) then
|
|
|
|
|
|
+ if not FileExists(FN) then
|
|
begin
|
|
begin
|
|
- AResponse.Code:=403;
|
|
|
|
- AResponse.CodeText:='Forbidden';
|
|
|
|
|
|
+ AResponse.Code:=404;
|
|
|
|
+ AResponse.CodeText:='Not found';
|
|
AResponse.SendContent;
|
|
AResponse.SendContent;
|
|
exit;
|
|
exit;
|
|
end;
|
|
end;
|