23RCSID(
"$Id: f0764a2fe69e8f28f0ea31a33d8b3f99fa85587f $")
25#include <freeradius-devel/util/pair.h>
26#include <freeradius-devel/util/value.h>
81 fr_sbuff_parse_rules_t
const *rules;
85 fr_sbuff_marker(&name_m, &our_in);
88 if (da->parent != pair_ctx->
parent) {
173 fr_sbuff_marker(&name_m, &our_in);
176 if (da->parent !=
parent) {
268 fr_sbuff_marker(&name_m, &our_in);
#define L(_str)
Helper for initialising arrays of string literals.
fr_slen_t fr_dict_attr_by_name_substr(fr_dict_attr_err_t *err, fr_dict_attr_t const **out, fr_dict_attr_t const *parent, fr_sbuff_t *name, fr_sbuff_term_t const *tt))
fr_dict_attr_t const * fr_dict_root(fr_dict_t const *dict)
Return the root attribute of a dictionary.
@ FR_TYPE_TLV
Contains nested attributes.
@ FR_TYPE_STRUCT
like TLV, but without T or L, and fixed-width children
@ FR_TYPE_GROUP
A grouping of other attributes.
fr_pair_t * fr_pair_afrom_da(TALLOC_CTX *ctx, fr_dict_attr_t const *da)
Dynamically allocate a new attribute and assign a fr_dict_attr_t.
fr_slen_t fr_pair_ctx_afrom_substr(fr_pair_ctx_t *pair_ctx, fr_sbuff_t *in)
Parse one pair, or one context change, from a string.
static fr_slen_t pair_ctx_set_from_substr(fr_pair_ctx_t *pair_ctx, fr_sbuff_t *in)
Set a new parent from a dotted attribute reference.
void fr_pair_ctx_reset(fr_pair_ctx_t *pair_ctx, fr_dict_t const *dict)
Reset a pair_ctx to the dictionary root.
fr_table_num_sorted_t const fr_pair_comparison_op_table[]
Operators that may appear between an attribute name and a value.
static fr_slen_t pair_afrom_substr(fr_pair_ctx_t *pair_ctx, fr_sbuff_t *in)
Parse Attribute op value and append the pair to pair_ctx->list.
size_t fr_pair_comparison_op_table_len
static fr_sbuff_parse_rules_t const pair_value_bareword_rules
A bare word value ends at whitespace or at the comma before the next pair.
bool fr_sbuff_next_if_char(fr_sbuff_t *sbuff, char c)
Return true if the current char matches, and if it does, advance.
#define fr_sbuff_out_by_longest_prefix(_match_len, _out, _table, _sbuff, _def)
#define fr_sbuff_set(_dst, _src)
#define fr_sbuff_adv_past_whitespace(_sbuff, _len, _tt)
#define FR_SBUFF_TERMS(...)
Initialise a terminal structure with a list of sorted strings.
#define fr_sbuff_extend(_sbuff_or_marker)
#define fr_sbuff_is_char(_sbuff_or_marker, _c)
#define FR_SBUFF_ERROR_RETURN(_sbuff_or_marker)
#define FR_SBUFF_SET_RETURN(_dst, _src)
#define FR_SBUFF(_sbuff_or_marker)
#define fr_sbuff_advance(_sbuff_or_marker, _len)
Stores an attribute, a value and various bits of other data.
An element in a lexicographically sorted array of name to num mappings.
TALLOC_CTX * ctx
to allocate VPs in
fr_pair_list_t * list
of VPs to add
fr_dict_attr_t const * parent
current attribute to allocate VPs in
#define fr_strerror_printf(_fmt,...)
Log to thread local error buffer.
#define fr_strerror_const(_msg)
fr_sbuff_parse_rules_t const value_parse_rules_single_quoted
fr_slen_t fr_value_box_from_substr(TALLOC_CTX *ctx, fr_value_box_t *dst, fr_type_t dst_type, fr_dict_attr_t const *dst_enumv, fr_sbuff_t *in, fr_sbuff_parse_rules_t const *rules)
Convert string value to a fr_value_box_t type.
fr_sbuff_parse_rules_t const value_parse_rules_double_quoted
static fr_sbuff_err_t char size_t fr_sbuff_t * in