Basic auth and templates