Search found 2987 matches

by palinka
2021-10-24 20:47
Forum: General discussions
Topic: Using ip2location to block whole countrys ?
Replies: 26
Views: 254

Re: Using ip2location to block whole countrys ?

That's it.

And reload scripts or restart hmailserver.
by palinka
2021-10-24 19:14
Forum: General discussions
Topic: Using ip2location to block whole countrys ?
Replies: 26
Views: 254

Re: Using ip2location to block whole countrys ?

And now we're back to the brining of the thread. :D
by palinka
2021-10-24 15:53
Forum: Scripting
Topic: Find Registrar Abuse Email
Replies: 6
Views: 59

Re: Find Registrar Abuse Email

Making progress. I changed the "database" of abuse contacts to a csv to make it easier to share. I guess eventually it will be in mysql format. There are 2,497 accredited registrars, so if I make any progress with the database, it's definitely going to need to be in mysql. For now, I just plan to ad...
by palinka
2021-10-24 02:39
Forum: Scripting
Topic: Find Registrar Abuse Email
Replies: 6
Views: 59

Re: Find Registrar Abuse Email

I see. This should have shipped with windows. Of course, it's probably still in the beta stage. They'll release it any day now. :roll:
by palinka
2021-10-24 01:20
Forum: Scripting
Topic: Find Registrar Abuse Email
Replies: 6
Views: 59

Re: Find Registrar Abuse Email

Pssst... https://www.hmailserver.com/forum/viewtopic.php?f=7&t=37442&p=233057&hilit=ScriptControl#p233057 32Bit version on my Windows Server 2003 Function jsonDecode(jsonString) Dim oSCtrl Set oSCtrl = CreateObject("MSScriptControl.ScriptControl") ' .NET Framework 3.5 - 4.8 oSCtrl.Language = "JScri...
by palinka
2021-10-23 23:36
Forum: Scripting
Topic: Find Registrar Abuse Email
Replies: 6
Views: 59

Re: Find Registrar Abuse Email

👍
by palinka
2021-10-23 21:51
Forum: Scripting
Topic: Find Registrar Abuse Email
Replies: 6
Views: 59

Find Registrar Abuse Email

I was inspired by Soren's automated forwarding of spam to domain registrar (https://hmailserver.com/forum/viewtopic.php?p=233909#p233909) so I set out to replicate it. Soren's version focused on NameCheap. I'm looking to do it for any ol' spam that comes along. However, it turns out that finding the...
by palinka
2021-10-23 20:59
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

PHP interface: Changed drop down boxes to submit on selection. Browsing goes a little faster.
by palinka
2021-10-23 18:56
Forum: General discussions
Topic: Using ip2location to block whole countrys ?
Replies: 26
Views: 254

Re: Using ip2location to block whole countrys ?

SorenR wrote:
2021-10-23 18:11
Nah ... :mrgreen:
Not everyone is a 9th degree spamjitsu black belt master... :mrgreen:
by palinka
2021-10-23 13:09
Forum: General discussions
Topic: SSL Certificate implementation questions
Replies: 5
Views: 129

Re: SSL Certificate implementation questions

mikedibella wrote:
2021-10-22 22:51
Look at win-acme: https://www.win-acme.com/
+1 for win-acme.

Also, domain confirmation can be achieved without IIS/apache if you script dns api entries with your dns provider. You can also get wildcard certificates using that method.
by palinka
2021-10-23 12:18
Forum: General discussions
Topic: Using ip2location to block whole countrys ?
Replies: 26
Views: 254

Re: Using ip2location to block whole countrys ?

I think, however, that I will also write a PHP script which will write the "good" countries from the imported table from IP2LOC into the database of HMS instead of "0.0.0.0 - Internet". The easiest way to do this is to define an array in the script in which the country code of good countries are no...
by palinka
2021-10-22 03:32
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

Well.... I have not used that for a very long time but ... strRegEx = GetXMLNode(XMLDATA, "//UCE/namesilo") Set oMatches = oLookup(strRegEx, Client_HELO, False) For Each oMatch In oMatches If (oClient.IPAddress = Client_IP) Then EventLogX.Write( LPad("Returned UCE", 15, " ") & vbTab & LPad(Client_I...
by palinka
2021-10-21 22:17
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

SUCCESS! It turns out those guys at Namecheap are awesome! Domains are still listed in Whois BUT! mxtoolbox cannot find the suspended ones so it appear they have no DNS records. :mrgreen: Hello, Thank you for your email. While the following domain names are registered with Namecheap, they are hoste...
by palinka
2021-10-21 01:43
Forum: General discussions
Topic: Using ip2location to block whole countrys ?
Replies: 26
Views: 254

Re: Using ip2location to block whole countrys ?

M*I*B wrote:
2021-10-20 14:34
... will check that script out too ...
That might be your best bet. It definitely works.
by palinka
2021-10-21 01:41
Forum: General discussions
Topic: Using ip2location to block whole countrys ?
Replies: 26
Views: 254

Re: Using ip2location to block whole countrys ?

Der Typ [MySql.Data.MySqlClient.MySqlConnection] kann nicht gefunden werden. Stellen Sie sicher, dass die Assembly, die diesen Typ enthält, geladen wird. 20.10.2021 14:21:40 : [ERROR] : Unable to drop/create database tables : Es ist nicht möglich, eine Methode für einen Ausdruck aufzurufen, der den...
by palinka
2021-10-20 14:00
Forum: General discussions
Topic: Using ip2location to block whole countrys ?
Replies: 26
Views: 254

Re: Using ip2location to block whole countrys ?

M*I*B wrote:
2021-10-20 13:55
Do I have to think about / adjust / blablub?
That is one of the minimum requirements.
by palinka
2021-10-20 12:56
Forum: General discussions
Topic: How to Forward all outbound email
Replies: 8
Views: 154

Re: How to Forward all outbound email

Create a rule:

If message size greater than 0, then forward email.
by palinka
2021-10-20 12:43
Forum: General discussions
Topic: Using ip2location to block whole countrys ?
Replies: 26
Views: 254

Re: Using ip2location to block whole countrys ?

And if I include this script here and enter zz.countries.nerd.dk in HMS, what do I have to enter under "Expected Result, Rejection Message, Score"? I never used nerd.dk, so I tried it out on a known US IP, then changed us to uk to force an error and see what the return codes are: C:\Users\palinka>n...
by palinka
2021-10-19 17:05
Forum: General discussions
Topic: Using ip2location to block whole countrys ?
Replies: 26
Views: 254

Re: Using ip2location to block whole countrys ?

Have a look at this: https://hmailserver.com/forum/viewtopic.php?f=9&t=34496 And this: https://github.com/palinkas-jo-reggelt/GeoLite2SQL How I do it: I have a whitelist function that checks various RWLs (RBLs that also do whitelisting). If any come back as whitelisted, then I assume the server shou...
by palinka
2021-10-19 15:47
Forum: SpamAssassin implementation discussions
Topic: I there a HowTo (learn a.s.o.)?
Replies: 6
Views: 114

Re: I there a HowTo (learn a.s.o.)?

M*I*B wrote:
2021-10-19 13:36
>> Its only a few pages.

... shure ... in english, isn't it? :roll: :lol:
It sure was last time I checked. Did the mods translate it to Swahili recently? That would be unusual. :lol:
by palinka
2021-10-19 15:44
Forum: User contributed hMailServer 5 scripts
Topic: SpamAssassin Bootcamp (sa-learn) train BAYES
Replies: 173
Views: 131066

Re: SpamAssassin Bootcamp (sa-learn) train BAYES

Well... I reject non-RFC compliant HELO/EHLO greetings, and the following list of TLD's: .top, .xyz, .icu, .best, .ga, .club, .press, .today, .guru, .casa, .tk, .ml, .work, .buzz, .co, .monster, .cyou Besides any addresses flagged as Snowshoe SPAM or Lashback SPAM. ... ahem... HowTo? https://hmails...
by palinka
2021-10-19 13:15
Forum: SpamAssassin implementation discussions
Topic: I there a HowTo (learn a.s.o.)?
Replies: 6
Views: 114

Re: I there a HowTo (learn a.s.o.)?

M*I*B wrote:
2021-10-19 13:05
... thx a lot. I will study that and try ...
Or you can skip to the end! :mrgreen:

https://hmailserver.com/forum/viewtopic ... 84#p225384

But seriously, read the whole thing to familiarize yourself before diving in. Its only a few pages.
by palinka
2021-10-19 12:59
Forum: SpamAssassin implementation discussions
Topic: I there a HowTo (learn a.s.o.)?
Replies: 6
Views: 114

Re: I there a HowTo (learn a.s.o.)?

Can't help with the language, but there is a wealth of info on training spamassassin here: https://hmailserver.com/forum/viewtopic ... 20&t=26866
by palinka
2021-10-19 11:52
Forum: General discussions
Topic: How to block .co domains
Replies: 11
Views: 219

Re: How to block .co domains

Chainz wrote:
2021-10-19 09:34
Thank you! This time it worked. I want to learn more about about regex how can I find documentation about it?
https://regex101.com/

Good place to start. And good for testing too.
by palinka
2021-10-18 12:20
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

One more small change. Sorting now works as follows: active hits (greater than 0) in order of tracked (timestamp) descending. Therefore, inactive appear at the end; hits>0 appear in timestamp desc order (so you will always see the last hit at the very top, then the next to last, etc), then finally h...
by palinka
2021-10-18 12:00
Forum: General discussions
Topic: How to block .co domains
Replies: 11
Views: 219

Re: How to block .co domains

Hi, I used the method you suggested, but it doesn't seem to work. Maybe I'm doing something wrong? I'm attaching screenshots of the config that i used. hmail spam rule.png Can it be because I'm running an older version of hmail hmail version.png try this instead: ^.*(\.bid|\.club|\.co)(?:[\"\>]*)$ ...
by palinka
2021-10-18 00:53
Forum: General discussions
Topic: "Call Back" sender validation ...
Replies: 12
Views: 268

Re: "Call Back" sender validation ...

First time I have seen this... I'm really surprised to hear that This is really old technology, that I thought had been generally dropped due to this... https://en.wikipedia.org/wiki/Callback_verification If a server receives a lot of spam it may do a lot of callbacks. If those addresses are invali...
by palinka
2021-10-18 00:50
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

PHP interface attached. Minor improvements since last version.
by palinka
2021-10-17 16:01
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

Function myListsStat(myListsDict, oMatchValue) Dim i, objKey Dim strSQL, oDB : Set oDB = CreateObject("ADODB.Connection") oDB.Open "DRIVER={" & DBDRVR & "};Server=" & DBSERVER & ";Port=" & DBPORT & ";Database=" & DBNAME & ";Uid=" & DBUID & ";Pwd=" & DBPW & ";FOUND_ROWS=1;" If oDB.State <> 1 Then Ev...
by palinka
2021-10-17 14:21
Forum: General discussions
Topic: "Call Back" sender validation ...
Replies: 12
Views: 268

Re: "Call Back" sender validation ...

If i read the limitations part of that wiki page, i doubt this is worth anything As example take IDS in mind, how would that work/play out? IDS shouldn't be a problem: * half connection, IP added * message sent on next try, IP removed You may have to increase the number of tries before banning if a...
by palinka
2021-10-17 14:20
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

Function myListStat(myListDict, oMatchValue) Dim i, a, b Dim strSQL, oDB : Set oDB = CreateObject("ADODB.Connection") oDB.Open "Driver={MariaDB ODBC 3.1 Driver}; Server=localhost; Database=hmailserver; User=hmailserver; Password=supersecretpassword;" If oDB.State <> 1 Then WScript.Echo( "myListRegE...
by palinka
2021-10-17 13:25
Forum: General discussions
Topic: "Call Back" sender validation ...
Replies: 12
Views: 268

Re: "Call Back" sender validation ...

https://en.wikipedia.org/wiki/Callback_verification If i read the limitations part of that wiki page, i doubt this is worth anything As example take IDS in mind, how would that work/play out? IDS shouldn't be a problem: * half connection, IP added * message sent on next try, IP removed You may have...
by palinka
2021-10-17 13:10
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

Just implemented it in eventhandlers and no more errors. Everything works. Hits count increases properly now on test message from gmail. Nice catch ;-) Only thing that bugs me is that it takes a little more ressources on a busy server. That is one of my "things" ... Saving CPU cycles = Saving CO2 :...
by palinka
2021-10-17 04:10
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

Just implemented it in eventhandlers and no more errors. Everything works. Hits count increases properly now on test message from gmail.
by palinka
2021-10-17 03:49
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

I've gone into combat mode trying to figure this shyte out... Never go to war with vikings. :mrgreen: Hmm... 2 groups ... two submatches in oMatchCollection strRegEx = "(127(?:\.[0-9]{1,3}){3})" I think i have it. First off all, everything works except sometimes on MyListStat(). Nothing wrong with ...
by palinka
2021-10-17 03:02
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

I'm boning up on multi dimensional arrays. Whatever you are into really...if that makes you happy? Or is it only in Australia, where 'boning up' is a sexual reference, meaning where a bloke would get aroused. https://www.merriam-webster.com/dictionary/bone%20up bone up verb boned up; boning up; bon...
by palinka
2021-10-16 22:33
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

I'm boning up on multi dimensional arrays.
by palinka
2021-10-16 17:25
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

I've gone into combat mode trying to figure this shyte out... Never go to war with vikings. :mrgreen: Hmm... 2 groups ... two submatches in oMatchCollection strRegEx = "(127(?:\.[0-9]{1,3}){3})" I think i have it. First off all, everything works except sometimes on MyListStat(). Nothing wrong with ...
by palinka
2021-10-16 16:25
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

For some reason RegEx find more "submatches" than there is... Right? That's my problem exactly. I'm surprised you haven't seen out of range errors like i have. Maybe the solution is to construct every node to match beginning and end. That way there could not possibly additional matches? In shooting...
by palinka
2021-10-16 13:32
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

I added your "log writes" to my code and "(fluke off niagara)" to my database... 2532 "2021-10-16 11:47:31.001" "key count : 1" 2532 "2021-10-16 11:47:31.001" "match count: 1" 2532 "2021-10-16 11:47:31.001" "i : 0" 2532 "2021-10-16 11:47:31.001" "key : 345" 2532 "2021-10-16 11:47:31.001" "subm...
by palinka
2021-10-16 04:31
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

Last one for tonight. I changed the debugging to be at the top of the for loop. As above there are 7 rows as mysql query result. Plus, I changed "For i = 0 To oMatch.SubMatches.Count-1" to "For i = 0 To myListDict.Count-1" which got rid of the out of range error. Function MyListStat(MyListDict, oMat...
by palinka
2021-10-16 03:25
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

I added some debugging. Function MyListStat(MyListDict, oMatch) Dim i, a Dim strSQL, oDB : Set oDB = CreateObject("ADODB.Connection") oDB.Open "Driver={MariaDB ODBC 3.1 Driver}; Server=localhost; Database=hmailserver; User=hmailserver; Password=supersecretpassword;" If oDB.State <> 1 Then EventLog.W...
by palinka
2021-10-16 02:56
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

What's in line 590 +/- 5 lines ? Can you verify there are listings in the database that matches and active=1 ?? Lines 577-597: Function MyListStat(MyListDict, oMatch) Dim i, a Dim strSQL, oDB : Set oDB = CreateObject("ADODB.Connection") oDB.Open "Driver={MariaDB ODBC 3.1 Driver}; Server=localhost; ...
by palinka
2021-10-15 20:06
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

Hmmm... copied it verbatim except for the connection strings. Still no dice. Same error: Subscript out of range: 'i' in the MyListStat function: strSQL = "UPDATE " & DBTABLE & " SET tracked = NOW(), hits = (hits + 1) WHERE id = " & a(i) & ";" If MyListStat is being called, then obviously the script ...
by palinka
2021-10-15 18:41
Forum: General discussions
Topic: Help for errors
Replies: 4
Views: 115

Re: Help for errors

Could also be ram problem.
by palinka
2021-10-15 16:45
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

Sub OnAcceptMessage(oClient, oMessage) ' left out Dim's, other operations, etc for brevity REM - Blacklist "Subject:" strRegEx = MyListRegEx(MyListDict, "//Blacklist/Subject") If strRegEx <> "VOID" Then Set oMatchCollection = oLookup(strRegEx, oMessage.Subject, False) For Each oMatch In oMatchColle...
by palinka
2021-10-15 13:13
Forum: User contributed hMailServer 5 scripts
Topic: Dynamic Black/Whitelists in your script.
Replies: 148
Views: 74391

Re: Dynamic Black/Whitelists in your script.

Please help me Soren-Wan! You're my only hope! I broke something and I can't figure it out because I'm poor with scripting dictionary.. :( (I think) Symptoms: 1) Send email with blacklisted subject from gmail to my hmailserver account 2) Message does not get blacklisted (X-hMailServer-Reason-Score: ...
by palinka
2021-10-14 12:30
Forum: General discussions
Topic: Log Entries Show Sending Server Fails TLS Handshake No Shared Cipher On Repeat Send TLS Not Used
Replies: 37
Views: 617

Re: Log Entries Show Sending Server Fails TLS Handshake No Shared Cipher On Repeat Send TLS Not Used

I have been using hMailServer for 10 years and the SSL/TLS Ciphers Entry has always been empty by default. New installs should contain the default ciphers. If you removed them at one point and upgraded or restored a backup (or series of upgrades/restores) then they wouldn't be present because you c...
by palinka
2021-10-14 12:17
Forum: User contributed hMailServer 5 scripts
Topic: Utility to update IP Range address
Replies: 3
Views: 3832

Re: Utility to update IP Range address

Why are connections on the same wan address presented as the external address instead of an internal LAN address? In my case its a router that doesn't do hairpinning very well (or at all). I fixed that by changing my hosts file on the client machine to point to the LAN address of the server on my d...
by palinka
2021-10-13 13:11
Forum: User contributed hMailServer 5 scripts
Topic: Problem with OnSMTPData filter script
Replies: 9
Views: 3353

Re: Problem with OnSMTPData filter script

If i understand well, \.co mean it end by .co ? and not, it contain .co ? Because I don't know vbscript, everything i made in vbs is based on my own deductions and observations. It's not vbs, it's regex (via vbs). . dot means literally any character \. escaped dot means only dot $ dollar sign means...
by palinka
2021-10-13 12:19
Forum: User contributed hMailServer 5 scripts
Topic: Problem with OnSMTPData filter script
Replies: 9
Views: 3353

Re: Problem with OnSMTPData filter script

1-SorenR, is your code able to catch .co and not .com ? Just add |\.co to the list. 2-Do you understand why my script is catching this email : "RECEIVED: MAIL FROM:<msprvs1=18920d6xNhWV6=bounces-222165-2@e.change.org>" Not unless you post your script. :D By the way, looking at your original post, i...
by palinka
2021-10-13 11:50
Forum: General discussions
Topic: How to block .co domains
Replies: 11
Views: 219

Re: How to block .co domains

Criteria:
From
Regular Expression (\.bid|\.club|\.co)(?:[\"\>]*)$

https://regex101.com/r/5e1Ger/1

You can add others besides .bid and .club. Just separate them with the pipe "|".
by palinka
2021-10-13 02:33
Forum: General discussions
Topic: Identification of messages retrieved via the POP3C
Replies: 9
Views: 167

Re: Identification of messages retrieved via the POP3C

Any thoughts on how to craft a expression that is false if the header is absent? Our posts crossed ... See post ^^ ;-) OP stated he's looking for a match by global rule. So... Criteria: custom header value X-hMailServer-ExternalAccount regex ^$ Or instead of regex, custom header value = BLANK? I'm ...
by palinka
2021-10-12 14:15
Forum: General discussions
Topic: Deal with error 550 and 535
Replies: 6
Views: 168

Re: Deal with error 550 and 535

Now that i think about it, banning by username isn't really practical for the following reasons: 1) the username is not available in OnClientLogon until AFTER login attempt 2) even if you could get the username before logon attempt, the ones you want to block are generally coming from giant bot netw...
by palinka
2021-10-12 12:07
Forum: General discussions
Topic: Deal with error 550 and 535
Replies: 6
Views: 168

Re: Deal with error 550 and 535

Try Soren's IDS (intrusion detection system): https://hmailserver.com/forum/viewtopic.php?p=209545#p209545 The way it works is every client IP gets logged into a database. If the client successfully completes a transaction (sends a message or logs in), the IP is deleted from the database. If not suc...
by palinka
2021-10-11 14:45
Forum: General discussions
Topic: Emails fails depending on the client
Replies: 9
Views: 242

Re: Emails fails depending on the client

If you're using antivirus, try turning it off.
by palinka
2021-10-10 15:40
Forum: Scripting
Topic: Adding a domain using PowerShell and COM API
Replies: 22
Views: 552

Re: Adding a domain using PowerShell and COM API

SorenR wrote:
2021-10-10 01:47
Hmmm... According to this https://powershell.one/wmi/remote-access DCOM is considered obsolete ... :roll:
:lol: :lol: :lol:

Buggy whips were once considered state of the art for enhancing and optimizing vehicle velocity.

:lol: :lol: :lol: