Rule Filter Information

Antwort erstellen

Bestätigungscode
Gib den Code genau so ein, wie du ihn siehst; Groß- und Kleinschreibung wird nicht unterschieden.
Smilies
:D :) :( :o :shock: :? 8) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :wink: :!: :?: :idea: :arrow: :| :mrgreen:
BBCode ist eingeschaltet
[img] ist eingeschaltet
[flash] ist ausgeschaltet
[url] ist eingeschaltet
Smilies sind eingeschaltet
Die letzten Beiträge des Themas
   

Ansicht erweitern Die letzten Beiträge des Themas: Rule Filter Information

Re: Rule Filter Information

Beitrag von Quellcore » 14. Apr 2010, 04:23

boat_broker hat geschrieben:... but how do you get an email to the Virtual Servers Emial folder?

Btw:
Did you know you can easily save messages in the eml format directly from the Training Area and the Recycle Bin from within Spami :?:
save_as_eml.png
save_as_eml.png (46.58 KiB) 837-mal betrachtet


Regards,
Quellcore

Re: Rule Filter Information

Beitrag von Chactory » 6. Apr 2010, 11:15

Hi Mike and Quellcore!

Thanks to your explanation I have found the settings finally. :) Unfurtunately, I haven't got enough time to test the program extensively, but I will care about that in the next weeks.

Regards, Chactory

Re: Rule Filter Information

Beitrag von boat_broker » 6. Apr 2010, 05:53

Hello Chactory,

I haven't used QuickREg much but to answer your question, go to the bottom of the main page and click on "global settings" (circled in green below). That opens the Global Settings options. Quellcore suggested selecting the "ORO Perl Flags" "Case insensitive" box (circled in red below) to best emulate Spami's RegEX engine.

Bild

Hope this helps,
Mike

Re: Rule Filter Information

Beitrag von Quellcore » 3. Apr 2010, 14:43

Hello boat_broker!

What a bummer :shock:

Try to do this:
View the complete Mail including the Haeder (No idea how to do this in Outlook but you'll figure it out ;-) )
Then save as a text file, which should be the same as the eml format, you just have to rename the extension from text to eml.

Regards,
Quellcore

Re: Rule Filter Information

Beitrag von boat_broker » 3. Apr 2010, 06:48

Quellcore,

I haven't done much with QuickREx yet. I have been trying to get the Virtual Pop3 Server to work. I have gotten my Outlook to recognize it but how do you get an email to the Virtual Servers Emial folder? I tried to "save as" an email from outlook but there was no .eml extension option. Then I saved as htm and then went in to the folder and changed the extension to .eml. Evidently, that doesn't work. Any suggestions?

Thanks,
Mike

Re: Rule Filter Information

Beitrag von Chactory » 2. Apr 2010, 13:42

Hallo Quellcore!

Your help is still needed to get QuickREx to work ...

I still can't find the second of your advised settings ...

Clipboard-02.gif
Clipboard-02.gif (27.92 KiB) 870-mal betrachtet

Clipboard-04.gif
Clipboard-04.gif (61.39 KiB) 870-mal betrachtet

Kind regards, Chactory

Re: Rule Filter Information

Beitrag von Quellcore » 2. Apr 2010, 06:08

Chactory hat geschrieben:where can I find the Global Flags settings? I didn't success to find it since two days ... :wink:

You can also see it in my last screenshot, btw ...

@ Mike and Chactory:
Did you play with QuickREx yet? How do you like it, could you get used to it and disregard The Regex Coach?


Regards,
Quellcore

Re: Rule Filter Information

Beitrag von Quellcore » 1. Apr 2010, 12:16

Hallo Chactory!

at the very bottom, you might have to unfold "Global Flags" ;-)

Gruß
Quellcore

Re: Rule Filter Information

Beitrag von Chactory » 1. Apr 2010, 08:32

Hi Quellcore,

Quellcore hat geschrieben:Evaluating: ORO Perl 5
Global Flags: ORO Perl "Case Insensitive"
where can I find the Global Flags settings? I didn't success to find it since two days ... :wink:

Sincerely, Chactory

Re: Rule Filter Information

Beitrag von Quellcore » 1. Apr 2010, 03:45

boat_broker hat geschrieben:I downloaded the QuickREx program that you linked to and went to set it up. However, in the Global Flags section I found the check box for the "ORO Perl Flags (Case insensitive)" but not for "Jakarta ORO Perl". There is one for "Jakarta-Regexp Flags (Case insensitive) (Multiline)", is that what you were referring to?

Sorry for the confusion, i was still using the Plug-in in Eclipse which looks almost identical but not quite.

Evaluating: ORO Perl 5
Global Flags: ORO Perl "Case Insensitive"


Since you chose "ORO Perl 5" Evaluation only the "ORO Perl" Flags matter, all the others don't have any effect as long as "ORO Perl 5" Evaluation is selected.

Depending on what kind of RegEx i want to create i also enable "Multiline Mode" (ORO Perl of course), this is only important when you want to make use of the anchors "^" (Start of Line) and "$" (End of Line).
The Multiline Mode was perfect for your project, the empty subject with "RE:".
This way i was able to check all possinilities at the same time:
QuickREx_01.png
QuickREx_01.png (5.01 KiB) 1825-mal betrachtet

boat_broker hat geschrieben:Out of curiosity, how did you determine to select those two implementations?

I know Spami uses the boost.regex library which is documented very well.
Apparently you could compile boost.regex for three different regular expression syntax (so called "flavors" i believe), PERL, POSIX extended and POSIX Basic.
Now i looked at the Regular Expression Flavor Comparison Chart.
There a plenty of features that DO work in Spami that indicate it has to be PERL and cannot be POSIX.
I have done a lot of RegExps in Spami which make it very clear that the boost.regex was compiled with "Case Insensitive" enabled.
boat_broker hat geschrieben:Obviously, I'm going to have to send myself some emails. My RegEx seemed to be working in my Spami but maybe it was focused on something else. Like you mentioned, the two different RegEx engines give me different results.

There is a pretty quick and convenient way for testing Rules in Spamihilator:
  • Get Boris Kugelmeier's Virtual Pop3 Server (not developed anymore, but works and its free) <here>
  • Start the Program and adjust the Port if you have to
  • Click the "Anleitung" Button, you will find instruction even in english how set up an account in you mailclient that would connect to the virtual server through Spami and how to get the Testmails on the Server.
  • Click "Hochfahren" to turn the virtual server on and check mails for your virtual account.

Regards,
Quellcore

Re: Rule Filter Information

Beitrag von boat_broker » 31. Mär 2010, 18:19

Thanks Quellcore,

I downloaded the QuickREx program that you linked to and went to set it up. However, in the Global Flags section I found the check box for the "ORO Perl Flags (Case insensitive)" but not for "Jakarta ORO Perl". There is one for "Jakarta-Regexp Flags (Case insensitive) (Multiline)", is that what you were referring to?

Out of curiosity, how did you determine to select those two implementations?

Obviously, I'm going to have to send myself some emails. My RegEx seemed to be working in my Spami but maybe it was focused on something else. Like you mentioned, the two different RegEx engines give me different results.

Mike

Re: Rule Filter Information

Beitrag von Quellcore » 31. Mär 2010, 04:24

boat_broker hat geschrieben:I believe that you correctly identified my intent with \b[Rr][Ee]\b:\s\B. However, with the RegEx Coach VM it does seem to work. It recognizes "Re:" and "Re: " and "Re: " (a re followed by a tab). At the same time it passes "Re: boats" and "Re:boats". So far, all is good. I will let you know if I change anything and I will go back to my formula and try to explain my reasoning. I do need to review the "anchor" concept that you mentioned. I should also note that I came up with this as an entry into the Spam Words file not the Rule Filter. I believe that it will be the same in the Rule Filter but it should be a little more precise.

I finally got your RegExp to work in The RegEx Coach, however even then it would also match a subject like "BA RE:". This might be alright for you, i just wanted to point it out that there could be any text before that "RE:" as long as its separated from "RE:" by a word boundary (Non-Word-Character).
But when i tried your RegExp in Spami it would NOT work in any of the cases you see in my screenshot of the Training Area above.
I understand your reasoning behind your RegEx, now even the "\B" at the end ;-)
Except for the problem with text before the "RE:" it's fine, i just couldn't get it to work in Spami.
I cannot tell you why it is not working but it must have to do with the word boundaries.
boat_broker hat geschrieben:Thank you so much for the time you put into your reply. It was way more than I had hoped.

I'm also still trying to learn more about RegExps myself, i'm sure i'll benefit from this discussion myself, so call me selfish if you want ;-).
boat_broker hat geschrieben:I’ve been pecking away at this today and my head is spinning. I am curious if the virtual machine that you are using is available. I have been getting different results than you mention (or I am interpreting them incorrectly) when I use The Regex Coach by Edi Weitz that is mentioned in the Spamihilator Wiki RegEx Tutorial

I'm still using "The RegEx Coach" myself from time to time, but unfortunately it doesn't seem to have the exact same interpretation of PERL RegExps as being used in Spami through the Boost Library.
Using this fantastic program for developing RegExps for single Words should be no problem, i have done that myself plenty of times with great success.
But when it comes to more complex expressions with word boundaries, anchors and linefeeds i don't trust "The RegEx Coach" anymore since i already had more than one incident where it worked in the program but not in Spami.
One example:
When you have a text consisting of two lines of text with a forced linebreak (Hit "ENTER" at the end of the line") in between those two lines you can match this linebreak with the RegEx "\s" in "The RegEx Coach" but in the Boost Library it's two times "\s".
Every RegExp Program out there looks for a substring match of your RegExp. This corresponds to the method "contains (regex)" while Spami offers also the method "matches (regex)" where the whole test-text has to be matched by your RegExp. This makes it a little harder to develop RegExps that uses the method "matches (regex)".
My newest favorite playground for RegExps is the QuickREx plug-in in development platform Eclipse.
When I was trying to find the URL i just learned that QuickREx is also available now a s a standalone application.
http://www.bastian-bergerhoff.com/eclipse/features/web/QuickREx/standalone.html
The behavior is way closer to the one in Spami.
Of course the problem with the different methods "contains (regex)" and "matches (regex) persists.
Choose the Jakarta ORO Perl implementation and set the global ORO Perl flag "Case insensitive"
This requires only checking/unschecking stuff, don't panic ;-)

Regards,
Quellcore

Re: Rule Filter Information

Beitrag von boat_broker » 31. Mär 2010, 01:04

Quellcore,

I’ve been pecking away at this today and my head is spinning. I am curious if the virtual machine that you are using is available. I have been getting different results than you mention (or I am interpreting them incorrectly) when I use The Regex Coach by Edi Weitz that is mentioned in the Spamihilator Wiki RegEx Tutorial

Thanks,
Mike

Re: Rule Filter Information

Beitrag von boat_broker » 30. Mär 2010, 16:36

Quellcore,

Thanks for your expansive reply. I am still trying to digest it.

I believe that you correctly identified my intent with \b[Rr][Ee]\b:\s\B. However, with the RegEx Coach VM it does seem to work. It recognizes "Re:" and "Re: " and "Re: " (a re followed by a tab). At the same time it passes "Re: boats" and "Re:boats". So far, all is good.

I will let you know if I change anything and I will go back to my formula and try to explain my reasoning. I do need to review the "anchor" concept that you mentioned. I should also note that I came up with this as an entry into the Spam Words file not the Rule Filter. I believe that it will be the same in the Rule Filter but it should be a little more precise.

Thank you so much for the time you put into your reply. It was way more than I had hoped.

Mike

Re: Rule Filter Information

Beitrag von Chactory » 29. Mär 2010, 00:26

Hi Quellcore,

thank you for explaining! Now I got it! :)

Quellcore hat geschrieben:realize the difference between the most common "contains (regex)" and the "matches (regex)"

Regards, Chactory

Nach oben

 industrious-southeast