CFB.encrypt

ubyte[] encrypt(const(ubyte)[] input)

Encrypts data using CFB mode.

CFB encryption:

  1. Encrypt the shift register to produce output block
  2. XOR plaintext segment with MSB of output block
  3. Shift ciphertext into the shift register

Parameters

inputPlaintext to encrypt. Length must be a multiple of segment size.

Returns

Ciphertext of the same length as input.

Throws

CryptoException if input length is not a multiple of segment size.