<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Stats / Eval to find results of email recipients who clicked a link in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/What-stats-eval-to-use-to-find-results-of-email-recipients-who/m-p/634610#M220469</link>
    <description>&lt;P&gt;Assuming your recipient field is called recipient, try something like this&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| stats earliest(time) AS First_Seen, latest(time) AS Last_Seen count(eval(eventType="clicksPermitted")) AS Clicks_Permitted, count(eval(eventType="clicksBlocked")) AS Clicks_Blocked, values(eval(if(eventType=="clicksPermitted",recipient,null()))) as recipients values(threatURL) AS TAP_Link BY sender, classification, url&lt;/LI-CODE&gt;</description>
    <pubDate>Wed, 15 Mar 2023 15:24:26 GMT</pubDate>
    <dc:creator>ITWhisperer</dc:creator>
    <dc:date>2023-03-15T15:24:26Z</dc:date>
    <item>
      <title>What stats/eval to use to find results of email recipients who clicked a link?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/What-stats-eval-to-use-to-find-results-of-email-recipients-who/m-p/634609#M220468</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;I'm building a report to list all phishing and malware threat detections by sender, classification, and threat url. The data contains two types of events "clicksAllowed" and "clicksBlocked". I want to add a list of recipients if their click was allowed "clicksAllowed" and I'm struggling with how to structure my query. I'm currently trying to do this with stats and eval (I thought about using subsearch too maybe), hopefully, I'm on the right track but I can't figure out how to show only the recipients who clicked while still showing counts of how many clicks were allowed and blocked.&lt;/P&gt;
&lt;P&gt;Current search (without who clicked):&lt;/P&gt;
&lt;P&gt;index=tap sourcetype="pp_tap_siem" classification IN (phish, malware) threatStatus=active&lt;BR /&gt;| eval time=strftime(_time,"%m/%d/%y @ %H:%M:%S")&lt;BR /&gt;| stats earliest(time) AS First_Seen, latest(time) AS Last_Seen count(eval(eventType="clicksPermitted")) AS Clicks_Permitted, count(eval(eventType="clicksBlocked")) AS Clicks_Blocked, values(threatURL) AS TAP_Link BY sender, classification, url&lt;BR /&gt;| table First_Seen, Last_Seen, classification, sender, Clicks_Permitted, Clicks_Blocked, AT_Risk_Users, url, TAP_Link&lt;BR /&gt;| sort -Last_Seen&lt;/P&gt;
&lt;P&gt;Output looks like:&lt;/P&gt;
&lt;TABLE border="1" width="100%"&gt;
&lt;TBODY&gt;
&lt;TR&gt;
&lt;TD width="11.11111111111111%"&gt;First_Seen&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;Last_Seen&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;classification&lt;/TD&gt;
&lt;TD width="5.426900584795321%"&gt;sender&lt;/TD&gt;
&lt;TD width="16.795321637426902%"&gt;Clicks_Permitted&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;Clicks_Blocked&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;&amp;nbsp;AT_Risk_Users&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;url&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;TAP_Link&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="11.11111111111111%"&gt;&lt;SPAN&gt;03/14/23 @ 17:52:36&lt;/SPAN&gt;&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;&lt;SPAN&gt;03/14/23 @ 17:52:36&lt;/SPAN&gt;&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;&lt;SPAN&gt;phish&lt;/SPAN&gt;&lt;/TD&gt;
&lt;TD width="5.426900584795321%"&gt;badguy@domain.com&lt;/TD&gt;
&lt;TD width="16.795321637426902%"&gt;1&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;1&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;list of 1 person here&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;hxxp://baddomain.com&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;hxxp://link_tothreatintel_webportal.com/uniqueguid&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="11.11111111111111%"&gt;&lt;SPAN&gt;01/05/23 @ 12:34:44&lt;/SPAN&gt;&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;&lt;SPAN&gt;01/05/23 @ 17:44:41&lt;/SPAN&gt;&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;&lt;SPAN&gt;phish&lt;/SPAN&gt;&lt;/TD&gt;
&lt;TD width="5.426900584795321%"&gt;badguy2@domain.com&lt;/TD&gt;
&lt;TD width="16.795321637426902%"&gt;39&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;3&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;list of 39 people here&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;hxxp://baddomain2.com&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;hxxp://link_tothreatintel_webportal.com/uniqueguid&lt;/TD&gt;
&lt;/TR&gt;
&lt;TR&gt;
&lt;TD width="11.11111111111111%"&gt;&lt;SPAN&gt;01/18/23 @ 15:43:20&lt;/SPAN&gt;&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;&lt;SPAN&gt;02/16/23 @ 22:46:19&lt;/SPAN&gt;&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;malware&lt;/TD&gt;
&lt;TD width="5.426900584795321%"&gt;badguy3@domain.com&lt;/TD&gt;
&lt;TD width="16.795321637426902%"&gt;4&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;0&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;list of 4 people here&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;hxxp://baddomain.com&lt;/TD&gt;
&lt;TD width="11.11111111111111%"&gt;hxxp://link_tothreatintel_webportal.com/uniqueguid&lt;/TD&gt;
&lt;/TR&gt;
&lt;/TBODY&gt;
&lt;/TABLE&gt;</description>
      <pubDate>Wed, 15 Mar 2023 18:28:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/What-stats-eval-to-use-to-find-results-of-email-recipients-who/m-p/634609#M220468</guid>
      <dc:creator>0p3r4t0r8089</dc:creator>
      <dc:date>2023-03-15T18:28:48Z</dc:date>
    </item>
    <item>
      <title>Re: Stats / Eval to find results of email recipients who clicked a link</title>
      <link>https://community.splunk.com/t5/Splunk-Search/What-stats-eval-to-use-to-find-results-of-email-recipients-who/m-p/634610#M220469</link>
      <description>&lt;P&gt;Assuming your recipient field is called recipient, try something like this&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| stats earliest(time) AS First_Seen, latest(time) AS Last_Seen count(eval(eventType="clicksPermitted")) AS Clicks_Permitted, count(eval(eventType="clicksBlocked")) AS Clicks_Blocked, values(eval(if(eventType=="clicksPermitted",recipient,null()))) as recipients values(threatURL) AS TAP_Link BY sender, classification, url&lt;/LI-CODE&gt;</description>
      <pubDate>Wed, 15 Mar 2023 15:24:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/What-stats-eval-to-use-to-find-results-of-email-recipients-who/m-p/634610#M220469</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2023-03-15T15:24:26Z</dc:date>
    </item>
    <item>
      <title>Re: Stats / Eval to find results of email recipients who clicked a link</title>
      <link>https://community.splunk.com/t5/Splunk-Search/What-stats-eval-to-use-to-find-results-of-email-recipients-who/m-p/634621#M220476</link>
      <description>&lt;P&gt;Thanks,&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;! That's exactly what I needed!&lt;/P&gt;</description>
      <pubDate>Wed, 15 Mar 2023 16:31:10 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/What-stats-eval-to-use-to-find-results-of-email-recipients-who/m-p/634621#M220476</guid>
      <dc:creator>0p3r4t0r8089</dc:creator>
      <dc:date>2023-03-15T16:31:10Z</dc:date>
    </item>
  </channel>
</rss>

