fixed cases where plaintext had null bytes at end of body