improved login implementation
ongoing