func ReadPublicKey(hexKey string) (*ecdsa.PublicKey, error) {
	key, err := hex.DecodeString(hexKey)
	if err != nil {
		return nil, fmt.Errorf("failed to read public key: %s", err.Error())
	}

	x, y := elliptic.Unmarshal(elliptic.P256(), key)
	return &ecdsa.PublicKey{
		Curve: elliptic.P256(),
		X:     x,
		Y:     y,
	}, nil
}
// ReadPublicKey reads a public key from a hex string (A P-256 FIPS 186.3 with
// ANSI X9.62 encoding (ecdsa public key of  a 256 bits curve)).
ReadPublicKey reads a public key from a hex string (A P-256 FIPS 186.3 with
ANSI X9.62 encoding (ecdsa public key of  a 256 bits curve)).
// ReadPublicKey reads a public key from a hex string ( A P - 256 FIPS 186 . 3 with // ANSI X9 . 62 encoding ( ecdsa public key of a 256 bits curve )) .
func ReadPublicKey(hexKey string) (*ecdsa.PublicKey, error) {
	key, err := hex.DecodeString(hexKey)
	if err != nil {
		return nil, fmt.Errorf("failed to read public key: %s", err.Error())
	}
	x, y := elliptic.Unmarshal(elliptic.P256(), key)
	return &ecdsa.PublicKey{
		Curve: elliptic.P256(),
		X:     x,
		Y:     y,
	}, nil
}
func ReadPublicKey ( hexKey string ) ( * ecdsa . PublicKey , error ) { key , err := hex . DecodeString ( hexKey ) if err != nil { return nil , fmt . Errorf ( " " , err . Error ( ) ) } x , y := elliptic . Unmarshal ( elliptic . P256 ( ) , key ) return & ecdsa . PublicKey { Curve : elliptic . P256 ( ) , X : x , Y : y , } , nil }
ReadPublicKey reads a public key from a hex string (A P-256 FIPS 186.3 with
ANSI X9.62 encoding (ecdsa public key of  a 256 bits curve)).
ReadPublicKey reads a public key from a hex string ( A P - 256 FIPS 186 . 3 with ANSI X9 . 62 encoding ( ecdsa public key of a 256 bits curve )) .