Upated certificate generation to work for IP addresses.