Home | History | Annotate | Download | only in ec

Lines Matching defs:EC_POINT

131 typedef struct ec_point_st EC_POINT;
232 * \param generator EC_POINT object with the generator.
238 int EC_GROUP_set_generator(EC_GROUP *group, const EC_POINT *generator, const BIGNUM *order, const BIGNUM *cofactor);
244 const EC_POINT *EC_GROUP_get0_generator(const EC_GROUP *group);
401 /* EC_POINT functions */
404 /** Creates a new EC_POINT object for the specified EC_GROUP
406 * \return newly created EC_POINT object or NULL if an error occurred
408 EC_POINT *EC_POINT_new(const EC_GROUP *group);
410 /** Frees a EC_POINT object
411 * \param point EC_POINT object to be freed
413 void EC_POINT_free(EC_POINT *point);
415 /** Clears and frees a EC_POINT object
416 * \param point EC_POINT object to be cleared and freed
418 void EC_POINT_clear_free(EC_POINT *point);
420 /** Copies EC_POINT object
421 * \param dst destination EC_POINT object
422 * \param src source EC_POINT object
425 int EC_POINT_copy(EC_POINT *dst, const EC_POINT *src);
427 /** Creates a new EC_POINT object and copies the content of the supplied
428 EC_POINT
429 * \param src source EC_POINT object
431 * \return newly created EC_POINT object or NULL if an error occurred
433 EC_POINT *EC_POINT_dup(const EC_POINT *src, const EC_GROUP *group);
435 /** Returns the EC_METHOD used in EC_POINT object
436 * \param point EC_POINT object
439 const EC_METHOD *EC_POINT_method_of(const EC_POINT *point);
443 * \param point EC_POINT to set to infinity
446 int EC_POINT_set_to_infinity(const EC_GROUP *group, EC_POINT *point);
448 /** Sets the jacobian projective coordinates of a EC_POINT over GFp
450 * \param p EC_POINT object
457 int EC_POINT_set_Jprojective_coordinates_GFp(const EC_GROUP *group, EC_POINT *p,
460 /** Gets the jacobian projective coordinates of a EC_POINT over GFp
462 * \param p EC_POINT object
470 const EC_POINT *p, BIGNUM *x, BIGNUM *y, BIGNUM *z, BN_CTX *ctx);
472 /** Sets the affine coordinates of a EC_POINT over GFp
474 * \param p EC_POINT object
480 int EC_POINT_set_affine_coordinates_GFp(const EC_GROUP *group, EC_POINT *p,
483 /** Gets the affine coordinates of a EC_POINT over GFp
485 * \param p EC_POINT object
492 const EC_POINT *p, BIGNUM *x, BIGNUM *y, BN_CTX *ctx);
494 /** Sets the x9.62 compressed coordinates of a EC_POINT over GFp
496 * \param p EC_POINT object
502 int EC_POINT_set_compressed_coordinates_GFp(const EC_GROUP *group, EC_POINT *p,
505 /** Sets the affine coordinates of a EC_POINT over GF2m
507 * \param p EC_POINT object
513 int EC_POINT_set_affine_coordinates_GF2m(const EC_GROUP *group, EC_POINT *p,
516 /** Gets the affine coordinates of a EC_POINT over GF2m
518 * \param p EC_POINT object
525 const EC_POINT *p, BIGNUM *x, BIGNUM *y, BN_CTX *ctx);
527 /** Sets the x9.62 compressed coordinates of a EC_POINT over GF2m
529 * \param p EC_POINT object
535 int EC_POINT_set_compressed_coordinates_GF2m(const EC_GROUP *group, EC_POINT *p,
538 /** Encodes a EC_POINT object to a octet string
540 * \param p EC_POINT object
548 size_t EC_POINT_point2oct(const EC_GROUP *group, const EC_POINT *p,
552 /** Decodes a EC_POINT from a octet string
554 * \param p EC_POINT object
560 int EC_POINT_oct2point(const EC_GROUP *group, EC_POINT *p,
564 BIGNUM *EC_POINT_point2bn(const EC_GROUP *, const EC_POINT *,
566 EC_POINT *EC_POINT_bn2point(const EC_GROUP *, const BIGNUM *,
567 EC_POINT *, BN_CTX *);
568 char *EC_POINT_point2hex(const EC_GROUP *, const EC_POINT *,
570 EC_POINT *EC_POINT_hex2point(const EC_GROUP *, const char *,
571 EC_POINT *, BN_CTX *);
575 /* functions for doing EC_POINT arithmetic */
578 /** Computes the sum of two EC_POINT
580 * \param r EC_POINT object for the result (r = a + b)
581 * \param a EC_POINT object with the first summand
582 * \param b EC_POINT object with the second summand
586 int EC_POINT_add(const EC_GROUP *group, EC_POINT *r, const EC_POINT *a, const EC_POINT *b, BN_CTX *ctx);
588 /** Computes the double of a EC_POINT
590 * \param r EC_POINT object for the result (r = 2 * a)
591 * \param a EC_POINT object
595 int EC_POINT_dbl(const EC_GROUP *group, EC_POINT *r, const EC_POINT *a, BN_CTX *ctx);
597 /** Computes the inverse of a EC_POINT
599 * \param a EC_POINT object to be inverted (it's used for the result as well)
603 int EC_POINT_invert(const EC_GROUP *group, EC_POINT *a, BN_CTX *ctx);
607 * \param p EC_POINT object
610 int EC_POINT_is_at_infinity(const EC_GROUP *group, const EC_POINT *p);
614 * \param point EC_POINT object to check
618 int EC_POINT_is_on_curve(const EC_GROUP *group, const EC_POINT *point, BN_CTX *ctx);
622 * \param a first EC_POINT object
623 * \param b second EC_POINT object
627 int EC_POINT_cmp(const EC_GROUP *group, const EC_POINT *a, const EC_POINT *b, BN_CTX *ctx);
629 int EC_POINT_make_affine(const EC_GROUP *group, EC_POINT *point, BN_CTX *ctx);
630 int EC_POINTs_make_affine(const EC_GROUP *group, size_t num, EC_POINT *points[], BN_CTX *ctx);
634 * \param r EC_POINT object for the result
637 * \param p array of size num of EC_POINT objects
642 int EC_POINTs_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *n, size_t num, const EC_POINT *p[], const BIGNUM *m[], BN_CTX *ctx);
646 * \param r EC_POINT object for the result
648 * \param q EC_POINT object with the first factor of the second summand
653 int EC_POINT_mul(const EC_GROUP *group, EC_POINT *r, const BIGNUM *n, const EC_POINT *q, const BIGNUM *m, BN_CTX *ctx);
790 * \return a EC_POINT object with the public key (possibly NULL)
792 const EC_POINT *EC_KEY_get0_public_key(const EC_KEY *key);
796 * \param pub EC_POINT object with the public key (note: the EC_KEY object
797 * will use an own copy of the EC_POINT object).
800 int EC_KEY_set_public_key(EC_KEY *key, const EC_POINT *pub);