Argon2FixedTimeEquals Method

Compare two ZeroedBuffers without leaking timing information.

Definition

Namespace: Gemstone.Security.Cryptography.Argon2Hash
Assembly: Gemstone.Security (in Gemstone.Security.dll) Version: 1.0.173 -- Release Build+d4109cef771ccafc97cdee2a4e18d5c0b500452d
public static bool FixedTimeEquals(
	ZeroedBuffer<byte> left,
	ZeroedBuffer<byte> right
)

Parameters

left  ZeroedBufferByte
The first ZeroedBuffer to compare.
right  ZeroedBufferByte
The second ZeroedBuffer to compare.

Return Value

Boolean
true if left and right have the same values for Length and the same contents; otherwise, false.

Remarks

Uses System.Security.Cryptography.CryptographicOperations.FixedTimeEquals() when available; otherwise implements a similar algorithm.

See Also