File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed
Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change 1414If ($URL= $redirectURI)
1515
1616 var $options : Object:= {redirectURI: $redirectURI ; state: $state }
17-
17+
1818 ARRAY TEXT ($names ; 0 )
1919 ARRAY TEXT ($values ; 0 )
2020 WEB GET VARIABLES ($names ; $values )
@@ -37,6 +37,15 @@ If ($URL=$redirectURI)
3737 var $contentType : Text:= "Content-Type: text/html"
3838 WEB SET HTTP HEADER ($contentType )
3939 WEB SEND RAW DATA ($responseBody )
40+ Else
41+
42+ // Send a 403 status line
43+ // This is not strictly necessary, but it makes it clear that the request was forbidden
44+ // and not just a 404 Not Found
45+ var $statusLine : Text:= "X-STATUS: 403 Forbidden"
46+ WEB SET HTTP HEADER ($statusLine )
47+ var $errorBody : Text:= "<html><body><h1>403 Forbidden</h1><p>Access denied</p></body></html>"
48+ WEB SEND TEXT ($errorBody ; "text/html" )
4049 End if
4150
4251End if
You can’t perform that action at this time.
0 commit comments