diff options
author | rcritten@redhat.com <rcritten@redhat.com> | 2007-08-06 10:05:53 -0400 |
---|---|---|
committer | rcritten@redhat.com <rcritten@redhat.com> | 2007-08-06 10:05:53 -0400 |
commit | 993f76fe6035cf59cceb88f3611fc53680738007 (patch) | |
tree | 17bb5afed002709bd322f5fe7e99e473adc1d018 /ipa-server/xmlrpc-server/ipaxmlrpc.py | |
parent | 66ab69d0b23da46b21dbb4bf165011f318ec2da8 (diff) | |
download | freeipa-993f76fe6035cf59cceb88f3611fc53680738007.tar.gz freeipa-993f76fe6035cf59cceb88f3611fc53680738007.tar.xz freeipa-993f76fe6035cf59cceb88f3611fc53680738007.zip |
- Abstracted client class to work directly or over RPC
- Add mod_auth_kerb and cyrus-sasl-gssapi to Requires
- Remove references to admin server in ipa-server-setupssl
- Generate a client certificate for the XML-RPC server to connect to LDAP with
- Create a keytab for Apache
- Create an ldif with a test user
- Provide a certmap.conf for doing SSL client authentication
- Update tools to use kerberos
- Add User class
Diffstat (limited to 'ipa-server/xmlrpc-server/ipaxmlrpc.py')
-rw-r--r-- | ipa-server/xmlrpc-server/ipaxmlrpc.py | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/ipa-server/xmlrpc-server/ipaxmlrpc.py b/ipa-server/xmlrpc-server/ipaxmlrpc.py index ad5e30683..7bad9ab5e 100644 --- a/ipa-server/xmlrpc-server/ipaxmlrpc.py +++ b/ipa-server/xmlrpc-server/ipaxmlrpc.py @@ -123,11 +123,16 @@ class ModXMLRPCRequestHandler(object): def register_instance(self,instance): self.register_module(instance) - def _marshaled_dispatch(self, data): + def _marshaled_dispatch(self, data, remoteuser): """Dispatches an XML-RPC method from marshalled (XML) data.""" params, method = loads(data) + opts={} + opts['remoteuser'] = remoteuser + + params = ipaserver.encode_args(params, opts) + # special case # if method == "get_user": # Marshaller._Marshaller__dump = xmlrpclib_dump @@ -239,7 +244,7 @@ class ModXMLRPCRequestHandler(object): req.allow_methods(['POST'],1) raise apache.SERVER_RETURN, apache.HTTP_METHOD_NOT_ALLOWED - response = self._marshaled_dispatch(req.read()) + response = self._marshaled_dispatch(req.read(), req.user) req.content_type = "text/xml" req.set_content_length(len(response)) @@ -267,10 +272,12 @@ def handler(req, profiling=False): else: opts = req.get_options() try: + f = funcs.IPAServer() h = ModXMLRPCRequestHandler() - h.register_function(funcs.get_user) - h.register_function(funcs.add_user) - h.register_function(funcs.get_add_schema) + h.register_function(f.get_user) + h.register_function(f.add_user) + h.register_function(f.get_add_schema) + h.register_function(f.get_all_users) h.handle_request(req) finally: pass |