All Apps and Add-ons

Content Analysis comparison with Http Response

ashishamalviya1
Explorer

Currently we are matching the Content of http Response with value in Content Analysis,
we have a scenario where we need to compare the content (greater then or less then) and provide the content match as True or False,

eg :-

`<group-status xmlns="http://abc.com/manage/groups" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://abc.com/manage/groups manage-groups.xsd">
<id>1041339500789136</id>
<name>Default</name>
<meta>...</meta>
<relations>...</relations>
<status-properties>
<hosts-status-summary>
<total-hosts units="quantity">4</total-hosts>`

we need to compare, total-hosts units should be greater then 3

Tags (1)
0 Karma

LukeMurphey
Champion

I would recommend the Website Input app instead.

You should be able to get what you want using Website Input by using an input that extracts that data along with a search the ensures the value is what you expect. Here is what I am thinking:

  1. Create an input using the included wizard against the URL with the given XML file. Set the selector to "total-hosts". Confirm that the extraction is working as intended by clicking "Preview Output".
  2. Create a saved search that looks at the output created by the input you just made. You ought to be able to setup the logic such that it will alert you when "total-hosts" is 3 or less (something like "... | search match <= 3"
0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

Announcing Modern Navigation: A New Era of Splunk User Experience

We are excited to introduce the Modern Navigation feature in the Splunk Platform, available to both cloud and ...

Modernize your Splunk Apps – Introducing Python 3.13 in Splunk

We are excited to announce that the upcoming releases of Splunk Enterprise 10.2.x and Splunk Cloud Platform ...

Step into “Hunt the Insider: An Splunk ES Premier Mystery” to catch a cybercriminal ...

After a whole week of being on call, you fell asleep on your keyboard, and you hit a sequence of buttons that ...