Python - remote object protocols and security

Burak Arslan burak.arslan at arskom.com.tr
Mon Jul 15 08:50:10 EDT 2013


Hi,

On 07/15/13 13:30, Chris Angelico wrote:
> On Mon, Jul 15, 2013 at 10:26 PM, Jean-Michel Pichavant
> <jeanmichel at sequans.com> wrote:
>> Basically, I need to transfer numbers (int). Possibly dictionaries like {string: int} in order to structure things a little bit.
> I strongly recommend JSON, then. It's a well-known system, it's
> compact, it's secure, and Python comes with a json module.
>

Especially for numbers, MessagePack is more efficient. Its API is
identical to Json, so it's almost a drop-in replacement.

A project that I've been working on, Spyne, is designed to implement
public RPC services. It supports both Json and MessagePack. Here's the
json example:
http://spyne.io/#inprot=JsonDocument&outprot=JsonDocument&s=rpc&tpt=WsgiApplication&validator=true

If you choose to use MessagePack, you must HTTP POST the MessagePack
document the same way you'd POST the json document.

Best regards,
Burak




More information about the Python-list mailing list