fix error messages in cipher