3 ms·
> Put another way: exceptions are exceptions to the normal program flow. There's no iron law or mathematical proof that says this is optimal. It's just a prefe
by asdfasgasdgasdg 7y ago
> Put another way: exceptions are exceptions to the normal program flow.
There's no iron law or mathematical proof that says this is optimal. It's just a preference some people have. Exceptions are the error handling mechanism for many programming languages. Authorization errors are a type of error. Under this construction, exceptions are the appropriate way to handle authorization errors, including when a principal attempts to access an resource they are not authorized to access.