@@ -629,7 +629,7 @@ def to_pem(
629629 implementations, it is as big as "uncompressed".
630630 :param str curve_parameters_encoding: the encoding for curve parameters
631631 to use, by default tries to use ``named_curve`` encoding,
632- if that is not possible, falls back to ``named_curve `` encoding.
632+ if that is not possible, falls back to ``explicit `` encoding.
633633
634634 :return: portable encoding of the public key
635635 :rtype: bytes
@@ -658,7 +658,7 @@ def to_der(
658658 implementations, it is as big as "uncompressed".
659659 :param str curve_parameters_encoding: the encoding for curve parameters
660660 to use, by default tries to use ``named_curve`` encoding,
661- if that is not possible, falls back to ``named_curve `` encoding.
661+ if that is not possible, falls back to ``explicit `` encoding.
662662
663663 :return: DER encoding of the public key
664664 :rtype: bytes
@@ -674,7 +674,7 @@ def to_der(
674674 return der .encode_sequence (
675675 der .encode_sequence (
676676 encoded_oid_ecPublicKey ,
677- self .curve .to_der (curve_parameters_encoding ),
677+ self .curve .to_der (curve_parameters_encoding , point_encoding ),
678678 ),
679679 # 0 is the number of unused bits in the
680680 # bit string
0 commit comments