login and uri fixes