Search found 61 matches

by mikernet
2020-04-04 02:55
Forum: User contributed hMailServer 5 scripts
Topic: Check incoming connections with AbuseIPDB
Replies: 90
Views: 27937

Re: Check incoming connections with AbuseIPDB

I already have the IP. What I was posting about was also getting the domain. As indicated above, we've already solved that issue so I'm not really sure where this is going.
by mikernet
2020-04-03 23:54
Forum: User contributed hMailServer 5 scripts
Topic: Check incoming connections with AbuseIPDB
Replies: 90
Views: 27937

Re: Check incoming connections with AbuseIPDB

palinka wrote:
2020-04-03 21:23
Maybe you should LOG everything in a way that's easily searchable.
That's kind of the point. Can't log the email/domain if you cut off the connection before you get that info...
by mikernet
2020-04-03 18:56
Forum: User contributed hMailServer 5 scripts
Topic: Check incoming connections with AbuseIPDB
Replies: 90
Views: 27937

Re: Check incoming connections with AbuseIPDB

Clearly had a brainfart...of course I can just do the check there instead of splitting it up. It is relevant if you are trying to help someone diagnose why your email server isn't accepting emails from them. Sometimes the sending IP address changes, sometimes they use multiple services to send mail ...
by mikernet
2020-04-03 17:46
Forum: User contributed hMailServer 5 scripts
Topic: Check incoming connections with AbuseIPDB
Replies: 90
Views: 27937

Re: Check incoming connections with AbuseIPDB

I've been doing AbuseIPDB checks for a while and it works great but I have a slight issue which relates to logging/diagnostics. When emails from someone aren't coming through it is very difficult to check if it is due to AbuseIPDB since the email domain is not tagged with the IP block. I think it wo...
by mikernet
2020-02-26 23:18
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Upon further reflection, I'm torn on what appropriate behavior should be here, but I guess you can't go wrong with configurability.
by mikernet
2020-02-26 14:29
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Nevermind, I see how a DNS trace could help - there are a lot more results than just pass/fail/neutral. Hmm... The SPF checker should probably emit the actual SPF result into the debug log during the check to help narrow things down. That said, given the limitations of hMailServer SPF testing, I'm o...
by mikernet
2020-02-26 14:11
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Unfortunately, I don't think I can do a Wireshark on the mail server at the moment. What information are you hoping to get from a Wireshark trace though? I think the main underlying issue is that a neutral result is not considered a pass for greylisting purposes. Secondary to that is why a neutral r...
by mikernet
2020-02-26 13:46
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

To be fair, the debug log didn't say the SPF test passed, it only said that the score it contributed to the spam score was 0, haha. That did make it somewhat difficult to trace the issue though. At least it pointed us in the right direction :P
by mikernet
2020-02-26 13:23
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Here is the exact line that the test runner code starts, which runs each test and outputs to the debug log based on the difference in the total score after the test is run, irrespective of whether or not the individual test decides to add a test result into the test result set: https://github.com/hm...
by mikernet
2020-02-26 13:15
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

That debug line is output in the code I JUST posted above, which uses the difference in the total score after the enabled test is run: sSpamTestResult.Format(_T("Spam test: %s, Score: %d"), sName.c_str(), totalDiff); LOG_DEBUG(sSpamTestResult); That code gets run regardless of whether the test passe...
by mikernet
2020-02-26 13:13
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

The spam test runner goes test by test, runs it, and then outputs the difference in the total score after each enabled test is run. After the SPF test is run, the total difference is 0, and that's where the debug log line for the SPF test is output. The SPF debug log line gets output regardless of w...
by mikernet
2020-02-26 13:12
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Haha...I don't really know what to make of "whatever... good luck" - did I upset you or was my "typing tone" off?

I certainly didn't mean it that way so I apologize if that's the case. I wasn't quoting "ignored" to be facetious if that's how that came across <3
by mikernet
2020-02-26 12:55
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

So, the question becomes: should greylisting bypass on SPF NEUTRAL result as well...I would argue it should. If it isn't failing then don't greylist it. The second question is, why is the result of the SPF test NEUTRAL and not PASS? I'm not 100% sure what a neutral result even means. From what I can...
by mikernet
2020-02-26 12:51
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

That code will clearly output a score of 0 because the test is "ignored" and thus the score difference is 0 after it is run...so we get the behavior I described.
by mikernet
2020-02-26 12:51
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Bingo: int totalScoreBefore = iTotalScore; for (; iter != iterEnd; iter++) { std::shared_ptr<SpamTestResult> pResult = (*iter); setTotalResult.insert(pResult); iTotalScore += pResult->GetSpamScore(); } int totalDiff = iTotalScore - totalScoreBefore; String sSpamTestResult; sSpamTestResult.Format(_T(...
by mikernet
2020-02-26 12:48
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

You have to be precise about your definition of "ignored" in this situation though. Yes it is "ignored" in the sense that it is not added to the set of spam test results, but what are the side-effects of that? One side effect is that this code that you posted: if (Configuration::Instance()->GetAntiS...
by mikernet
2020-02-26 12:39
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

The score is only added in the code you posted on a FAIL result, so it would make sense to me that a NEUTRAL result would have a 0 score. Where in the code would a score be added for a NEUTRAL result?
by mikernet
2020-02-26 12:37
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

From the info we have (fails to bypass greylisting but does not score in spam test), I'm fairly sure this particular SPF test is coming back neutral for some reason...maybe because of the macro? That would only make sense if it resolved the entire SPF record chain upfront instead of stepping through...
by mikernet
2020-02-26 12:32
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Okay, so I'm 99% sure we found the problem. It's right there in the code you posted. The code considers FAIL and PASS results...but the SPF test CAN apparently return NEUTRAL: https://github.com/hmailserver/hmailserver/blob/master/hmailserver/source/Server/SMTP/SPF/SPF.h The greylisting bypass code ...
by mikernet
2020-02-26 12:04
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Why would whitelisting have anything to do with the bypass on SPF pass mechanism? It's just ANOTHER mechanism to bypass greylisting, so regardless of whether or not an IP passes the whitelist it should still bypass on SPF pass. The greylisting whitelist does support wildcards though :) It was discus...
by mikernet
2020-02-26 02:12
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Well then whatever the issue is, it seems that SPF passes for the purpose of the spam tests, but somehow fails for the purpose of greylisting bypass. Perhaps the actual test result is Neutral instead of Pass so the spam test score comes out to 0 but still greylists? SpamTestResult can take on the va...
by mikernet
2020-02-25 23:25
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Does it redo the SPF test for greylisting or reuse the spam test result? If it redoes the test, does it not use the same SPF code?
by mikernet
2020-02-25 23:19
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Yes
by mikernet
2020-02-25 21:37
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

It says "SpamTestSPF, Score: 0" which presumably means it passed SPF testing, yet it still greylists it? Am I missing something?
by mikernet
2020-02-25 21:36
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

"DEBUG" 63464 "2020-02-25 14:33:14.018" "Creating session 940" "DEBUG" 63464 "2020-02-25 14:33:14.018" "Executing event OnClientConnect" "DEBUG" 63464 "2020-02-25 14:33:14.440" "Event completed" "DEBUG" 63464 "2020-02-25 14:33:14.440" "TCP connection started for session 939" "SMTPD" 63464 939 "2020...
by mikernet
2020-02-25 13:57
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Oh sorry, misread what he said.
by mikernet
2020-02-25 13:47
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

I don't think I've ever had a problem with HELO not being used before. I would be surprised if a legit mail sender would rely on that behavior. Would that not completely eliminate the purpose of SPF anyway?

The basic test in the link you provided which does not use HELO passes fine though.
by mikernet
2020-02-23 20:47
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

I'm working on a debug trace but that won't happen until Monday. The problem 100% exists that something in the VALID olg.ca SPF record is causing hMailServer to fail the SPF check though. Wireshark ?? I believe you should be able to filter "dns.spf" ... I need OLG to send me an email first :) They ...
by mikernet
2020-02-23 20:43
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Sure, fine by me...i don't care much if it returns the expected ip address, but it my opinion it should (most i tested do) For example: 52.31.115.240 send a mail, spf exists:%{i}._spf.sparkpostmail.com is in place there 52.31.115.240._spf.sparkpostmail.com resolves to A RR 52.31.115.240 It literall...
by mikernet
2020-02-23 20:33
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Wee are still tackling a problem that we haven't yet proven exists. We arte still assuming the macro is the cause of the original failure and are still waiting for the proof that . (We never assume anything without seeing it). That said it would be useful to see debug level logging for such an even...
by mikernet
2020-02-23 20:31
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

As far i understand the exists:%{i} macro doesn't do much more as checking if the value in %{i} resolves to any A-record, the returned IP address does not need to match that of the sender. So this apparently is the worst option that you can define in your spf record as it security wise doesn't veri...
by mikernet
2020-02-23 20:02
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

As far i understand the exists:%{i} macro doesn't do much more as checking if the value in %{i} resolves to any A-record, the returned IP address does not need to match that of the sender. So this apparently is the worst option that you can define in your spf record as it security wise doesn't veri...
by mikernet
2020-02-22 06:24
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

This made me wonder - if a third-party included record becomes "unavailable" and cannot be retrieved, does the whole SPF record get thrown out as well?
by mikernet
2020-02-22 06:21
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Greylisting with SPF bypass still manages to stop a significant portion of spam for us before it has a chance to go anywhere else, but given hMailServer's current non-conformant SPF implementation and lack of ability to handle this situation, it seems that we need to disable it now. If someone has a...
by mikernet
2020-02-22 02:10
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

That macro passes SPF validation on every test site I've tried, including macro resolution on the sample site I provided, so it must be following readily available standards. Even if it wasnt though, I really dont think the entire SPF config shoul# be thrown away because of a bad included SPF record...
by mikernet
2020-02-21 23:12
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Can you elaborate on how I get the debug level logging you're looking for? Here is the diagnostic report output: 2020-02-21 Hmailserver: 5.6.7-B2425 DOMAINS "Domain1.com" - atxxxxxxxxxxxxxx.ca Enabled: True SIGNATURE LIMITS DKIM ADVANCED Enabled: False Max size: 0 Enabled: False Catchall: info@Domai...
by mikernet
2020-02-21 22:55
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Let me know if you still want me to run that report, but I don't think this really has anything to do with my settings. hMailServer just fails to SPF pass mail coming from 40.107.223.80 for the olg.ca domain, which should pass no problem.
by mikernet
2020-02-21 22:37
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

Re: SPF not working correctly

Yes, I have greylisting enabled with bypass on SPF pass. The issue is that SPF should be passing for that email server IP and domain.
by mikernet
2020-02-21 20:55
Forum: General discussions
Topic: SPF not working correctly
Replies: 95
Views: 44462

SPF not working correctly

Running hMailServer version 5.6.7. Never had an issue like this in many years, until now. Here is an example of the log section that shows the email being greylisted: "SMTPD" 2128 79087 "2020-02-17 01:29:03.833" "40.107.223.80" "SENT: 220 mail.singulink.com ESMTP" "SMTPD" 2132 79087 "2020-02-17 01:2...
by mikernet
2019-03-02 02:36
Forum: Feature requests
Topic: Decimal values for spam tests
Replies: 5
Views: 2999

Re: Decimal values for spam tests

You wouldn't happen to know if there's a way to configure SA to multiply the final score by a certain amount without editing every single rule would you? If I could multiply the score before it's returned then I could get more granular control over the threshold values in hMailServer as I'll have a ...
by mikernet
2019-03-02 02:28
Forum: Feature requests
Topic: Decimal values for spam tests
Replies: 5
Views: 2999

Re: Decimal values for spam tests

Hmmm? SpamAssassin has always returned decimal spam score values. EDIT: Oh wait...I see what you mean - the computed X-hMailServer-Reason-Score does look like it's always a whole number. Nevermind then. I've just always looked at the X-Spam-Status header scores SpamAssassin returns when tuning thing...
by mikernet
2019-03-02 02:26
Forum: Development & alpha discussions
Topic: hMailServer Administrator causing mail server to become unresponsive
Replies: 10
Views: 4100

Re: hMailServer Administrator causing mail server to become unresponsive

Latest 5.6.7-B2425. I haven't done a fresh install since the first time I installed it probably more than 10 years ago now though...just been upgrading it and the original 2008 R2 VM it was installed on is still chugging along today haha. Not sure if there's anything about that that may be causing t...
by mikernet
2019-03-01 19:06
Forum: Feature requests
Topic: Decimal values for spam tests
Replies: 5
Views: 2999

Decimal values for spam tests

It would be great to be able to enter decimal values instead of just integers for the spam test scores as well as the spam thresholds, particularly when using it with SpamAssassin. I really want to mark my spam threshold as a x.5 value for the threshold as well as for some of the spam tests but I ne...
by mikernet
2019-03-01 18:44
Forum: Development & alpha discussions
Topic: hMailServer Administrator causing mail server to become unresponsive
Replies: 10
Views: 4100

Re: hMailServer Administrator causing mail server to become unresponsive

Yeah, I don't know...I literally just had to restart hMailServer again because it completely stopped responding to SMTP requests after the HELO because I had the Administrator application open for too long, haha. No errors in any logs, nothing. I can run hMailServer with a year of uptime no problem ...
by mikernet
2019-03-01 06:47
Forum: Development & alpha discussions
Topic: hMailServer Administrator causing mail server to become unresponsive
Replies: 10
Views: 4100

Re: hMailServer Administrator causing mail server to become unresponsive

I haven't really paid attention to the memory usage as the server has plenty of free memory so I'm not sure if it's actually using more memory. I doubt the issue would be just memory leak related, something else is going on that's causing this. In terms of what I mean about sluggish - switching betw...
by mikernet
2019-02-28 20:57
Forum: Development & alpha discussions
Topic: hMailServer Administrator causing mail server to become unresponsive
Replies: 10
Views: 4100

hMailServer Administrator causing mail server to become unresponsive

I don't know if anyone else has noticed this, but when I spend a lot of time in hMailServer Administrator, it's responsiveness starts to becomes sluggish and so does the mail server itself (connected mail clients clearly start taking longer to load messages, change folders, save draft messages, etc)...
by mikernet
2019-02-28 16:29
Forum: Scripting
Topic: Add custom external spam filter
Replies: 21
Views: 5092

Re: Add custom external spam filter

I'm guessing my situation is a bit different than yours as well SorenR. Your suggested scripts indicate that you are putting in 100% confidence into the spamhaus zen list and lashback to block emails. Given the large number of customer email addresses I host, I can't do that. If it was only my compa...
by mikernet
2019-02-28 15:33
Forum: Scripting
Topic: Add custom external spam filter
Replies: 21
Views: 5092

Re: Add custom external spam filter

Just to clarify....I'm talking about a very "small" level of spam. On my own email account, which I've been using as my primary email for 12 years now and which aggregates email from several company mailboxes that at times have been plastered on the internet for all spammers to see, gets maybe 1-2 s...
by mikernet
2019-02-28 15:26
Forum: Scripting
Topic: Add custom external spam filter
Replies: 21
Views: 5092

Re: Add custom external spam filter

Thanks SorenR for digging in, but the point is that there IS spam left over after all that. I've already implemented everything else you're suggesting. The spam that IS left over that is getting through has a fairly high rate of reply-to/from addresses that have no websites on their domains. The lis...
by mikernet
2019-02-28 04:39
Forum: Scripting
Topic: Add custom external spam filter
Replies: 21
Views: 5092

Re: Add custom external spam filter

I'm not talking about his original replies. This line was clearly intended to be smug: "So with all your fancy SPAM fighting and many years of experience you have not figured out how to work the SPAM score in hMailServer, eh?" Clearly I had not because that was my original question. As my current se...
by mikernet
2019-02-28 01:52
Forum: Scripting
Topic: Add custom external spam filter
Replies: 21
Views: 5092

Re: Add custom external spam filter

Yes SorenR, that is correct, I didn't know how to access the spam score programmatically from a script because I haven't had a need to do that yet. That's kind of why I asked the question in the first place. Is that really so surprising? I have several scripts that block messages but haven't seen or...
by mikernet
2019-02-28 00:00
Forum: Scripting
Topic: Add custom external spam filter
Replies: 21
Views: 5092

Re: Add custom external spam filter

Again, thank you for your input, but that's not what I'm asking. I'm very well versed in spam filtering and I have a very comprehensive spam protection setup at the moment. Please stay on topic and keep answers relevant to my question. I'm not interested in a beginner's framework for fixing 60% of m...
by mikernet
2019-02-27 19:39
Forum: Scripting
Topic: Add custom external spam filter
Replies: 21
Views: 5092

Re: Add custom external spam filter

Thanks for the input SorenR but that doesn't address my question. I'm looking to modify the spam score from a script or be able to plug in an external program that can do that like SpamAssassin. So far the only real option I've been able to figure out is going the route of building a custom SpamAssa...
by mikernet
2019-02-27 18:43
Forum: Scripting
Topic: Add custom external spam filter
Replies: 21
Views: 5092

Re: Add custom external spam filter

I just checked 25 of the last spam messages that came through and 25 of the last legit sending domains in my inbox. All of the spam domains had no website or threw out a 403 forbidden and all 25 legit domains have a valid website at the root domain. I haven't seen any spam filtering options to do th...
by mikernet
2019-02-27 18:27
Forum: Scripting
Topic: Add custom external spam filter
Replies: 21
Views: 5092

Add custom external spam filter

I tried to do a search but couldn't find anything specifically about this. I want to write a script or an external program that does some spam checks and either returns a score or a yes/no spam result that then adds to the hMailServer spam score. Kind of like SpamAssassin, but I can't just emulate S...
by mikernet
2018-12-07 23:31
Forum: Development & alpha discussions
Topic: Whitelisting is not working
Replies: 4
Views: 2770

Re: Whitelisting is not working

It looks like you're right...I must have mixed it up with another setting somewhere. There was a discussion on here about being able to use wildcards in a field because it does a LIKE query so % worked in it, I can't remember what that was referencing now.

Either way, all good now :)
by mikernet
2018-12-07 20:18
Forum: Development & alpha discussions
Topic: Whitelisting is not working
Replies: 4
Views: 2770

Re: Whitelisting is not working

Nevermind I think I got it...at some point since I originally put in the entries hMailServer must have been updated to use * instead of % because the docs now say you use *. I'll give that a try and report back if I have any issues.
by mikernet
2018-12-07 20:07
Forum: Development & alpha discussions
Topic: Whitelisting is not working
Replies: 4
Views: 2770

Whitelisting is not working

I have two anti-spam whitelist entries as follows: 0.0.0.0 - 255.255.255.255: %@domain.com 0.0.0.0 - 255.255.255.255: %@sendgrid.net The email I'm trying to whitelist shows this information in the headers: From: something@domain.com Return-Path: bounces+2348723432-bed1-myemail=mydomain@sendgrid.net ...
by mikernet
2018-09-05 20:34
Forum: Scripting
Topic: LockFile Script Occasionally Throwing An Error
Replies: 4
Views: 1985

Re: LockFile Script Occasionally Throwing An Error

Haha yes indeed I am...thanks :) I searched and found several posts that had the LockFile function quoted in their code but no Wait function so I assumed it was built-in.
by mikernet
2018-09-04 23:09
Forum: SpamAssassin implementation discussions
Topic: HmailServer & SpamAssassin : The WinSock error code is 2.
Replies: 73
Views: 36213

Re: HmailServer & SpamAssassin : The WinSock error code is 2.

Has there been any updates to this issue? It's been a couple years and I'm still getting this.

Has your proxy that delays closing the socket fixed the issue superman20? Is there any chance we can get a copy of your proxy?