how to convert hex string into base64 ? I found this page http://home2.paulschou.net/tools/xlate/ but I need some function in java: String base64 = ...decoder(String h
String base64 = ...decoder(String h
Have a look at Commons Codec :
import org.apache.commons.codec.binary.Base64; import org.apache.commons.codec.binary.Hex; byte[] decodedHex = Hex.decodeHex(hex); byte[] encodedHexB64 = Base64.encodeBase64(decodedHex);