fix authentication mechanism