java - RPC CertIOException "malformed data: sequence wrong size for a certificate" -
i’m trying use rpc connect m12 cordaapp , call nodeidentity()
method, i'm getting org.bouncycastle.cert.certioexception
. think java client code works, can see rpc connection , when try call getprotocolversion()
instead see correct protocol version.
here stack trace when calling nodeidentity()
:
10:50:25.848 [thread-0 (activemq-client-global-threads-1076641925)] error org.apache.activemq.artemis.core.client - amq214000: failed call onmessage org.bouncycastle.cert.certioexception: malformed data: sequence wrong size certificate @ org.bouncycastle.cert.x509certificateholder.parsebytes(unknown source) ~[bcpkix-jdk15on-1.56.jar:1.56.0.0] @ org.bouncycastle.cert.x509certificateholder.(unknown source) ~[bcpkix-jdk15on-1.56.jar:1.56.0.0] @ net.corda.core.serialization.x509certificateserializer.read(kryo.kt:641) ~[core-0.12.1.jar:?] @ net.corda.core.serialization.x509certificateserializer.read(kryo.kt:639) ~[core-0.12.1.jar:?] @ com.esotericsoftware.kryo.kryo.readobject(kryo.java:731) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.serializers.objectfield.read(objectfield.java:125) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.serializers.compatiblefieldserializer.read(compatiblefieldserializer.java:147) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.kryo.readobjectornull(kryo.java:782) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.serializers.objectfield.read(objectfield.java:132) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.serializers.compatiblefieldserializer.read(compatiblefieldserializer.java:147) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.kryo.readclassandobject(kryo.java:813) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.serializers.collectionserializer.read(collectionserializer.java:134) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.serializers.collectionserializer.read(collectionserializer.java:40) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.kryo.readobject(kryo.java:731) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.serializers.objectfield.read(objectfield.java:125) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.serializers.compatiblefieldserializer.read(compatiblefieldserializer.java:147) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.kryo.readclassandobject(kryo.java:813) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.serializers.collectionserializer.read(collectionserializer.java:134) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.serializers.collectionserializer.read(collectionserializer.java:40) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.kryo.readobject(kryo.java:731) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.serializers.objectfield.read(objectfield.java:125) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.serializers.compatiblefieldserializer.read(compatiblefieldserializer.java:147) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.kryo.readobject(kryo.java:731) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.serializers.objectfield.read(objectfield.java:125) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.serializers.compatiblefieldserializer.read(compatiblefieldserializer.java:147) ~[kryo-4.0.0.jar:?] @ com.esotericsoftware.kryo.kryo.readclassandobject(kryo.java:813) ~[kryo-4.0.0.jar:?] @ net.corda.core.serialization.kryokt$deserialize$1$1.execute(kryo.kt:110) ~[core-0.12.1.jar:?] @ net.corda.core.serialization.kryopoolwithcontext.run(kryo.kt:653) ~[core-0.12.1.jar:?] @ net.corda.core.serialization.kryokt.deserialize(kryo.kt:110) ~[core-0.12.1.jar:?] @ net.corda.nodeapi.rpcapi$servertoclient$companion.fromclientmessage(rpcapi.kt:177) ~[node-api-0.12.1.jar:?] @ net.corda.client.rpc.internal.rpcclientproxyhandler.artemismessagehandler(rpcclientproxyhandler.kt:224) ~[rpc-0.12.1.jar:?] @ net.corda.client.rpc.internal.rpcclientproxyhandler.access$artemismessagehandler(rpcclientproxyhandler.kt:58) ~[rpc-0.12.1.jar:?] @ net.corda.client.rpc.internal.rpcclientproxyhandler$start$3.invoke(rpcclientproxyhandler.kt:174) ~[rpc-0.12.1.jar:?] @ net.corda.client.rpc.internal.rpcclientproxyhandler$start$3.invoke(rpcclientproxyhandler.kt:58) ~[rpc-0.12.1.jar:?] @ net.corda.client.rpc.internal.rpcclientproxyhandlerkt$sam$messagehandler$43516406.onmessage(rpcclientproxyhandler.kt) ~[rpc-0.12.1.jar:?] @ org.apache.activemq.artemis.core.client.impl.clientconsumerimpl.callonmessage(clientconsumerimpl.java:1001) ~[artemis-core-client-1.5.3.jar:1.5.3] @ org.apache.activemq.artemis.core.client.impl.clientconsumerimpl.access$400(clientconsumerimpl.java:49) ~[artemis-core-client-1.5.3.jar:1.5.3] @ org.apache.activemq.artemis.core.client.impl.clientconsumerimpl$runner.run(clientconsumerimpl.java:1124) [artemis-core-client-1.5.3.jar:1.5.3] @ org.apache.activemq.artemis.utils.orderedexecutorfactory$orderedexecutor$executortask.run(orderedexecutorfactory.java:101) [artemis-commons-1.5.3.jar:1.5.3] @ java.util.concurrent.threadpoolexecutor.runworker(threadpoolexecutor.java:1142) [?:1.8.0_131] @ java.util.concurrent.threadpoolexecutor$worker.run(threadpoolexecutor.java:617) [?:1.8.0_131] @ java.lang.thread.run(thread.java:748) [?:1.8.0_131] caused by: java.lang.illegalargumentexception: sequence wrong size certificate @ org.bouncycastle.asn1.x509.certificate.(unknown source) ~[bcprov-jdk15on-1.56.jar:1.56.0] @ org.bouncycastle.asn1.x509.certificate.getinstance(unknown source) ~[bcprov-jdk15on-1.56.jar:1.56.0] ... 42 more
it looks there wrong x509 certificate serialization, did miss something?
we suspect may fixed in m13 m14 right around corner, may worth , updating straight that.
Comments
Post a Comment