code: public static byte[] computeMD5Hash(byte[] input) {
          try {
              MessageDigest md = MessageDigest.getInstance("MD5");
              return md.digest(input);
          } catch (NoSuchAlgorithmException e) {
              // should never get here
              throw new IllegalStateException(e);
          }
      }
docs: Computes the MD5 hash of the given data and returns it as an array of
  bytes.