Reasoning:
In quite a few scenarios we need to support multiple authentication strategies, for example anonymous logins from mobile devices and bearer tokens if users had decided to log in. Right now it seems that the way to implement this is to create multiple strategies and set the auth.strategies property in each route. This gets a bit messy, especially when hapi servers are composed from smaller, individual modules. Having multiple default strategies allows us to determine access levels through scope and roles at the plugin level, but keep the auth code outside in the server where it belongs.
Does this cover what you're trying to do: http://hapijs.com/api#serverauthdefaultoptions?
So you would use it like:
server.auth.default({
strategies: ['strategy1', 'strategy2', 'strategy3']
})
Nice, I missed that. I think that should cover it.
Most helpful comment
Does this cover what you're trying to do: http://hapijs.com/api#serverauthdefaultoptions?
So you would use it like: