new SHA1Managed() : SHA1Managed : Security C# Source Code


Custom Search

C# Source Code » Security » SHA1Managed »

 

new SHA1Managed()








    
 
using System;
using System.Text;
using System.Security.Cryptography;

class MainClass {
    public static void Main(string[] args) {
        HashAlgorithm hashAlg = null;
        hashAlg = new SHA1Managed();
        using (hashAlg) {
            byte[] pwordData = Encoding.Default.GetBytes(args[1]);

            byte[] hash = hashAlg.ComputeHash(pwordData);

            Console.WriteLine(BitConverter.ToString(hash));
        }
    }
}

 
    
   
  
   







HTML code for linking to this page:

Follow Navioo On Twitter

C# Source Code

 Navioo Security
» SHA1Managed