/// <summary>
 /// Initializes a new instance of the <see cref="XmlSecureNodeXPath"/> class.
 /// </summary>
 /// <param name="xPath">The x path.</param>
 public XmlSecureNodeXPath(string xPath)
 {
     XPath         = xPath;
     HashString    = CryptoServices.ComputeHashBase64String(xPath, "SHA256");
     AppliedXPaths = new string[] { xPath };
 }
Example #2
0
 /// <summary>
 /// Generates the password hash.
 /// </summary>
 /// <param name="salt">The salt.</param>
 /// <param name="password">The password.</param>
 /// <param name="hashAlgo">The hash algo.</param>
 /// <returns></returns>
 public static string GeneratePasswordHash(string salt, string password, string hashAlgo)
 {
     return(CryptoServices.ComputeHashBase64String(string.Concat(salt, password), hashAlgo));
 }