Function createPeerIdFromPublicKey