summaryrefslogtreecommitdiffstats
path: root/ipa-server/xmlrpc-server/ipaxmlrpc.py
diff options
context:
space:
mode:
authorKevin McCarthy <kmccarth@redhat.com>2007-08-22 10:30:51 -0700
committerKevin McCarthy <kmccarth@redhat.com>2007-08-22 10:30:51 -0700
commit7691653c0a3ee95aab7c64d631c694a300547345 (patch)
treed1d3018438cc2b4abdc0b24c2751b85028e96e76 /ipa-server/xmlrpc-server/ipaxmlrpc.py
parenta8f302aa9f193984d68318a65a51b41298b1391d (diff)
downloadfreeipa-7691653c0a3ee95aab7c64d631c694a300547345.tar.gz
freeipa-7691653c0a3ee95aab7c64d631c694a300547345.tar.xz
freeipa-7691653c0a3ee95aab7c64d631c694a300547345.zip
Create ipaerror module.
Move LDAPError trapping/conversion into the ipaldap module. Fix xmlrpc layer to encode/decode ipaerrors properly. Also, implement mid-air collision exception for updates.
Diffstat (limited to 'ipa-server/xmlrpc-server/ipaxmlrpc.py')
-rw-r--r--ipa-server/xmlrpc-server/ipaxmlrpc.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/ipa-server/xmlrpc-server/ipaxmlrpc.py b/ipa-server/xmlrpc-server/ipaxmlrpc.py
index 03340ca5f..be4762c35 100644
--- a/ipa-server/xmlrpc-server/ipaxmlrpc.py
+++ b/ipa-server/xmlrpc-server/ipaxmlrpc.py
@@ -35,6 +35,8 @@ from mod_python import apache
import ipaserver
import funcs
+from ipa import ipaerror
+
import string
import base64
@@ -144,9 +146,9 @@ class ModXMLRPCRequestHandler(object):
# wrap response in a singleton tuple
response = (response,)
response = dumps(response, methodresponse=1, allow_none=1)
- except Fault, fault:
+ except ipaerror.IPAError, e:
self.traceback = True
- response = dumps(fault)
+ response = dumps(Fault(e.code, str(e)))
except:
self.traceback = True
# report exception back to server