Fix XSS in auth failure

Problem and fix as identified by @samjsharpe