add user validate and user can login logout