<?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 Detecting different character sets in an email subject in Splunk Dev</title>
    <link>https://community.splunk.com/t5/Splunk-Dev/Detecting-different-character-sets-in-an-email-subject/m-p/438733#M7950</link>
    <description>&lt;P&gt;I want to report on emails containing subjects that are using difference character sets, such as Chinese, Russian, Greek alphabet, etc.&lt;/P&gt;

&lt;P&gt;Is there an easy way to pull out the character encoding from the emails?&lt;/P&gt;

&lt;P&gt;eg:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;Sender: someone@somewhere.com
Sender: 你好，世界
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Thu, 31 Jan 2019 15:32:55 GMT</pubDate>
    <dc:creator>sheamus69</dc:creator>
    <dc:date>2019-01-31T15:32:55Z</dc:date>
    <item>
      <title>Detecting different character sets in an email subject</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/Detecting-different-character-sets-in-an-email-subject/m-p/438733#M7950</link>
      <description>&lt;P&gt;I want to report on emails containing subjects that are using difference character sets, such as Chinese, Russian, Greek alphabet, etc.&lt;/P&gt;

&lt;P&gt;Is there an easy way to pull out the character encoding from the emails?&lt;/P&gt;

&lt;P&gt;eg:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;Sender: someone@somewhere.com
Sender: 你好，世界
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 31 Jan 2019 15:32:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/Detecting-different-character-sets-in-an-email-subject/m-p/438733#M7950</guid>
      <dc:creator>sheamus69</dc:creator>
      <dc:date>2019-01-31T15:32:55Z</dc:date>
    </item>
    <item>
      <title>Re: Detecting different character sets in an email subject</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/Detecting-different-character-sets-in-an-email-subject/m-p/438734#M7951</link>
      <description>&lt;P&gt;HI,&lt;/P&gt;

&lt;P&gt;its a bit bulky, but wouldn´t it be working if you use your regex to find everything except chracters you have in your charset?&lt;/P&gt;

&lt;P&gt;like&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[^:.@,\s+\w+]
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This is matching the chinese characters&lt;/P&gt;

&lt;P&gt;OR&lt;/P&gt;

&lt;P&gt;And at least for chinese there is a method to match all chracters with &lt;CODE&gt;\p{Han}&lt;/CODE&gt;. Seems to work in splunk. &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| makeresults | eval aaa="世界" | rex field=aaa (?&amp;lt;my_aaa&amp;gt;\p{Han}.*)
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 31 Jan 2019 16:16:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/Detecting-different-character-sets-in-an-email-subject/m-p/438734#M7951</guid>
      <dc:creator>dkeck</dc:creator>
      <dc:date>2019-01-31T16:16:06Z</dc:date>
    </item>
    <item>
      <title>Re: Detecting different character sets in an email subject</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/Detecting-different-character-sets-in-an-email-subject/m-p/438735#M7952</link>
      <description>&lt;P&gt;That was an interesting approach I hadn't considered.  The problem I am finding is that there seem to be lots of edge cases, such as é, í, !, ", £, $, %, ... I keep going back and finding more to exclude.&lt;/P&gt;

&lt;P&gt;Not sure if this is the best way to do it, or if theres an alternate approach? &lt;/P&gt;</description>
      <pubDate>Thu, 31 Jan 2019 17:12:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/Detecting-different-character-sets-in-an-email-subject/m-p/438735#M7952</guid>
      <dc:creator>sheamus69</dc:creator>
      <dc:date>2019-01-31T17:12:19Z</dc:date>
    </item>
    <item>
      <title>Re: Detecting different character sets in an email subject</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/Detecting-different-character-sets-in-an-email-subject/m-p/438736#M7953</link>
      <description>&lt;P&gt;I found a List of all languages here :&lt;/P&gt;

&lt;P&gt;&lt;A href="https://www.regular-expressions.info/unicode.html#prop"&gt;https://www.regular-expressions.info/unicode.html#prop&lt;/A&gt; scroll down to Unicode Scripts and Unicode Blocks.&lt;/P&gt;

&lt;P&gt;You could use &lt;CODE&gt;[^\p{Latin}]&lt;/CODE&gt;, since everything you are looking for is non latin?!&lt;/P&gt;

&lt;P&gt;I think thats the closest you can get, by using the rex above &lt;/P&gt;</description>
      <pubDate>Thu, 31 Jan 2019 17:25:11 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/Detecting-different-character-sets-in-an-email-subject/m-p/438736#M7953</guid>
      <dc:creator>dkeck</dc:creator>
      <dc:date>2019-01-31T17:25:11Z</dc:date>
    </item>
    <item>
      <title>Re: Detecting different character sets in an email subject</title>
      <link>https://community.splunk.com/t5/Splunk-Dev/Detecting-different-character-sets-in-an-email-subject/m-p/438737#M7954</link>
      <description>&lt;P&gt;Would be great if you could accept and upvote the question, thank you &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 01 Feb 2019 05:22:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Dev/Detecting-different-character-sets-in-an-email-subject/m-p/438737#M7954</guid>
      <dc:creator>dkeck</dc:creator>
      <dc:date>2019-02-01T05:22:22Z</dc:date>
    </item>
  </channel>
</rss>

