Encrypted wire protocol