Hi,
i tried to add httpAuth to a website to have a version online which can be reviewed by a client.
However it behaves rather odd,by requiring multiple reloads on local dev to kick in, while it does not work at all in deployment mode.
This is the code:
LiftRules.httpAuthProtectedResource.prepend{
case _ => Full(AuthRole("admin"))
}
LiftRules.authentication = HttpBasicAuthentication("Authenticate Yourself") {
case("admin","whatever",req) => {
logger.info("Authentication Succeeded...Welcome!!")
userRoles(AuthRole("admin"))
true
}
}
The app is deployed on red hat cloud on jetty no idea why it does not work.
It would be nice, to have this behave the other way around ;)