package com.msgilligan.bitcoinj.json.conversion;

import com.fasterxml.jackson.core.JsonGenerator;
import com.fasterxml.jackson.core.JsonProcessingException;
import com.fasterxml.jackson.databind.JsonSerializer;
import com.fasterxml.jackson.databind.SerializerProvider;
import org.bitcoinj.core.ECKey;

import java.io.IOException;

/**
 * Serialize (without private key)
 */
public class ECKeySerializer extends JsonSerializer<ECKey> {
    @Override
    public void serialize(ECKey value, JsonGenerator gen, SerializerProvider serializers) throws IOException, JsonProcessingException {
        gen.writeNumber(value.toString());
    }
}

@@ -600,29 +600,38 @@
 rite
-Number
+String
 (value.
-toString
+getPublicKeyAsHex
 ());

Fix to ECKeySerializer#serialize