<?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: data masking not working in Deployment Architecture</title>
    <link>https://community.splunk.com/t5/Deployment-Architecture/data-masking-not-working/m-p/310927#M21361</link>
    <description>&lt;P&gt;Hi Prakhar_shukla,&lt;BR /&gt;
do you want to mask your AcctlID in the data before indexing ?&lt;BR /&gt;
in this case you should insert in your props.conf at first a stanza with sourcetype and not with source (I found problems with sources or hosts) and after you should modify your regex in SEDCMD command&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[your_sourcetype]
SEDCMD-1acct = s/AcctID\=\d+/AcctID\=XXXXXXXXXX/g 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Bye.&lt;BR /&gt;
Giuseppe&lt;/P&gt;</description>
    <pubDate>Wed, 05 Apr 2017 11:35:57 GMT</pubDate>
    <dc:creator>gcusello</dc:creator>
    <dc:date>2017-04-05T11:35:57Z</dc:date>
    <item>
      <title>data masking not working</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/data-masking-not-working/m-p/310925#M21359</link>
      <description>&lt;P&gt;this is the log file&lt;/P&gt;

&lt;P&gt;bash-4.2$ more mask.log .( static log file for testing. added it via input file monitoring from web for index idx1)&lt;BR /&gt;
123456789123456789&lt;BR /&gt;
[05/Apr/2017:00:02:48:21]       VendorID=9112   Code=B1 AcctID=4902343983&lt;BR /&gt;
[05/Apr/2017:00:03:48:21]       VendorID=9113   Code=B2 AcctID=4902343983&lt;/P&gt;

&lt;P&gt;here is my props.conf in /local/&lt;/P&gt;

&lt;P&gt;bash-4.2$ more props.conf&lt;BR /&gt;
[mask.log]&lt;BR /&gt;
SEDCMD-1acct = s/AcctID=...../AcctID=XXXXX/g&lt;/P&gt;

&lt;P&gt;when i am searching for the index, i am getting unmasked log file, masking is just not working&lt;/P&gt;

&lt;P&gt;please help out.&lt;/P&gt;</description>
      <pubDate>Wed, 05 Apr 2017 11:13:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/data-masking-not-working/m-p/310925#M21359</guid>
      <dc:creator>Prakhar_shukla</dc:creator>
      <dc:date>2017-04-05T11:13:05Z</dc:date>
    </item>
    <item>
      <title>Re: data masking not working</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/data-masking-not-working/m-p/310926#M21360</link>
      <description>&lt;P&gt;here i am trying to mask 1st 5 number from AcctID. mask.log file is in /tmp/ fold.&lt;/P&gt;</description>
      <pubDate>Wed, 05 Apr 2017 11:28:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/data-masking-not-working/m-p/310926#M21360</guid>
      <dc:creator>Prakhar_shukla</dc:creator>
      <dc:date>2017-04-05T11:28:46Z</dc:date>
    </item>
    <item>
      <title>Re: data masking not working</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/data-masking-not-working/m-p/310927#M21361</link>
      <description>&lt;P&gt;Hi Prakhar_shukla,&lt;BR /&gt;
do you want to mask your AcctlID in the data before indexing ?&lt;BR /&gt;
in this case you should insert in your props.conf at first a stanza with sourcetype and not with source (I found problems with sources or hosts) and after you should modify your regex in SEDCMD command&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[your_sourcetype]
SEDCMD-1acct = s/AcctID\=\d+/AcctID\=XXXXXXXXXX/g 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Bye.&lt;BR /&gt;
Giuseppe&lt;/P&gt;</description>
      <pubDate>Wed, 05 Apr 2017 11:35:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/data-masking-not-working/m-p/310927#M21361</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2017-04-05T11:35:57Z</dc:date>
    </item>
    <item>
      <title>Re: data masking not working</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/data-masking-not-working/m-p/310928#M21362</link>
      <description>&lt;P&gt;Your configuration is correct to mask the first 4 digits and you can see this like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;|makeresults | eval raw="VendorID=9112 Code=B1 AcctID=4902343983"
| rename raw AS _raw
| rex mode=sed "s/AcctID=...../AcctID=XXXXX/g"
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;You need to deploy this to &lt;CODE&gt;props.conf&lt;/CODE&gt; but first fix your stanza header.  I doubt that your &lt;CODE&gt;sourctype&lt;/CODE&gt; is &lt;CODE&gt;mask.log&lt;/CODE&gt;  Check your &lt;CODE&gt;inputs.conf&lt;/CODE&gt; and find out what you set &lt;CODE&gt;sourcetype&lt;/CODE&gt; to and use that or, if you need to use &lt;CODE&gt;source&lt;/CODE&gt;, then use this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[source::mask.log]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Deploy to your Indexers (or HFs), restart splunk there and verify on NEW events (old events will stay broken).&lt;/P&gt;</description>
      <pubDate>Wed, 05 Apr 2017 14:01:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/data-masking-not-working/m-p/310928#M21362</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2017-04-05T14:01:23Z</dc:date>
    </item>
    <item>
      <title>Re: data masking not working</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/data-masking-not-working/m-p/310929#M21363</link>
      <description>&lt;P&gt;Did you try this?  Did it work?&lt;/P&gt;</description>
      <pubDate>Wed, 05 Apr 2017 18:36:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/data-masking-not-working/m-p/310929#M21363</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2017-04-05T18:36:47Z</dc:date>
    </item>
    <item>
      <title>Re: data masking not working</title>
      <link>https://community.splunk.com/t5/Deployment-Architecture/data-masking-not-working/m-p/310930#M21364</link>
      <description>&lt;P&gt;thanks cusello, woodcock. yes it worked after replacing source with sourcetype.&lt;/P&gt;</description>
      <pubDate>Thu, 06 Apr 2017 03:45:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Deployment-Architecture/data-masking-not-working/m-p/310930#M21364</guid>
      <dc:creator>Prakhar_shukla</dc:creator>
      <dc:date>2017-04-06T03:45:42Z</dc:date>
    </item>
  </channel>
</rss>

