changed authentication pattern