Here you can find the source of SHA256(byte[] src)
public static byte[] SHA256(byte[] src)
//package com.java2s; //License from project: Open Source License import java.security.MessageDigest; public class Main { public static byte[] SHA256(byte[] src) { try {/*www .j a va 2s . com*/ MessageDigest md = MessageDigest.getInstance("SHA-256"); md.update(src); return md.digest(); } catch (Exception e) { } return null; } }