Forum Discussion

Antony_Hawkins's avatar
3 years ago

Credentials-absent Resource identification by HTML Title - PropertySource

OK, so this is so insanely simple you'll wonder why no-one else has done it before.

I dunno, maybe they have. Whatever.

What it does:

It makes an http call and if there is an HTML <title> field, adds that content as a Resource auto.property, to help determine what a Resource is when you don't have credentials.

Why?

Some time ago, I wrote this: a href="https://communities.logicmonitor.com/topic/7589-generic-https-resource-type-discovery-template/" rel="">https://communities.logicmonitor.com/topic/7589-generic-https-resource-type-discovery-template/

...which is great for credentials-absent discovery of resource types, when you already know what you're looking for.

What if you don't?

I'm currently working with an MSP to attempt to determine which of the 1,200 or so responsive IPs in a customer's multiple networks are worth pursuing (in terms of, trying to find credentials for).

It occurred that almost anything that gives an HTML page via an HTTP/S response will contain a <title> field and we don't need to know what that is, to report it.

This PropertySource simply calls http://hostname, in a way that follows redirects, and outputs the content of the <title> field, if found, as a property named auto.html.title, e.g.

Boom.

Now, we can create a dynamic group with AppliesTo of simply:

auto.html.title

 

...and create and run a Resource Inventory Report against that group, to return all those values.

Clearly, not every Resource will have an HTML page, but in our case above, nearly 400 of those 1,200 IPs do, and a quick scan of the sorted report shows a lot of desktop and barcode printers, access points, VOIP phones, etc - stuff we don't care about monitoring - and a lot more resources that don't identify themselves specifically in the property, but clearly give similar responses to dozens of other resources, meaning we should only have to investigate a small proportion of them to be able to categorise all of them. Quite possibly by casting a Mk1 eyeball over the full HTML response, and using a modification of my HTTP Resource Type Discovery PropertySource to automatically and positively identify those things, that can then be grouped (and/or deleted).

Compared to manually checking 400 Resource IPs against tribal knowledge, or attempting to manually connect to them all? That's a massive time saving.

PropertySource: http_html_title

v1.0 Published with lmLocator: LXYKY6

3 Replies