Java tutorial
//package com.java2s; import org.apache.commons.codec.binary.Hex; public class Main { public static String byteToHexString(byte[] bytes) { return String.valueOf(Hex.encodeHex(bytes)); } }