SecureComparisonEquals Method | CryptSharp |
Compares two strings in a timing-insensitive manner.
Namespace: CryptSharp.Utility
Assembly: CryptSharp (in CryptSharp.dll) Version: 2.1.0.0
Syntax
public static bool Equals( string potentialAttackerSuppliedString, string referenceString )
Public Shared Function Equals ( potentialAttackerSuppliedString As String, referenceString As String ) As Boolean
public: static bool Equals( String^ potentialAttackerSuppliedString, String^ referenceString )
static member Equals : potentialAttackerSuppliedString : string * referenceString : string -> bool
Parameters
- potentialAttackerSuppliedString
- Type: SystemString
The string controlled by a potential attacker. - referenceString
- Type: SystemString
The string not controlled by a potential attacker.
Return Value
Type: Booleantrue if the strings are equal.
Remarks
See Also