modify the comparsion to find authentication type