In Java I have a ECDH public Key that I am sending as a byte array.
Once I have received the byte array how can I turn it back into a public key?
I am using Bouncy Castle but a Java solution would be just as useful.
Thanks
In Java I have a ECDH public Key that I am sending as a byte array.
Once I have received the byte array how can I turn it back into a public key?
I am using Bouncy Castle but a Java solution would be just as useful.
Thanks
How are the raw bytes formatted for the ECDH key? Where are you getting the raw bytes?
Generally, one uses the appropriate *Spec class to turn raw key material into a Key but the ECPublicKeySpec and DHPublicKeySpec classes don't accept a raw byte array.