Login

Tag "xmlrpc"

Snippet List

In-memory XML-RPC server based on URL

This is a XML-RPC server, that uses arguments in URLs and every dispatcher instance is prepared in memory during webserver run. It's good, for example, for securing XML-RPC server with hashed strings and there are a lot of similar use cases. Usage: from xmlrpclib import ServerProxy server = ServerProxy('http://example.com/xmlr-rpc/%s/' % something, allow_none=True) server.do_something(*args)

  • xml
  • server
  • dispatcher
  • xmlrpc
Read More

general-purpose django XMLRC dispatcher

create an instance of this class: `rpcserver = XMLRPC()` then define handlers on it with the register decorator: @rpcserver.register("pingback.ping") def handle_pingback(sourceURI, targetURI) # ... de-serialization of the arguments and serialization of the return values is handled by the XMLRPC object, so just expect python built-in types as your arguments and use them as your return values. you can also raise instances of xmlrpclib.Fault from within your handlers and a proper xmlrpc fault will be sent out as the response. then you can use `rpcserver.view` in your urlconf to offer up your XML-RPC service at a URL: urlpatterns = patterns('', url(r'^$', rpcserver.view, name="xmlrpc"), # ... )

  • xmlrpc
Read More

xmlrpc basic auth

decorator which performs basic http auth authentication against the known userbase. This decorator is only for xml-rpc services. When there is no basic auth a proper response will be returned

  • auth
  • xmlrpc
Read More

3 snippets posted so far.