<?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: How to get a regex setup to tell me whether a session was decrypted or not based on the proxy Palo Alto Decryption flag? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-regex-setup-to-tell-me-whether-a-session-was/m-p/345026#M102217</link>
    <description>&lt;P&gt;As @richgalloway said... use the app... Specifically the tech addon for Palo Alto: &lt;A href="https://splunkbase.splunk.com/app/2757/"&gt;https://splunkbase.splunk.com/app/2757/&lt;/A&gt; &lt;/P&gt;

&lt;P&gt;The field to determine if you decrypted a session is part of a bit wise field: &lt;A href="https://live.paloaltonetworks.com/t5/Management-Articles/How-to-Determine-if-Session-was-Decrypted-Based-on-Flags-in/ta-p/60515"&gt;https://live.paloaltonetworks.com/t5/Management-Articles/How-to-Determine-if-Session-was-Decrypted-Based-on-Flags-in/ta-p/60515&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;This means, that while you may be able to use a regex to extract the flag field itself, you're not going to be able to use a regex to interpret the flag to determine if the session was decrypted or not. Instead you'll need bit arithmetic. &lt;/P&gt;

&lt;P&gt;If we look at the transforms.conf of the tech addon, you'll see that they use delimiter based extractions instead of regular expressions to extract the field as &lt;CODE&gt;session_flags&lt;/CODE&gt;. They then in the props.conf use some math to convert the single &lt;CODE&gt;session_flags&lt;/CODE&gt; field into a multi-valued &lt;CODE&gt;flags&lt;/CODE&gt; field... this is &lt;CODE&gt;EVAL-flags&lt;/CODE&gt; in props.conf in the TA. &lt;/P&gt;

&lt;P&gt;The flag you're asking about in particular:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;if(floor(tonumber(session_flags,16) / pow(2, 24))%2==0,null(),"decrypted")
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;EDIT: And thanks to &lt;A href="https://answers.splunk.com/answering/236510/view.html"&gt;this answer&lt;/A&gt; by @martin_mueller I realize there's a bug in that line in the TA, and we need to add a %2 into it... so updated.&lt;/P&gt;

&lt;P&gt;And issue logged with the TA: &lt;A href="https://github.com/PaloAltoNetworks/Splunk_TA_paloalto/issues/17"&gt;https://github.com/PaloAltoNetworks/Splunk_TA_paloalto/issues/17&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Sun, 04 Feb 2018 20:07:38 GMT</pubDate>
    <dc:creator>acharlieh</dc:creator>
    <dc:date>2018-02-04T20:07:38Z</dc:date>
    <item>
      <title>How to get a regex setup to tell me whether a session was decrypted or not based on the proxy Palo Alto Decryption flag?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-regex-setup-to-tell-me-whether-a-session-was/m-p/345024#M102215</link>
      <description>&lt;P&gt;Hi all; so we are decrypting traffic via Palo Alto, but we aren't using the PA app for Splunk.  What I'm trying to figure out is how to get a regex setup to tell me a session was or was not decrypted based on the proxy flag.  Has anyone done that yet?&lt;/P&gt;</description>
      <pubDate>Fri, 02 Feb 2018 20:34:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-regex-setup-to-tell-me-whether-a-session-was/m-p/345024#M102215</guid>
      <dc:creator>coloradoark</dc:creator>
      <dc:date>2018-02-02T20:34:25Z</dc:date>
    </item>
    <item>
      <title>Re: How to get a regex setup to tell me whether a session was decrypted or not based on the proxy Palo Alto Decryption flag?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-regex-setup-to-tell-me-whether-a-session-was/m-p/345025#M102216</link>
      <description>&lt;P&gt;Why not use the app?&lt;BR /&gt;
If you'll post some sample events and the fields you want extracted from them, we can help craft a regex string or find some other way to get what you need.&lt;/P&gt;</description>
      <pubDate>Sun, 04 Feb 2018 19:21:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-regex-setup-to-tell-me-whether-a-session-was/m-p/345025#M102216</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2018-02-04T19:21:27Z</dc:date>
    </item>
    <item>
      <title>Re: How to get a regex setup to tell me whether a session was decrypted or not based on the proxy Palo Alto Decryption flag?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-regex-setup-to-tell-me-whether-a-session-was/m-p/345026#M102217</link>
      <description>&lt;P&gt;As @richgalloway said... use the app... Specifically the tech addon for Palo Alto: &lt;A href="https://splunkbase.splunk.com/app/2757/"&gt;https://splunkbase.splunk.com/app/2757/&lt;/A&gt; &lt;/P&gt;

&lt;P&gt;The field to determine if you decrypted a session is part of a bit wise field: &lt;A href="https://live.paloaltonetworks.com/t5/Management-Articles/How-to-Determine-if-Session-was-Decrypted-Based-on-Flags-in/ta-p/60515"&gt;https://live.paloaltonetworks.com/t5/Management-Articles/How-to-Determine-if-Session-was-Decrypted-Based-on-Flags-in/ta-p/60515&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;This means, that while you may be able to use a regex to extract the flag field itself, you're not going to be able to use a regex to interpret the flag to determine if the session was decrypted or not. Instead you'll need bit arithmetic. &lt;/P&gt;

&lt;P&gt;If we look at the transforms.conf of the tech addon, you'll see that they use delimiter based extractions instead of regular expressions to extract the field as &lt;CODE&gt;session_flags&lt;/CODE&gt;. They then in the props.conf use some math to convert the single &lt;CODE&gt;session_flags&lt;/CODE&gt; field into a multi-valued &lt;CODE&gt;flags&lt;/CODE&gt; field... this is &lt;CODE&gt;EVAL-flags&lt;/CODE&gt; in props.conf in the TA. &lt;/P&gt;

&lt;P&gt;The flag you're asking about in particular:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;if(floor(tonumber(session_flags,16) / pow(2, 24))%2==0,null(),"decrypted")
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;EDIT: And thanks to &lt;A href="https://answers.splunk.com/answering/236510/view.html"&gt;this answer&lt;/A&gt; by @martin_mueller I realize there's a bug in that line in the TA, and we need to add a %2 into it... so updated.&lt;/P&gt;

&lt;P&gt;And issue logged with the TA: &lt;A href="https://github.com/PaloAltoNetworks/Splunk_TA_paloalto/issues/17"&gt;https://github.com/PaloAltoNetworks/Splunk_TA_paloalto/issues/17&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 04 Feb 2018 20:07:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-get-a-regex-setup-to-tell-me-whether-a-session-was/m-p/345026#M102217</guid>
      <dc:creator>acharlieh</dc:creator>
      <dc:date>2018-02-04T20:07:38Z</dc:date>
    </item>
  </channel>
</rss>

