RandomGetBytes Method

Fills an array of bytes with a cryptographically strong sequence of random values.

Definition

Namespace: Gemstone.Security.Cryptography
Assembly: Gemstone.Common (in Gemstone.Common.dll) Version: 1.0.128 -- Release Build+d050cfc5563c89a1188cc3c6b2d417530856f490
public static void GetBytes(
	byte[] buffer
)

Parameters

buffer  Byte
The array to fill with a cryptographically strong sequence of random values.

Remarks

The length of the byte array determines how many cryptographically strong random bytes are produced.

This method is thread safe.

Exceptions

CryptographicExceptionThe cryptographic service provider (CSP) cannot be acquired.
ArgumentNullExceptionbuffer is null.

See Also