File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed
Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -21,7 +21,14 @@ Function getResponse($request : 4D.IncomingMessage) : 4D.OutgoingMessage
2121 $response .setHeader ("Content-Type" ; "text/html" )
2222 Else
2323
24- $response .setStatus (404 )
24+ // Send a 403 status line
25+ // This is not strictly necessary, but it makes it clear that the request was forbidden
26+ // and not just a 404 Not Found
27+ $response .setStatus (403 )
28+ var $errorBody : Text:= "<html><body><h1>403 Forbidden</h1><p>Access denied</p></body></html>"
29+ $response .setBody ($errorBody )
30+ $response .setHeader ("Content-Type" ; "text/html" )
31+
2532 End if
2633 Else
2734 var $error : Object:= cs .Tools .me .makeError (9 ; {which: "request (4D.IncomingMessage)" ; function: "OAuth2Authorization.getResponse" })
You can’t perform that action at this time.
0 commit comments