serialization: signed/encrypted messages