changed authenticate api

Signed-off-by: abbr <wenfred@gmail.com>