Richard G
Verified User
I don't know regexp so I need some help.
The various blacklistfiles in the /etc/virtual directory are based on nwildlsearch which means if you use a * wildcard, it has to be in the beginning of the line for example *.store, you can't use someting.* in these files.
That's how I thought this only would work with the nwildlsearch method.
But I thought there should be a better way so I searched and now I found these examples on the internet for nwildlsearch usage:
with this explaining text belonging to it.
Now we are receiving spam from addresses like this:
mail-koreacentralazolkn19012059.outbound.protection.outlook.com
now the mail-koreacentralazolkn part stays the same, but the number often changes.
Am I correct I would be able to block these too in the bad_sender_hosts like this with a * at the end, when using a ^in front of the line?
or am I undersanding this incorrectly? Maybe @zEitEr you have a clue?
The various blacklistfiles in the /etc/virtual directory are based on nwildlsearch which means if you use a * wildcard, it has to be in the beginning of the line for example *.store, you can't use someting.* in these files.
That's how I thought this only would work with the nwildlsearch method.
But I thought there should be a better way so I searched and now I found these examples on the internet for nwildlsearch usage:
Code:
[email protected]
*@somespamsite.com
*@someotherspamsite.com
^known-first-part@mail[.].*
^another-known-first-part@.*
That contains the word "regular expression" and then abracadabra starts in my head.Note that the * wilcards only work for the leading part of theaddress. For any other wildcarding – for example, ignoring thetrailing part of the address – we have to use a regular expression(cued by starting the line with ^).
Now we are receiving spam from addresses like this:
mail-koreacentralazolkn19012059.outbound.protection.outlook.com
now the mail-koreacentralazolkn part stays the same, but the number often changes.
Am I correct I would be able to block these too in the bad_sender_hosts like this with a * at the end, when using a ^in front of the line?
^mail-koreacentralazolkn*
or am I undersanding this incorrectly? Maybe @zEitEr you have a clue?