Arun Viswanath
2013-Nov-25 17:59 UTC
[libvirt-users] Help required in simulating libvirt TLS server
Hi All, Will some one explain how is this tls libvirt server is implemented. For my testing purpose I need to implement the similar TLS server in Java or Python and this server is capable to receive all libvirt calls like getCapabilities, hostname etc and return response as I'm configured. Basically I need to simulate the libvirt TLS server. I tried creating many TLS server but none of the my TLS server implemenation is capable to do proper handshake with python libvirt client and do successful calls. Any ideas or help will be appreciable. Thanks In Advance, Arun V
Eric Blake
2013-Nov-25 18:07 UTC
Re: [libvirt-users] [libvirt] Help required in simulating libvirt TLS server
On 11/25/2013 10:59 AM, Arun Viswanath wrote:> Hi All, > > Will some one explain how is this tls libvirt server is implemented. For my > testing purpose I need to implement the similar TLS server in Java or > Python and this server is capable to receive all libvirt calls like > getCapabilities, hostname etc and return response as I'm configured. > Basically I need to simulate the libvirt TLS server. I tried creating many > TLS server but none of the my TLS server implemenation is capable to do > proper handshake with python libvirt client and do successful calls. Any > ideas or help will be appreciable.I think the advice you were given last time is still accurate: https://www.redhat.com/archives/libvirt-users/2013-September/msg00086.html You are probably going to be better off hooking your simulations into the existing test:/// URI driver than trying to write your own RPC client counterparts, as the existing code will handle tls on your behalf. -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
Daniel P. Berrange
2013-Nov-26 09:23 UTC
Re: [libvirt-users] Help required in simulating libvirt TLS server
On Mon, Nov 25, 2013 at 11:29:42PM +0530, Arun Viswanath wrote:> Hi All, > > Will some one explain how is this tls libvirt server is implemented. For my > testing purpose I need to implement the similar TLS server in Java or > Python and this server is capable to receive all libvirt calls like > getCapabilities, hostname etc and return response as I'm configured. > Basically I need to simulate the libvirt TLS server. I tried creating many > TLS server but none of the my TLS server implemenation is capable to do > proper handshake with python libvirt client and do successful calls. Any > ideas or help will be appreciable.I really strongly recommend against trying to re-implement the libvirt RPC protocol again. The protocol is pretty complex & easy to screw up. We consider it a private implementation detail of libvirt and we won't support use of libvirt client against any 3rd party server impl or vica verca. Daniel -- |: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :| |: http://libvirt.org -o- http://virt-manager.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|