namespace System.Security.Rng;
public interface ICryptoRngProvider
{
///
/// Populate provided array of bytes with cryptographically secure random bytes.
///
/// Array of bytes to be populated.
public void GetBytes(byte[] data);
///
/// Return an array of cryptographically secure random bytes.
///
/// Length of the returned array.
/// Array containing cryptographically secure random values.
public byte[] GetBytes(int byteCount);
///
/// Populate provided array of bytes with cryptographically secure random non-zero bytes.
///
/// Array of bytes to be populated.
public void GetNonZeroBytes(byte[] data);
///
/// Return an array of cryptographically secure random non-zero bytes.
///
/// Length of the returned array.
/// Array containing cryptographically secure random non-zero values.
public byte[] GetNonZeroBytes(int byteCount);
}