added basic authentication to controllers and views