Lines Matching defs:EC_KEY
212 * form src to the newly created EC_KEY object
705 /* EC_KEY functions */
708 typedef struct ec_key_st EC_KEY;
718 /** Creates a new EC_KEY object.
719 * \return EC_KEY object or NULL if an error occurred.
721 EC_KEY *EC_KEY_new(void);
723 int EC_KEY_get_flags(const EC_KEY *key);
725 void EC_KEY_set_flags(EC_KEY *key, int flags);
727 void EC_KEY_clear_flags(EC_KEY *key, int flags);
729 /** Creates a new EC_KEY object using a named curve as underlying
732 * \return EC_KEY object or NULL if an error occurred.
734 EC_KEY *EC_KEY_new_by_curve_name(int nid);
736 /** Frees a EC_KEY object.
737 * \param key EC_KEY object to be freed.
739 void EC_KEY_free(EC_KEY *key);
741 /** Copies a EC_KEY object.
742 * \param dst destination EC_KEY object
743 * \param src src EC_KEY object
746 EC_KEY *EC_KEY_copy(EC_KEY *dst, const EC_KEY *src);
748 /** Creates a new EC_KEY object and copies the content from src to it.
749 * \param src the source EC_KEY object
750 * \return newly created EC_KEY object or NULL if an error occurred.
752 EC_KEY *EC_KEY_dup(const EC_KEY *src);
754 /** Increases the internal reference count of a EC_KEY object.
755 * \param key EC_KEY object
758 int EC_KEY_up_ref(EC_KEY *key);
760 /** Returns the EC_GROUP object of a EC_KEY object
761 * \param key EC_KEY object
764 const EC_GROUP *EC_KEY_get0_group(const EC_KEY *key);
766 /** Sets the EC_GROUP of a EC_KEY object.
767 * \param key EC_KEY object
768 * \param group EC_GROUP to use in the EC_KEY object (note: the EC_KEY
772 int EC_KEY_set_group(EC_KEY *key, const EC_GROUP *group);
774 /** Returns the private key of a EC_KEY object.
775 * \param key EC_KEY object
778 const BIGNUM *EC_KEY_get0_private_key(const EC_KEY *key);
780 /** Sets the private key of a EC_KEY object.
781 * \param key EC_KEY object
782 * \param prv BIGNUM with the private key (note: the EC_KEY object
786 int EC_KEY_set_private_key(EC_KEY *key, const BIGNUM *prv);
788 /** Returns the public key of a EC_KEY object.
789 * \param key the EC_KEY object
792 const EC_POINT *EC_KEY_get0_public_key(const EC_KEY *key);
794 /** Sets the public key of a EC_KEY object.
795 * \param key EC_KEY object
796 * \param pub EC_POINT object with the public key (note: the EC_KEY object
800 int EC_KEY_set_public_key(EC_KEY *key, const EC_POINT *pub);
802 unsigned EC_KEY_get_enc_flags(const EC_KEY *key);
803 void EC_KEY_set_enc_flags(EC_KEY *eckey, unsigned int flags);
804 point_conversion_form_t EC_KEY_get_conv_form(const EC_KEY *key);
805 void EC_KEY_set_conv_form(EC_KEY *eckey, point_conversion_form_t cform);
807 void *EC_KEY_get_key_method_data(EC_KEY *key,
809 /** Sets the key method data of an EC_KEY object, if none has yet been set.
810 * \param key EC_KEY object
817 void *EC_KEY_insert_key_method_data(EC_KEY *key, void *data,
820 void EC_KEY_set_asn1_flag(EC_KEY *eckey, int asn1_flag);
823 * accelerate further EC_KEY operations.
824 * \param key EC_KEY object
828 int EC_KEY_precompute_mult(EC_KEY *key, BN_CTX *ctx);
831 * \param key EC_KEY object
834 int EC_KEY_generate_key(EC_KEY *key);
837 * \param key the EC_KEY object
840 int EC_KEY_check_key(const EC_KEY *key);
844 * \param key the EC_KEY object
849 int EC_KEY_set_public_key_affine_coordinates(EC_KEY *key, BIGNUM *x, BIGNUM *y);
857 * \param key a pointer to a EC_KEY object which should be used (or NULL)
862 EC_KEY *d2i_ECPrivateKey(EC_KEY **key, const unsigned char **in, long len);
865 * \param key the EC_KEY object to encode
870 int i2d_ECPrivateKey(EC_KEY *key, unsigned char **out);
878 * \param key a pointer to a EC_KEY object which should be used (or NULL)
881 * \return a EC_KEY object with the decoded parameters or NULL if an error
884 EC_KEY *d2i_ECParameters(EC_KEY **key, const unsigned char **in, long len);
887 * \param key the EC_KEY object with ec paramters to encode
892 int i2d_ECParameters(EC_KEY *key, unsigned char **out);
901 * \param key a pointer to a EC_KEY object which should be used
904 * \return EC_KEY object with decoded public key or NULL if an error
907 EC_KEY *o2i_ECPublicKey(EC_KEY **key, const unsigned char **in, long len);
910 * \param key the EC_KEY object with the public key
915 int i2o_ECPublicKey(EC_KEY *key, unsigned char **out);
920 * \param key EC_KEY object
923 int ECParameters_print(BIO *bp, const EC_KEY *key);
925 /** Prints out the contents of a EC_KEY object
927 * \param key EC_KEY object
931 int EC_KEY_print(BIO *bp, const EC_KEY *key, int off);
937 * \param key EC_KEY object
940 int ECParameters_print_fp(FILE *fp, const EC_KEY *key);
942 /** Prints out the contents of a EC_KEY object
944 * \param key EC_KEY object
948 int EC_KEY_print_fp(FILE *fp, const EC_KEY *key, int off);
952 #define ECParameters_dup(x) ASN1_dup_of(EC_KEY,i2d_ECParameters,d2i_ECParameters,x)