CryptoSys API Library Manual

CipherStream.Bytes Method

Enciphers data in array of bytes using specified stream cipher.

Syntax

[C#]
public static byte[] Bytes(
	byte[] input,
	byte[] key,
	byte[] iv,
	int counter,
	CipherStream.Algorithm streamAlg
)
[VB.NET]
Public Shared Function Bytes ( _
	input As Byte(), _
	key As Byte(), _
	iv As Byte(), _
	counter As Integer, _
	streamAlg As CipherStream.Algorithm _
) As Byte()

Parameters

input
Input data to be encrypted
key
Key
iv
Initialization Vector (IV, nonce) or null for Arcfour
counter
Counter value for ChaCha20 only, otherwise ignored. Use 0 for default.
streamAlg
Type: CipherStream.Algorithm
Stream cipher algorithm

Return Value

Ciphertext in byte array, or empty array on error

Remarks

See Also

VB6/C equivalent: CIPHER_StreamBytes

[Contents] [Index]

[PREV: Cipher.Update Method (String)...]   [Contents]   [Index]   
   [NEXT: CipherStream.Dispose Method...]

Copyright © 2001-24 D.I. Management Services Pty Ltd. All rights reserved. Generated 2024-01-07T07:42:00Z.