Login mechanism works for guest and user.