Start refactoring auth