Splunk Search

Masking an email address at the search head level

joe06031990
Communicator
  • Good afternoon,
  • I am trying to Masking an email address at the search head level I have tried using Rex and sed but can’t get it to work, does anyone have any examples?
  •  
  • thanks 
  •  
  • Joe 
  •  
Labels (2)
Tags (1)
0 Karma

to4kawa
Ultra Champion

https://community.splunk.com/t5/Getting-Data-In/Anonymize-data-from-JSON-File/td-p/502195?childToVie...

how about my updated answer? or

| makeresults
| eval _raw="2020-07-06 sender=foo@bar.com recipient=baz@bar.co.jp subject=\"test only\""
| rex mode=sed "s/[\w\-\.]+@[\w\-\.]+/XXXXX/g"
0 Karma

joe06031990
Communicator

Thanks for your reply, is their a regex I could use? As this is only at the search head level.

0 Karma

to4kawa
Ultra Champion

@joe06031990     I'm not sure what you say "search head level".

1. If you want to mask logs, see my link and try logic.

2. If you want to mask on dashboard, try rex

0 Karma
Get Updates on the Splunk Community!

Your Guide to Splunk Digital Experience Monitoring

A flawless digital experience isn't just an advantage, it's key to customer loyalty and business success. But ...

Data Management Digest – November 2025

  Welcome to the inaugural edition of Data Management Digest! As your trusted partner in data innovation, the ...

Upcoming Webinar: Unmasking Insider Threats with Slunk Enterprise Security’s UEBA

Join us on Wed, Dec 10. at 10AM PST / 1PM EST for a live webinar and demo with Splunk experts! Discover how ...