CSharp examples for System:Byte Array
byte array To MD Hash
using System.Threading.Tasks; using System.Text; using System.Security.Cryptography; using System.Linq; using System.Collections.Generic; using System;//w w w . j a v a 2s . c o m public class Main{ public static string ToMD5Hash(this byte[] target) { if (null == target) throw new ArgumentNullException("target"); var md5 = MD5.Create(); var hashInBytes = md5.ComputeHash(target); return Convert.ToBase64String(hashInBytes); } }