Add statschannel counter for Root Key Sentinel feature
This commit is contained in:
committed by
Ondřej Surý
parent
4d59a96b98
commit
bddc5f7834
@@ -311,6 +311,8 @@ init_desc(void) {
|
||||
"QryUsedStale");
|
||||
SET_NSSTATDESC(prefetch, "queries triggered prefetch", "Prefetch");
|
||||
SET_NSSTATDESC(keytagopt, "Keytag option received", "KeyTagOpt");
|
||||
SET_NSSTATDESC(rootkeysentinel, "Root key sentinel queries",
|
||||
"RootKeySentinel");
|
||||
INSIST(i == ns_statscounter_max);
|
||||
|
||||
/* Initialize resolver statistics */
|
||||
|
||||
@@ -101,8 +101,9 @@ enum {
|
||||
|
||||
ns_statscounter_prefetch = 63,
|
||||
ns_statscounter_keytagopt = 64,
|
||||
ns_statscounter_rootkeysentinel = 65,
|
||||
|
||||
ns_statscounter_max = 65
|
||||
ns_statscounter_max = 66
|
||||
};
|
||||
|
||||
void
|
||||
|
||||
@@ -5166,6 +5166,7 @@ root_key_sentinel_detect(query_ctx_t *qctx) {
|
||||
ns_client_log(qctx->client, NS_LOGCATEGORY_TAT,
|
||||
NS_LOGMODULE_QUERY, ISC_LOG_INFO,
|
||||
"root-key-sentinel-is-ta query label found");
|
||||
inc_stats(qctx->client, ns_statscounter_rootkeysentinel);
|
||||
} else if (qctx->client->query.qname->length > 31 && ndata[0] == 30 &&
|
||||
strncasecmp(ndata + 1, "root-key-sentinel-not-ta-", 25) == 0)
|
||||
{
|
||||
@@ -5181,6 +5182,7 @@ root_key_sentinel_detect(query_ctx_t *qctx) {
|
||||
ns_client_log(qctx->client, NS_LOGCATEGORY_TAT,
|
||||
NS_LOGMODULE_QUERY, ISC_LOG_INFO,
|
||||
"root-key-sentinel-not-ta query label found");
|
||||
inc_stats(qctx->client, ns_statscounter_rootkeysentinel);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user