added a lot functionality for authorization