code: public static String hexMD5(String value) {
          try {
              MessageDigest messageDigest = MessageDigest.getInstance("MD5");
              messageDigest.reset();
              messageDigest.update(value.getBytes("utf-8"));
              byte[] digest = messageDigest.digest();
              return byteToHexString(digest);
          } catch (Exception ex) {
              throw new UnexpectedException(ex);
          }
      }
docs: Build an hexadecimal MD5 hash for a String
  
  @param value The String to hash
  @return An hexadecimal Hash