Lines Matching defs:ctx
71 EC_POINT *point, const BIGNUM *x_, int y_bit, BN_CTX *ctx)
81 BN_CTX_start(ctx);
83 if ((tmp1 = BN_CTX_get(ctx)) == NULL)
85 if ((tmp2 = BN_CTX_get(ctx)) == NULL)
87 if ((x = BN_CTX_get(ctx)) == NULL)
89 if ((y = BN_CTX_get(ctx)) == NULL)
98 if (!BN_nnmod(x, x_, &group->field, ctx))
102 if (!group->meth->field_sqr(group, tmp2, x_, ctx))
104 if (!group->meth->field_mul(group, tmp1, tmp2, x_, ctx))
107 if (!BN_mod_sqr(tmp2, x_, &group->field, ctx))
109 if (!BN_mod_mul(tmp1, tmp2, x_, &group->field, ctx))
123 if (!group->meth->field_decode(group, tmp2, &group->a, ctx))
125 if (!BN_mod_mul(tmp2, tmp2, x, &group->field, ctx))
129 if (!group->meth->field_mul(group, tmp2, &group->a, x, ctx))
139 if (!group->meth->field_decode(group, tmp2, &group->b, ctx))
148 if (!BN_mod_sqrt(y, tmp1, &group->field, ctx)) {
170 if (!EC_POINT_set_affine_coordinates(group, point, x, y, ctx))
176 BN_CTX_end(ctx);
183 point_conversion_form_t form, unsigned char *buf, size_t len, BN_CTX *ctx)
212 BN_CTX_start(ctx);
221 if ((x = BN_CTX_get(ctx)) == NULL)
223 if ((y = BN_CTX_get(ctx)) == NULL)
226 if (!EC_POINT_get_affine_coordinates(group, point, x, y, ctx))
271 BN_CTX_end(ctx);
278 const unsigned char *buf, size_t len, BN_CTX *ctx)
318 BN_CTX_start(ctx);
320 if ((x = BN_CTX_get(ctx)) == NULL)
322 if ((y = BN_CTX_get(ctx)) == NULL)
336 if (!EC_POINT_set_compressed_coordinates(group, point, x, y_bit, ctx))
355 if (!EC_POINT_set_affine_coordinates(group, point, x, y, ctx))
362 BN_CTX_end(ctx);