fixed encryption/serialization mismatch