<?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 How to extract a field from my raw data using rex? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594473#M206906</link>
    <description>&lt;P&gt;Below is my raw logs.&lt;/P&gt;
&lt;P&gt;I want to extract "analystVerdict" &amp;amp; its corresponding result from raw logs. can someone please help&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;\"mitigationStartedAt\": \"2022-04-13T03:57:58.393000Z\", \"status\": \"success\"}], \"threatInfo\": {\"&lt;STRONG&gt;analystVerdict&lt;/STRONG&gt;\": \"&lt;STRONG&gt;false_positive&lt;/STRONG&gt;\", \"analystVerdictDescription\": \"False positive\", \"automaticallyResolved\": false, \"browserType\": null, \"certificateId\": \"\", \"classification\": \"Malware\",&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I tried below. But i am failing to get the result&lt;/P&gt;
&lt;P&gt;index=test_summary&amp;nbsp; | rex field=_raw ":\\\"(?&amp;lt;analystVerdict&amp;gt;\w+)\\\"" |table search_name analystVerdict&lt;/P&gt;</description>
    <pubDate>Wed, 20 Apr 2022 15:27:33 GMT</pubDate>
    <dc:creator>alexspunkshell</dc:creator>
    <dc:date>2022-04-20T15:27:33Z</dc:date>
    <item>
      <title>How to extract a field from my raw data using rex?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594473#M206906</link>
      <description>&lt;P&gt;Below is my raw logs.&lt;/P&gt;
&lt;P&gt;I want to extract "analystVerdict" &amp;amp; its corresponding result from raw logs. can someone please help&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;\"mitigationStartedAt\": \"2022-04-13T03:57:58.393000Z\", \"status\": \"success\"}], \"threatInfo\": {\"&lt;STRONG&gt;analystVerdict&lt;/STRONG&gt;\": \"&lt;STRONG&gt;false_positive&lt;/STRONG&gt;\", \"analystVerdictDescription\": \"False positive\", \"automaticallyResolved\": false, \"browserType\": null, \"certificateId\": \"\", \"classification\": \"Malware\",&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I tried below. But i am failing to get the result&lt;/P&gt;
&lt;P&gt;index=test_summary&amp;nbsp; | rex field=_raw ":\\\"(?&amp;lt;analystVerdict&amp;gt;\w+)\\\"" |table search_name analystVerdict&lt;/P&gt;</description>
      <pubDate>Wed, 20 Apr 2022 15:27:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594473#M206906</guid>
      <dc:creator>alexspunkshell</dc:creator>
      <dc:date>2022-04-20T15:27:33Z</dc:date>
    </item>
    <item>
      <title>Re: Extract a field from my raw data using rex</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594476#M206907</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/126376"&gt;@alexspunkshell&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;please try this regex:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| rex "analystVerdictDescription\\\":\s+\\\"(?&amp;lt;analystVerdictDescription&amp;gt;[^\"]+)"&lt;/LI-CODE&gt;&lt;P&gt;that you can test at&amp;nbsp;&lt;A href="https://regex101.com/r/IjwJYM/1" target="_blank"&gt;https://regex101.com/r/IjwJYM/1&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Wed, 20 Apr 2022 15:16:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594476#M206907</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2022-04-20T15:16:22Z</dc:date>
    </item>
    <item>
      <title>Re: Extract a field from my raw data using rex</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594482#M206908</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/161352"&gt;@gcusello&lt;/a&gt;&amp;nbsp; Thanks for your help&lt;/P&gt;&lt;P&gt;I tried but the field is empty in my results. But the raw logs is having the values.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="alexspunkshell_0-1650469176646.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/19154i0B865486AA3E02A4/image-size/medium?v=v2&amp;amp;px=400" role="button" title="alexspunkshell_0-1650469176646.png" alt="alexspunkshell_0-1650469176646.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 20 Apr 2022 15:39:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594482#M206908</guid>
      <dc:creator>alexspunkshell</dc:creator>
      <dc:date>2022-04-20T15:39:52Z</dc:date>
    </item>
    <item>
      <title>Re: Extract a field from my raw data using rex</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594483#M206909</link>
      <description>If you really have that \ as an escape character on your data, you should add could of more \ character on your rex. There reason is that internally there are couple of places where splunk do that de-escaping and for that reason sometimes you need to do it double or triple times.</description>
      <pubDate>Wed, 20 Apr 2022 15:38:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594483#M206909</guid>
      <dc:creator>isoutamo</dc:creator>
      <dc:date>2022-04-20T15:38:42Z</dc:date>
    </item>
    <item>
      <title>Re: Extract a field from my raw data using rex</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594489#M206912</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/126376"&gt;@alexspunkshell&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;sometimes I found a behaviour in Splunk different than regex101, so please try this:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| rex "analystVerdictDescription\\\\":\s+\\\\"(?&amp;lt;analystVerdictDescription&amp;gt;[^\"]+)"&lt;/LI-CODE&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Wed, 20 Apr 2022 15:45:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594489#M206912</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2022-04-20T15:45:15Z</dc:date>
    </item>
    <item>
      <title>Re: Extract a field from my raw data using rex</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594491#M206913</link>
      <description>&lt;P&gt;Still the same&lt;/P&gt;</description>
      <pubDate>Wed, 20 Apr 2022 15:48:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594491#M206913</guid>
      <dc:creator>alexspunkshell</dc:creator>
      <dc:date>2022-04-20T15:48:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to extract a field from my raw data using rex?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594494#M206915</link>
      <description>&lt;LI-CODE lang="markup"&gt;| rex "analystVerdict\\\\\":\s+\\\\\"(?&amp;lt;analystVerdictDescription&amp;gt;[^\\\\\"]+)"&lt;/LI-CODE&gt;</description>
      <pubDate>Wed, 20 Apr 2022 15:54:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-extract-a-field-from-my-raw-data-using-rex/m-p/594494#M206915</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-04-20T15:54:03Z</dc:date>
    </item>
  </channel>
</rss>

