Authentication functionality added