Martin Geisler <[EMAIL PROTECTED]> writes: Hi again!
> We use the marshal module in the ShareExchanger class to, well, > marshal data in shares before they are exchanged. [...] I forgot to add that the solution to this should be easy in our case. We only send very simple data over the network: * Program counters which are tuples of integers. * GF256 objects which contain a single byte for the value. * GFElement objects which contain a long int prime modulus and a long int value. I think that is it, which means that we can use something like the struct module for packing the 32-bit integers into bytes and something a little more complicated for the long integers. When we start using the GMPY module again for the big integer arithmetic, we might be able to use the gmpy.binary function. But I don't know how that function will handle arbitrary binary data... In both cases we should know in advance how many bytes to read (since we know the field size), so we can simply always read that many bytes. All this business about protecting against malicious input data is of course somewhat silly now when VIFF assumes a passive adversary. But I think it is good to think about it already now since it will make things easier for us when we begin looking at security against active adversaries later on. -- Martin Geisler _______________________________________________ viff-devel mailing list (http://viff.dk/) [email protected] http://lists.viff.dk/listinfo.cgi/viff-devel-viff.dk
