Added some backend for recognising HTTP authorisation failures and prompting the user for credentials. Not yet implemented in the UI