Closed buddhabuddy closed 7 years ago
@buddhabuddy the login page in the sample app gets the token rendered when you fail to enter one of the fields. Could you compare/share your page to see what could be causing the problem?
its true it does. Sorry am on 2.5.x so its a problem somewhere dealing with injection of CSRFAddToken.
When there's an empty field in the login page a badRequest is thrown in UsernamePasswordProvider. The login form has a @CSRF.formField so fails to render without CSRFAddToken at:
Results.BadRequest(viewTemplates.getLoginPage(f, msg))
How would I get a token to the render?