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);
827 void EC_KEY_set_nonce_from_hash(EC_KEY *key, int on);
831 int EC_KEY_get_nonce_from_hash(const EC_KEY *key);
834 * accelerate further EC_KEY operations.
835 * \param key EC_KEY object
839 int EC_KEY_precompute_mult(EC_KEY *key, BN_CTX *ctx);
842 * \param key EC_KEY object
845 int EC_KEY_generate_key(EC_KEY *key);
848 * \param key the EC_KEY object
851 int EC_KEY_check_key(const EC_KEY *key);
855 * \param key the EC_KEY object
860 int EC_KEY_set_public_key_affine_coordinates(EC_KEY *key, BIGNUM *x, BIGNUM *y);
868 * \param key a pointer to a EC_KEY object which should be used (or NULL)
873 EC_KEY *d2i_ECPrivateKey(EC_KEY **key, const unsigned char **in, long len);
876 * \param key the EC_KEY object to encode
881 int i2d_ECPrivateKey(EC_KEY *key, unsigned char **out);
889 * \param key a pointer to a EC_KEY object which should be used (or NULL)
892 * \return a EC_KEY object with the decoded parameters or NULL if an error
895 EC_KEY *d2i_ECParameters(EC_KEY **key, const unsigned char **in, long len);
898 * \param key the EC_KEY object with ec paramters to encode
903 int i2d_ECParameters(EC_KEY *key, unsigned char **out);
912 * \param key a pointer to a EC_KEY object which should be used
915 * \return EC_KEY object with decoded public key or NULL if an error
918 EC_KEY *o2i_ECPublicKey(EC_KEY **key, const unsigned char **in, long len);
921 * \param key the EC_KEY object with the public key
926 int i2o_ECPublicKey(EC_KEY *key, unsigned char **out);
931 * \param key EC_KEY object
934 int ECParameters_print(BIO *bp, const EC_KEY *key);
936 /** Prints out the contents of a EC_KEY object
938 * \param key EC_KEY object
942 int EC_KEY_print(BIO *bp, const EC_KEY *key, int off);
948 * \param key EC_KEY object
951 int ECParameters_print_fp(FILE *fp, const EC_KEY *key);
953 /** Prints out the contents of a EC_KEY object
955 * \param key EC_KEY object
959 int EC_KEY_print_fp(FILE *fp, const EC_KEY *key, int off);
963 #define ECParameters_dup(x) ASN1_dup_of(EC_KEY,i2d_ECParameters,d2i_ECParameters,x)