Compute MD5 Hash - CSharp System.Security.Cryptography

CSharp examples for System.Security.Cryptography:MD5

Description

Compute MD5 Hash

Demo Code

// Copyright (C) 2006-2015 Esper Team. All rights reserved.                           /
using System.Text;
using System.Security.Cryptography;
using System.Collections.Generic;
using System;/*from   w w w  . java  2s .c om*/

public class Main{
        public static byte[] ComputeMD5Hash( byte[] data, int offset, int length )
        {
            MD5 md5Hasher = MD5.Create();
            byte[] dataHash = md5Hasher.ComputeHash(data, offset, length);
            return dataHash;
        }
}

Related Tutorials