}
}
-int kr_ta_covers(map_t *trust_anchors, const knot_dname_t *name)
-{
- while(name) {
- if (kr_ta_get(trust_anchors, name)) {
- return true;
- }
- if (name[0] == '\0') {
- return false;
- }
- name = knot_wire_next_label(name, NULL);
- }
- return false;
-}
-
/* Delete record data */
static int del_record(const char *k, void *v, void *ext)
{
int kr_ta_add(map_t *trust_anchors, const knot_dname_t *name, uint16_t type,
uint32_t ttl, const uint8_t *rdata, uint16_t rdlen);
-/**
- * Return true if the name is below/at any TA in the store.
- * This can be useful to check if it's possible to validate a name beforehand.
- * @param trust_anchors trust store
- * @param name name of the TA
- * @return boolean
- */
-KR_EXPORT KR_PURE
-int kr_ta_covers(map_t *trust_anchors, const knot_dname_t *name);
-
struct kr_context;
/**
*/
KR_EXPORT
const knot_dname_t *kr_ta_get_longest_name(map_t *trust_anchors, const knot_dname_t *name);
+