Returning an HTTP 403 from %CSP.SessionEvents:OnStartRequest
Is there a way, given a %CSP.SessionEvents subclass, to simply return an HTTP 403 error status from OnStartRequest?
If I return an error %Status from the method, it'll go to the error page; if I don't, it's always a 200 OK and the page continues to render.
Product version: IRIS 2021.2
$ZV: IRIS for Windows (x86-64) 2021.2 (Build 651U) Mon Jan 31 2022 17:39:04 EST
Try this:
Or this:
Here's the problem:
The solution might be using a custom error page too.
Simple solution:
Create a class extending %CSP.Page with:
From the %CSP.SessionEvents subclass, in OnStartRequest: