<?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: Problem with HEADER_FIELD_REGEX in TMG Logs in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Problem-with-HEADER-FIELD-REGEX-in-TMG-Logs/m-p/153075#M185598</link>
    <description>&lt;P&gt;I will definitely give this a shot, but I will not have access to the environment until the end of next month, so I can't be sure just yet. Thanks!&lt;/P&gt;</description>
    <pubDate>Thu, 30 Jan 2014 17:34:43 GMT</pubDate>
    <dc:creator>delink</dc:creator>
    <dc:date>2014-01-30T17:34:43Z</dc:date>
    <item>
      <title>Problem with HEADER_FIELD_REGEX in TMG Logs</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Problem-with-HEADER-FIELD-REGEX-in-TMG-Logs/m-p/153071#M185594</link>
      <description>&lt;P&gt;I am attempting to use the INDEXED_EXTRACTION = W3C configuration to pull logs from a Microsoft TMG server. I started with the isamonitor app that exists for ISA 2006 and built a new sourcetype on top of it for the TMG logs called tmgwebw3c (based on isawebw3c). The header of the W3C log looks as follows, with the fields line containing tab-separated values as does the data itself:&lt;/P&gt;

&lt;PRE&gt;
#Software: Microsoft Forefront Threat Management Gateway
#Version: 2.0
#Date: 2013-11-22 15:26:48
#Fields: c-ip   cs-username     c-agent date    time    s-computername  cs-referred     r-host  r-ip
    r-port  time-taken      sc-bytes        cs-bytes        cs-protocol     s-operation     cs-uri  cs-mime-type    s-object-source sc-status       rule    FilterInfo      cs-network      sc-network
      error-info      action  AuthenticationServer    NIS scan result NIS signature   ThreatName
      MalwareInspectionAction MalwareInspectionResult UrlCategory     MalwareInspectionContentDeliveryMethod  MalwareInspectionDuration       MalwareInspectionThreatLevel    internal-service-info   NIS application protocol        NAT address     UrlCategorizationReason SessionType     UrlDestHost     s-port  SoftBlockAction
&lt;/PRE&gt;

&lt;P&gt;Using the documentation at &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.0/Data/Extractfieldsfromfileheadersatindextime" target="_blank"&gt;http://docs.splunk.com/Documentation/Splunk/6.0/Data/Extractfieldsfromfileheadersatindextime&lt;/A&gt; I built a sourcetype that looks as follows:&lt;/P&gt;

&lt;PRE&gt;
[tmgwebw3c]
MAX_TIMESTAMP_LOOKAHEAD = 32
SHOULD_LINEMERGE = false
REPORT-tmgwebw3c = tmgwebw3c
TZ = GMT
INDEXED_EXTRACTIONS = W3C
FIELD_HEADER_REGEX = ^#Fields:
PREAMBLE_REGEX = ^#\w+: 
FIELD_DELIMITER = \t
&lt;/PRE&gt;

&lt;P&gt;Everything appears to be working well, but for the very first field, it is being named "Fields_c_ip" rather than the expected "c_ip". Based on the documentation, FIELD_HEADER_REGEX should not include the matched portion as part of the header line, but it seems to be doing so anyhow.&lt;/P&gt;

&lt;P&gt;I tried to remove the PREAMBLE_REGEX also in case they were conflicting, but this did not solve the issue. Any assistance with this would be appreciated.&lt;/P&gt;

&lt;P&gt;-- &lt;BR /&gt;
Brian T Glenn&lt;BR /&gt;
Hurricane Labs&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 15:21:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Problem-with-HEADER-FIELD-REGEX-in-TMG-Logs/m-p/153071#M185594</guid>
      <dc:creator>delink</dc:creator>
      <dc:date>2020-09-28T15:21:07Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with HEADER_FIELD_REGEX in TMG Logs</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Problem-with-HEADER-FIELD-REGEX-in-TMG-Logs/m-p/153072#M185595</link>
      <description>&lt;P&gt;Hi Brian,&lt;/P&gt;

&lt;P&gt;Did you try just:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;INDEXED_EXTRACTIONS = W3C  
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Without any other settings? This actually sets the following under the covers:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;FIELD_DELIMITER = whitespace
FIELD_HEADER_REGEX = ^#Fields:\\s*(.*)
MISSING_VALUE_REGEX = -
TIME_FORMAT = %Y-%m-%d %H:%M:%S
TZ = GMT
TIMESTAMP_FIELDS = date,time
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;We did have some trouble with tabs and spaces in Internet Security and Acceleration Server and I'm wondering if we'll see the same problems here.&lt;/P&gt;</description>
      <pubDate>Thu, 12 Dec 2013 18:41:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Problem-with-HEADER-FIELD-REGEX-in-TMG-Logs/m-p/153072#M185595</guid>
      <dc:creator>ogdin</dc:creator>
      <dc:date>2013-12-12T18:41:34Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with HEADER_FIELD_REGEX in TMG Logs</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Problem-with-HEADER-FIELD-REGEX-in-TMG-Logs/m-p/153073#M185596</link>
      <description>&lt;P&gt;My props.conf settings that works with this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[w3c_tab]
FIELD_DELIMITER=tab
FIELD_HEADER_REGEX=^#Fields:\s*(.*)
MISSING_VALUE_REGEX=-
TIME_FORMAT=%Y-%m-%d %H:%M:%S
TZ=GMT
TIMESTAMP_FIELDS=date,time
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Note I had accidentally escaped the \s in FIELD_HEADER_REGEX &lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 15:46:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Problem-with-HEADER-FIELD-REGEX-in-TMG-Logs/m-p/153073#M185596</guid>
      <dc:creator>ogdin</dc:creator>
      <dc:date>2020-09-28T15:46:35Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with HEADER_FIELD_REGEX in TMG Logs</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Problem-with-HEADER-FIELD-REGEX-in-TMG-Logs/m-p/153074#M185597</link>
      <description>&lt;P&gt;I will definitely give this a shot, but I will not have access to the environment until the end of next month, so I can't be sure just yet. Thanks!&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jan 2014 17:34:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Problem-with-HEADER-FIELD-REGEX-in-TMG-Logs/m-p/153074#M185597</guid>
      <dc:creator>delink</dc:creator>
      <dc:date>2014-01-30T17:34:34Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with HEADER_FIELD_REGEX in TMG Logs</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Problem-with-HEADER-FIELD-REGEX-in-TMG-Logs/m-p/153075#M185598</link>
      <description>&lt;P&gt;I will definitely give this a shot, but I will not have access to the environment until the end of next month, so I can't be sure just yet. Thanks!&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jan 2014 17:34:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Problem-with-HEADER-FIELD-REGEX-in-TMG-Logs/m-p/153075#M185598</guid>
      <dc:creator>delink</dc:creator>
      <dc:date>2014-01-30T17:34:43Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with HEADER_FIELD_REGEX in TMG Logs</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Problem-with-HEADER-FIELD-REGEX-in-TMG-Logs/m-p/153076#M185599</link>
      <description>&lt;P&gt;Turns out this is going to be fixed post-6.0.2. Nothing to do in the configuration itself.&lt;/P&gt;</description>
      <pubDate>Wed, 26 Feb 2014 16:17:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Problem-with-HEADER-FIELD-REGEX-in-TMG-Logs/m-p/153076#M185599</guid>
      <dc:creator>delink</dc:creator>
      <dc:date>2014-02-26T16:17:24Z</dc:date>
    </item>
  </channel>
</rss>

