Skip to content
This repository has been archived by the owner on Dec 14, 2024. It is now read-only.

Broken field alias for src in sourcetype=pan:firewall_cloud #220

Closed
cramasta opened this issue Oct 7, 2021 · 2 comments · Fixed by #257
Closed

Broken field alias for src in sourcetype=pan:firewall_cloud #220

cramasta opened this issue Oct 7, 2021 · 2 comments · Fixed by #257

Comments

@cramasta
Copy link

cramasta commented Oct 7, 2021

For the sourcetype=pan:firewall_cloud the src field does not appear in the list of fields.

The data format is JSON so Splunk automatically extracts the field named SourceAddress

The TA then has two field aliases settings in props.conf that operate in this order

  1. FIELDALIAS-fwcloud_src = SourceAddress as src <- this creates the src field alias

  2. FIELDALIAS-src_for_pan_cloud = src_ip as src <-this tries to create a field alias of src from the src_ip field, but src_ip field does not exist. Since it doesn't exist and the default setting for a field alias is to overwrite the alias value this causes splunk to REMOVE the src field

  3. EVAL-src_ip = coalesce(SourceAddress, PublicIPv4) < - we than have this eval to create a field called src_ip by coalescing two other fields together. BUT hey didnt you say in step 2 that src_ip didnt exist?! Thats correct because EVAL's occur AFTER FIELDALIAS so at the time the field aliases operated it src_ip did not exist at that time.

My guess is that the field aliases worked previously and did what was intended prior to a update in Splunk 7.2.4 in how field alias's work. Prior to 7.2.4 Splunk would have NOT removed the field alias in step 2 even though scr_ip didnt exist.

more here on the field alias change
https://docs.splunk.com/Documentation/Splunk/8.2.2/ReleaseNotes/Fieldaliasbehaviorchange#:~:text=4%2B%20of%20Splunk%20Enterprise%2C%20the,events%20that%20contain%20that%20field.

Im not sure what the intent was for creating the src field so I dont want to suggest what the proper fix is as there are many ways one could go about fixing this. However a quick fix to at least get step 1's alias working is to uncheck the OVERWRITE Values setting in the FIELDALIAS-src_for_pan_cloud config

@welcome-to-palo-alto-networks
Copy link

🎉 Thanks for opening your first issue here! Welcome to the community!

as3923 added a commit to as3923/Splunk-Apps that referenced this issue May 9, 2022
@as3923 as3923 mentioned this issue May 9, 2022
4 tasks
@btorresgil btorresgil linked a pull request Oct 7, 2022 that will close this issue
4 tasks
@jacobappleton-orbis
Copy link

Thanks @cramasta - I just ran into the same issue and this helped.

paulmnguyen pushed a commit that referenced this issue Apr 1, 2024
Update Props.conf (#257)
Resolve issue #220

* fix(addon): Change fwcloud src to EVAL and remove fwcloud dest alias

---------

Co-authored-by: Brian Torres-Gil <btorres-gil@paloaltonetworks.com>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants