Complete login functionality from GUI