mirror of
https://github.com/openssl/openssl.git
synced 2024-11-21 01:15:20 +08:00
property: create property names more eagerly.
User defined property names were not created before the first fetch. The rationale for this was to only maintain the user names defined by providers. This was intended to prevent malicious memory use attacks. Not being able to specify a default query before the first fetch is wrong. This changes the behaviour of the property query parsing to always create property names. Fixes #15218 Reviewed-by: Tim Hudson <tjh@openssl.org> Reviewed-by: Matt Caswell <matt@openssl.org> (Merged from https://github.com/openssl/openssl/pull/15222)
This commit is contained in:
parent
ab6db11e63
commit
1f12bf71fe
@ -407,12 +407,12 @@ OSSL_PROPERTY_LIST *ossl_parse_query(OSSL_LIB_CTX *ctx, const char *s,
|
||||
if (match_ch(&s, '-')) {
|
||||
prop->oper = PROPERTY_OVERRIDE;
|
||||
prop->optional = 0;
|
||||
if (!parse_name(ctx, &s, 0, &prop->name_idx))
|
||||
if (!parse_name(ctx, &s, 1, &prop->name_idx))
|
||||
goto err;
|
||||
goto skip_value;
|
||||
}
|
||||
prop->optional = match_ch(&s, '?');
|
||||
if (!parse_name(ctx, &s, 0, &prop->name_idx))
|
||||
if (!parse_name(ctx, &s, 1, &prop->name_idx))
|
||||
goto err;
|
||||
|
||||
if (match_ch(&s, '=')) {
|
||||
|
Loading…
Reference in New Issue
Block a user