Lines Matching refs:params

32 #include <openssl/params.h>
64 * to use or modify |*params|, depending on
80 * the passed |*params| in whatever way
109 * modify the passed |*params| in whatever
138 * modify the passed |*params| in whatever
175 * For ctrl to params translation, the actual ctrl command number used.
176 * For params to ctrl translation, 0.
180 * For ctrl_str to params translation, the actual ctrl command string
182 * For params to ctrl translation, this is NULL. Along with it is also
194 /* pointer to the OSSL_PARAM-style params array. */
195 OSSL_PARAM *params;
230 * Conditions, for params->ctrl translations.
309 * For ctrl_str to params translation, we allow direct use of
401 * PRE_CTRL_TO_PARAMS and POST_CTRL_TO_PARAMS handle ctrl to params
403 * |*params|, and POST_CTRL_TO_PARAMS is responsible for bringing the
407 /* This is ctrl to params translation, so we need an OSSL_PARAM key */
446 *ctx->params = OSSL_PARAM_construct_int(translation->param_key,
472 *ctx->params =
488 *ctx->params =
494 *ctx->params =
499 *ctx->params =
504 *ctx->params =
509 *ctx->params =
527 ctx->p1 = (int)ctx->params[0].return_size;
535 * params translations. PRE_CTRL_TO_PARAMS is responsible for preparing
536 * |*params|, and POST_CTRL_TO_PARAMS currently has nothing to do, since
541 /* This is ctrl_str to params translation */
575 if (!OSSL_PARAM_allocate_from_text(ctx->params, settable,
588 ctx->allocated_buf = ctx->params->data;
589 ctx->buflen = ctx->params->data_size;
597 * PRE_PARAMS_TO_CTRL and POST_PARAMS_TO_CTRL handle params to ctrl
601 * to |*params|.
606 * |ctx->params| accordingly.
614 /* This is params to ctrl translation */
618 /* When setting, we populate |p1| and |p2| from |*params| */
621 return OSSL_PARAM_get_int(ctx->params, &ctx->p1);
625 if (!OSSL_PARAM_get_BN(ctx->params, ctx->p2))
629 if (!OSSL_PARAM_get_uint(ctx->params,
635 return OSSL_PARAM_get_utf8_string(ctx->params,
638 return OSSL_PARAM_get_octet_string(ctx->params,
642 return OSSL_PARAM_get_octet_ptr(ctx->params,
666 param_data_type = ctx->params->data_type;
668 /* When getting, we populate |*params| from |p1| and |p2| */
671 return OSSL_PARAM_set_int(ctx->params, ctx->p1);
675 return OSSL_PARAM_set_BN(ctx->params, ctx->p2);
678 return OSSL_PARAM_set_uint(ctx->params,
683 return OSSL_PARAM_set_utf8_string(ctx->params, ctx->p2);
685 return OSSL_PARAM_set_octet_string(ctx->params, ctx->p2,
688 return OSSL_PARAM_set_octet_ptr(ctx->params, ctx->p2,
960 * We're translating from ctrl to params and setting the OID, or
961 * we're translating from params to ctrl and getting the OID.
978 * We're translating from ctrl to params and setting the OID name,
979 * or we're translating from params to ctrl and getting the OID
1154 * We're translating from params to ctrl and setting the curve name.
1293 ctx->params[0] = OSSL_PARAM_construct_int(translation->param_key,
1305 switch (ctx->params->data_type) {
1307 return OSSL_PARAM_get_int(ctx->params, &ctx->p1);
1309 return OSSL_PARAM_get_uint(ctx->params, (unsigned int *)&ctx->p1);
1567 if (ctx->params->data_type != OSSL_PARAM_UNSIGNED_INTEGER)
1610 switch (ctx->params->data_type) {
1625 if (ctx->params->data_type == OSSL_PARAM_UNSIGNED_INTEGER) {
1633 if (ctx->params->data_type == OSSL_PARAM_OCTET_STRING) {
1666 if (ctx->params->data_type != OSSL_PARAM_UNSIGNED_INTEGER)
1747 if (ctx->params->data_type != OSSL_PARAM_INTEGER)
1984 if (OSSL_PARAM_get_utf8_string_ptr(ctx->params, &value) == 0 ||
2544 * ctrl->params, ctrl_str->params, and params->ctrl
2633 OSSL_PARAM params[2] = { OSSL_PARAM_END, OSSL_PARAM_END };
2661 ctx.params = params;
2671 ret = evp_pkey_ctx_get_params_strict(pctx, ctx.params);
2674 ret = evp_pkey_ctx_set_params_strict(pctx, ctx.params);
2701 OSSL_PARAM params[2] = { OSSL_PARAM_END, OSSL_PARAM_END };
2727 ctx.params = params;
2743 ret = evp_pkey_ctx_set_params_strict(pctx, ctx.params);
2759 OSSL_PARAM *params)
2764 for (; params != NULL && params->key != NULL; params++) {
2774 tmpl.param_key = params->key;
2784 ctx.params = params;
2810 int evp_pkey_ctx_set_params_to_ctrl(EVP_PKEY_CTX *ctx, const OSSL_PARAM *params)
2812 return evp_pkey_ctx_setget_params_to_ctrl(ctx, SET, (OSSL_PARAM *)params);
2815 int evp_pkey_ctx_get_params_to_ctrl(EVP_PKEY_CTX *ctx, OSSL_PARAM *params)
2817 return evp_pkey_ctx_setget_params_to_ctrl(ctx, GET, params);
2823 OSSL_PARAM *params)
2827 for (; params != NULL && params->key != NULL; params++) {
2834 tmpl.param_key = params->key;
2843 ctx.params = params;
2863 int evp_pkey_get_params_to_ctrl(const EVP_PKEY *pkey, OSSL_PARAM *params)
2865 return evp_pkey_setget_params_to_ctrl(pkey, GET, params);