All Apps and Add-ons

Base64: Parsing an XML file using kv_mode=xml, how to get the Base64 script "recurse" and decode more than the first line?

lchumley
New Member

I'm parsing an XML file using the kv_mode=xml in my props.conf and that's all good and well.

However, these XMLs that are coming back as a payload from another app are formatted like this:

<host>PC11</host>
<Registry>
<Value>AbBccDlllK[...]</Value>
<Value>AbBccDQQqq[...]</Value>

In the Search app, the tables format correctly and I get multiple values per host. These values are on separate lines, but not being treated as separate events. I'm fine with that part.

The Values are in Base64. I downloaded the base64 app and ran a decode string against the source type and it worked, but only for the first value of every host. Any ideas on how to make the base64 script "recurse" and decode more than the first line?

0 Karma

jhedgpeth
Path Finder

something to try. split mv field, decode, recombine.

... | mvexpand yourbase64 | base64 field=yourbase64 action=“decode"  | mvcombine yourbase64
0 Karma
Get Updates on the Splunk Community!

Stay Connected: Your Guide to November Tech Talks, Office Hours, and Webinars!

&#x1f342; Fall into November with a fresh lineup of Community Office Hours, Tech Talks, and Webinars we’ve ...

Transform your security operations with Splunk Enterprise Security

Hi Splunk Community, Splunk Platform has set a great foundation for your security operations. With the ...

Splunk Admins and App Developers | Earn a $35 gift card!

Splunk, in collaboration with ESG (Enterprise Strategy Group) by TechTarget, is excited to announce a ...