git://git.onelab.eu
/
nodemanager.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
blind and brutal 2to3
[nodemanager.git]
/
safexmlrpc.py
diff --git
a/safexmlrpc.py
b/safexmlrpc.py
index
f320c9c
..
71bf4d6
100644
(file)
--- a/
safexmlrpc.py
+++ b/
safexmlrpc.py
@@
-1,10
+1,11
@@
-# $Id$
-
"""Leverage curl to make XMLRPC requests that check the server's credentials."""
"""Leverage curl to make XMLRPC requests that check the server's credentials."""
+import xmlrpc.client
+
import curlwrapper
import curlwrapper
-class CertificateCheckingSafeTransport (xmlrpclib.Transport):
+
+class CertificateCheckingSafeTransport (xmlrpc.client.Transport):
def __init__(self, cacert, timeout):
self.cacert = cacert
def __init__(self, cacert, timeout):
self.cacert = cacert
@@
-18,11
+19,11
@@
class CertificateCheckingSafeTransport (xmlrpclib.Transport):
cacert = self.cacert,
postdata = request_body,
timeout = self.timeout)
cacert = self.cacert,
postdata = request_body,
timeout = self.timeout)
- return xmlrpc
lib
.loads(contents)[0]
+ return xmlrpc
.client
.loads(contents)[0]
-class ServerProxy(xmlrpc
lib
.ServerProxy):
+class ServerProxy(xmlrpc
.client
.ServerProxy):
def __init__(self, uri, cacert, timeout = 300, **kwds):
def __init__(self, uri, cacert, timeout = 300, **kwds):
- xmlrpc
lib
.ServerProxy.__init__(self, uri,
+ xmlrpc
.client
.ServerProxy.__init__(self, uri,
CertificateCheckingSafeTransport(cacert, timeout),
**kwds)
CertificateCheckingSafeTransport(cacert, timeout),
**kwds)