NRDP Bug: Host name is case sensitive

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
User avatar
eloyd
Cool Title Here
Posts: 2129
Joined: Thu Sep 27, 2012 9:14 am
Location: Rochester, NY
Contact:

NRDP Bug: Host name is case sensitive

Post by eloyd »

I believe we've discovered a bug in NRDP processing that took us a while to figure out. I'd appreciate knowing if anyone else can reproduce it:

In XI, create a host called "THIS-host" (case sensitive).
In NRDP, send a service check called "service-check" on host "this-host" (still case sensitive)
Nagios will say "Unable to find service" for "service-check" on "this-host"
In NRDP, send a service check called "service-check" on host "THIS-host" (still case sensitive)
And it works.

So inbound checks are apparently case sensitive with [at least] the hostname. This took us a while to figure out because we had a host that was created in the XI GUI, that we had service checks added to, that we then turned on automatic addition of unconfigured objects, but the sending host is identifying itself as "this-host" but the hostname in XI is "THIS-host" to make it easier to differentiate between "THIS-host" and "THAT-host" and "OTHER-host." The names are changed for this example, but I think you get the idea.

I considered posting this in the Github for NRDP, but I'm pretty sure it's an incoming processing issue inside of Nagios, not specifically an NRDP issue itself; NRDP is just the delivery vector.

Can anyone confirm that it's not just us? If so, can anyone provide a patch to fix? We need to be able to match case-insensitive hostnames due to the manner in which they will be dynamically generated.
Image
Eric Loyd • http://everwatch.global • 844.240.EVER • @EricLoydI'm a Nagios Fanatic!
User avatar
eloyd
Cool Title Here
Posts: 2129
Joined: Thu Sep 27, 2012 9:14 am
Location: Rochester, NY
Contact:

Re: NRDP Bug: Host name is case sensitive

Post by eloyd »

Okay, so after some historical research, I see that hostnames are case sensitive for Nagios. I don't know why I never ran across this before.

I humbly submit that that should not be the case. I can see that service names should be (though I could argue that ping PING and pInG should not all exist as separate checks) but hostname/FQDN should be case-insensitive. No one is going to have a this.is.my.host and a THIS.is.my.host that are different.

Besides, the RFC for DNS case insensitivity states that DNS names should be case insensitive (https://tools.ietf.org/html/rfc4343). Specifically, "[a]ccording to the original DNS design decision, comparisons on name lookup for DNS queries should be case insensitive." So to be compliant with that RFC, Nagios should compare hostnames in a case-insensitive manner.
Image
Eric Loyd • http://everwatch.global • 844.240.EVER • @EricLoydI'm a Nagios Fanatic!
ssax
Dreams In Code
Posts: 7682
Joined: Wed Feb 11, 2015 12:54 pm

Re: NRDP Bug: Host name is case sensitive

Post by ssax »

Locked