Home | History | Annotate | Download | only in dist

Lines Matching refs:label

29  * able to quickly index and compare by label.
41 * root label).
128 * Offsets into NAME for each label starting with the most
129 * significant label (the root label, followed by the TLD,
140 * The actual name in wire format (a sequence of label, each
142 * label).
154 * Return the label for DNAME specified by LABEL_INDEX. The first
155 * label (LABEL_INDEX == 0) is the root label, the next label is the
161 dname_label(const dname_type *dname, uint8_t label)
166 assert(label < dname->label_count);
168 label_index = dname_label_offsets(dname)[label];
178 * significant label.
204 * with the most significant label. Because the root label always
228 * Is LABEL a normal LABEL (not a pointer or reserved)?
230 * Pre: label != NULL;
233 label_is_normal(const uint8_t *label)
235 assert(label);
236 return (label[0] & 0xc0) == 0;
241 * Is LABEL a pointer?
243 * Pre: label != NULL;
246 label_is_pointer(const uint8_t *label)
248 assert(label);
249 return (label[0] & 0xc0) == 0xc0;
254 * LABEL's pointer location.
256 * Pre: label != NULL && label_is_pointer(label)
259 label_pointer_location(const uint8_t *label)
261 assert(label);
262 assert(label_is_pointer(label));
263 return ((uint16_t) (label[0] & ~0xc0) << 8) | (uint16_t) label[1];
268 * Length of LABEL.
270 * Pre: label != NULL && label_is_normal(label)
273 label_length(const uint8_t *label)
275 assert(label);
276 assert(label_is_normal(label));
277 return label[0];
282 * The data of LABEL.
284 * Pre: label != NULL && label_is_normal(label)
287 label_data(const uint8_t *label)
289 assert(label);
290 assert(label_is_normal(label));
291 return label + 1;
296 * Is LABEL the root label?
298 * Pre: label != NULL
301 label_is_root(const uint8_t *label)
303 assert(label);
304 return label[0] == 0;
309 * Is LABEL the wildcard label?
311 * Pre: label != NULL
314 label_is_wildcard(const uint8_t *label)
316 assert(label);
317 return label[0] == 1 && label[1] == '*';
322 * The next label of LABEL.
324 * Pre: label != NULL
325 * label_is_normal(label)
326 * !label_is_root(label)
329 label_next(const uint8_t *label)
331 assert(label);
332 assert(label_is_normal(label));
333 assert(!label_is_root(label));
334 return label + label_length(label) + 1;
366 * Create a dname containing the single label specified by STR
367 * followed by the root label.
370 const uint8_t *label,
394 /** convert uncompressed label to string */
395 char* wirelabel2str(const uint8_t* label);
420 * The labelcount can be 1 byte per label, maxlen/2 + 1(root label).
429 * Make the dname and label offsets.