Make sure the user is logged in before updating the certificate.