mirror of
https://github.com/isc-projects/bind9.git
synced 2026-06-12 16:00:00 -04:00
3755. [func] Add stats counters for known EDNS options + others.
[RT #35447]
This commit is contained in:
parent
c48c691c4f
commit
02a5e3ed85
4 changed files with 25 additions and 9 deletions
3
CHANGES
3
CHANGES
|
|
@ -1,3 +1,6 @@
|
|||
3755. [func] Add stats counters for known EDNS options + others.
|
||||
[RT #35447]
|
||||
|
||||
--- 9.10.0b1 released ---
|
||||
|
||||
3754. [cleanup] win32: Installer now places files in the
|
||||
|
|
|
|||
|
|
@ -1776,6 +1776,8 @@ process_opt(ns_client_t *client, dns_rdataset_t *opt) {
|
|||
optlen = isc_buffer_getuint16(&optbuf);
|
||||
switch (optcode) {
|
||||
case DNS_OPT_NSID:
|
||||
isc_stats_increment(ns_g_server->nsstats,
|
||||
dns_nsstatscounter_nsidopt);
|
||||
client->attributes |= NS_CLIENTATTR_WANTNSID;
|
||||
isc_buffer_forward(&optbuf, optlen);
|
||||
break;
|
||||
|
|
@ -1785,10 +1787,14 @@ process_opt(ns_client_t *client, dns_rdataset_t *opt) {
|
|||
break;
|
||||
#endif
|
||||
case DNS_OPT_EXPIRE:
|
||||
isc_stats_increment(ns_g_server->nsstats,
|
||||
dns_nsstatscounter_expireopt);
|
||||
client->attributes |= NS_CLIENTATTR_WANTEXPIRE;
|
||||
isc_buffer_forward(&optbuf, optlen);
|
||||
break;
|
||||
default:
|
||||
isc_stats_increment(ns_g_server->nsstats,
|
||||
dns_nsstatscounter_otheropt);
|
||||
isc_buffer_forward(&optbuf, optlen);
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -180,17 +180,21 @@ enum {
|
|||
dns_nsstatscounter_udp = 41,
|
||||
dns_nsstatscounter_tcp = 42,
|
||||
|
||||
#ifdef ISC_PLATFORM_USESIT
|
||||
dns_nsstatscounter_sitopt = 43,
|
||||
dns_nsstatscounter_sitbadsize = 44,
|
||||
dns_nsstatscounter_sitbadtime = 45,
|
||||
dns_nsstatscounter_sitnomatch = 46,
|
||||
dns_nsstatscounter_sitmatch = 47,
|
||||
dns_nsstatscounter_sitnew = 48,
|
||||
dns_nsstatscounter_nsidopt = 43,
|
||||
dns_nsstatscounter_expireopt = 44,
|
||||
dns_nsstatscounter_otheropt = 45,
|
||||
|
||||
dns_nsstatscounter_max = 49
|
||||
#ifdef ISC_PLATFORM_USESIT
|
||||
dns_nsstatscounter_sitopt = 46,
|
||||
dns_nsstatscounter_sitbadsize = 47,
|
||||
dns_nsstatscounter_sitbadtime = 48,
|
||||
dns_nsstatscounter_sitnomatch = 49,
|
||||
dns_nsstatscounter_sitmatch = 50,
|
||||
dns_nsstatscounter_sitnew = 51,
|
||||
|
||||
dns_nsstatscounter_max = 52
|
||||
#else
|
||||
dns_nsstatscounter_max = 43
|
||||
dns_nsstatscounter_max = 46
|
||||
#endif
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -220,6 +220,9 @@ init_desc(void) {
|
|||
"RPZRewrites");
|
||||
SET_NSSTATDESC(udp, "UDP queries received", "QryUDP");
|
||||
SET_NSSTATDESC(tcp, "TCP queries received", "QryTCP");
|
||||
SET_NSSTATDESC(nsidopt, "NSID option received", "NSIDOpt");
|
||||
SET_NSSTATDESC(expireopt, "Expire option recieved", "ExpireOpt");
|
||||
SET_NSSTATDESC(otheropt, "Other EDNS option recieved", "OtherOpt");
|
||||
#ifdef ISC_PLATFORM_USESIT
|
||||
SET_NSSTATDESC(sitopt, "source identity token option received",
|
||||
"SitOpt");
|
||||
|
|
|
|||
Loading…
Reference in a new issue