<div dir="ltr">Hi Daniel,<div><br></div><div>thanks for the reply - The procedure I use is the same as I use for XenServer, and the certificate exchange works just fine.  The only thing I'm a bit unclear on, is the location of the CA cert, which in the case of XenServer, I simply put it in /etc/pki/CA.  And when I start the libvirtd daemon, it successfully picks it up.  If I put the Server key and cert in /etc/vmware/ssl for ESXi, is there a location where I put the CA cert (cacert.pem)?  Also, following are the log errors that I see -</div>
<div><br></div><div><div>2013-10-30T18:32:25.405Z [FFE81B90 error 'Default'] SSLStreamImpl::DoServerHandshake (ffd005d0) SSL_accept failed. Dumping SSL error queue:</div><div>2013-10-30T18:32:25.405Z [FFE81B90 error 'Default'] [0] error:14094418:SSL routines:SSL3_READ_BYTES:tlsv1 alert unknown ca</div>
<div>2013-10-30T18:32:25.405Z [FFE81B90 warning 'Default'] SSL Handshake failed for stream TCP(local=<ESXi>:443, peer=<client>:33776), error: N7Vmacore3Ssl12SSLExceptionE(SSL Exception: error:14094418:SSL routines:SSL3_READ_BYTES:tlsv1 alert unknown ca)</div>
</div><div><br></div><div><br></div><div>Doesn't this mean the CA cert wasn't found on the ESXi?</div><div><br></div><div>Regards,</div><div>Shiva</div><div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">
On Wed, Oct 30, 2013 at 2:45 AM, Daniel P. Berrange <span dir="ltr"><<a href="mailto:berrange@redhat.com" target="_blank">berrange@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="HOEnZb"><div class="h5">On Tue, Oct 29, 2013 at 06:48:46PM -0700, Shiva Bhanujan wrote:<br>
> Hello,<br>
><br>
> I'm using certtool to generate the server certificates for ESXi -<br>
> <a href="http://libvirt.org/remote.html#Remote_TLS_CA" target="_blank">http://libvirt.org/remote.html#Remote_TLS_CA</a>.  I just copy the server<br>
> certificate and key as /etc/vmware/ssl/rui.crt and /etc/vmware/ssl/rui.key.<br>
>  And then use virsh to connect from a CentOS 6.4 VM running on it - "virsh<br>
> -c esx://<esx IP>.  I get the following error -<br>
><br>
> error: internal error curl_easy_perform() returned an error: Peer<br>
> certificate cannot be authenticated with known CA certificates (60) : Peer<br>
> certificate cannot be authenticated with known CA certificates<br>
> error: failed to connect to the hypervisor<br>
><br>
> is there something basic that I'm missing?<br>
<br>
</div></div>I'm not sure what you're missing, but the error message means that the<br>
VMWare server certificate was not signed by any CA certificate that<br>
the libvirt client has access to. So it is a client side CA cert config<br>
problem most likely.<br>
<span class="HOEnZb"><font color="#888888"><br>
Daniel<br>
--<br>
|: <a href="http://berrange.com" target="_blank">http://berrange.com</a>      -o-    <a href="http://www.flickr.com/photos/dberrange/" target="_blank">http://www.flickr.com/photos/dberrange/</a> :|<br>
|: <a href="http://libvirt.org" target="_blank">http://libvirt.org</a>              -o-             <a href="http://virt-manager.org" target="_blank">http://virt-manager.org</a> :|<br>
|: <a href="http://autobuild.org" target="_blank">http://autobuild.org</a>       -o-         <a href="http://search.cpan.org/~danberr/" target="_blank">http://search.cpan.org/~danberr/</a> :|<br>
|: <a href="http://entangle-photo.org" target="_blank">http://entangle-photo.org</a>       -o-       <a href="http://live.gnome.org/gtk-vnc" target="_blank">http://live.gnome.org/gtk-vnc</a> :|<br>
</font></span></blockquote></div><br></div>