Further authentication fixes