Added automatic downloading of the certificate