Unique Files From File Object

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Announcements

Unique Files From File Object

L1 Bithead

Dear All,

I am currently optimizing the phishing playbook and have encountered some issues with the detonation and enrichment processes that handle file objects. I noticed that duplicate files are being passed to the sub-playbooks. I attempted to use a unique function to filter out these duplicates, but it didn't work as expected. I have two files with duplicate entries

TSOARSupport_0-1724837317574.png

Cortex XSOAR #playbook 

1 REPLY 1

L1 Bithead

Hi,
Maybe you can make use of DT language. The value below printing the entry ids with unique names

${.=(val.File instanceof Array ? Array.from(new Map(val.File.map(file => [file.Name, file.EntryID])).values()).join(", ") : val.File.EntryID)}

  • 332 Views
  • 1 replies
  • 0 Likes
Like what you see?

Show your appreciation!

Click Like if a post is helpful to you or if you just want to show your support.

Click Accept as Solution to acknowledge that the answer to your question has been provided.

The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!

These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!

The LIVEcommunity thanks you for your participation!