public Transform ( byte data ) : void | ||
data | byte | The array to transform. This array will be directly modified. |
return | void |
public void Transform(byte[] data)
{
Guard.NotNull(() => data, data);
this.algorithm.TransformArraySegment(data, this.iv, 0, data.Length);
this.iv = this.algorithm.ShuffleIv(this.iv);
}
/// <summary> /// Decrypts the given packet in-place. /// </summary> /// <remarks> /// The array will be modified directly. /// </remarks> /// <param name="packet">The data to decrypt.</param> public void Decrypt(byte[] packet) { lock (_decryptor) { _decryptor.Transform(packet); CustomCrypto.Decrypt(packet); } }