The params are not filled out during the before method. You can override the invoke method.
class NoFooBarRouter extends ScalatraServlet{
override def invoke(matchedRoute: MatchedRoute): Option[Any] = {
withRouteMultiParams(Some(matchedRoute)){
val foo = params.getOrElse("foo", "")
if(foo =="bar")
halt(403, "You are not authorized for the requested client.")
else
NoFooBarRouter.super.invoke(matchedRoute)
}
}
}