static byte[] md5OfFileAsByteArray(File f) ctex { if (!isFile(f)) null; var md5 = MessageDigest.getInstance("MD5"); temp FileInputStream in = new FileInputStream(f); byte buf[] = new byte[65536]; int l; while (true) { l = in.read(buf); if (l <= 0) break; md5.update(buf, 0, l); } ret md5.digest(); }