Resthandler permission exception

Can we have a permission exception coldbox.system.resthandler?

So e.g. if a user can’t access a resource, we would throw a permissionDenied exception which would be treated in the rest handler.

What do you think? If it makes sense we can prepare a pull request

Hi @gunnar.lieb we do have two actions already to address: unauthenticated and unauthorized:

Is this what you are talking about?

Ok, thanks, so onAuthorizationFailure would the right!

Shouldn’t it have an according catch in the resthandler.aroundhandler()?

@lmajano I made a pull request: Update RestHandler.cfc, added catch for onAuthorizationFailure by GunnarLieb · Pull Request #472 · ColdBox/coldbox-platform · GitHub