Hi folks,
I have several routes in an REST API which require security, and a handful of other routes in the same API that are open.
I’m wondering if there is an elegant way to override the Security interceptor based on the incoming route.
Currently I’m doing a simple check on the route/event:
if(reFindNocase(“createUser”,event.getCurrentAction()) OR reFindNocase(“index”,event.getCurrentAction())){
//don’t do security
}else{
//do security check
}
This is a slimmed down example and there are many more routes which do not need the security. Is there a more elegant way to do this by using regex or an XML config file?
Thanks.
Nolan