Refactor authentication implementation