Skip to content

Commit

Permalink
Updates to spf.cpp and WebAdmin
Browse files Browse the repository at this point in the history
  • Loading branch information
SorenRR committed Aug 23, 2023
1 parent 64a1f3e commit 9395f17
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions hmailserver/installation/hMailServer.iss
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
[Setup]
AppName=hMailServer
AppVerName=hMailServer 5.6.9-B2607.79 (x86)
AppVerName=hMailServer 5.6.9-B2607.80 (x86)
AppCopyright=Copyright (C) 2023
DefaultDirName={pf}\hMailServer
DefaultGroupName=hMailServer
PrivilegesRequired=admin
OutputBaseFilename=hMailServer-5.6.9-B2607.79-(x86)
OutputBaseFilename=hMailServer-5.6.9-B2607.80-(x86)
SolidCompression=yes
WizardImageFile=setup.bmp
LicenseFile=license.rtf
Expand Down
3 changes: 2 additions & 1 deletion hmailserver/source/Server/Common/Application/Version.h
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#pragma once

#define HMAILSERVER_VERSION "5.6.9"
#define HMAILSERVER_BUILD "2607.79 (x86)"
#define HMAILSERVER_BUILD "2607.80 (x86)"

/*
[list=1]
Expand Down Expand Up @@ -82,5 +82,6 @@
[*]Update: Distinguish more clearly between helo/mailfrom SPF results/checks
[*]Experiment: Remove .NET 2.0 requirement during install.
[*]Update hm_smtp_antivirus.php issue #471
[*]OpenSSL 1.1.1u compiled with "no-ssl2 no-ssl3" since we don't support them.
[/list]
*/
5 changes: 2 additions & 3 deletions hmailserver/source/Server/SMTP/SPF/SPF.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,6 @@ namespace HM
int result = SPFQuery(family, BinaryIP, T2A(sSenderEmail), NULL, T2A(sHeloHost), NULL, NULL);

String sSPFResultString = SPFResultString(result);
String sIdentity = !sSenderEmail.IsEmpty() ? "mailfrom" : "helo";
String sResultMessage;

switch (result)
Expand Down Expand Up @@ -128,7 +127,7 @@ namespace HM
if (!sSenderEmail.IsEmpty())
sResult.Format(_T("Received-SPF: %s\r\n\tidentity=mailfrom;\r\n\tclient-ip=%s;\r\n\tenvelope-from=<%s>;\r\n"), sResultMessage.c_str(), sSenderIP.c_str(), sSenderEmail.c_str());
else
sResult.Format(_T("Received-SPF: %s\r\n\tidentity=helo;\r\n\tclient-ip=%s;\r\n\thelo=%s;\r\n"), sResultMessage.c_str(), sSenderIP.c_str(), sHeloHost.c_str());
sResult.Format(_T("Received-SPF: %s\r\n\tidentity=helo;\r\n\tclient-ip=%s;\r\n\thelo=%s;\r\n"), sResultMessage.c_str(), sSenderIP.c_str(), sHeloHost.c_str());

return sResult;
}
Expand All @@ -137,7 +136,7 @@ namespace HM
{
String sExplanation;

if (SPF::Instance()->Test("185.216.75.37", "[email protected]", sExplanation) != SPF::Pass)
if (SPF::Instance()->Test("185.216.75.37", "[email protected]", "mail.hmailserver.com", sExplanation) != SPF::Pass)
{
// Should be allowed.
throw;
Expand Down
2 changes: 1 addition & 1 deletion hmailserver/source/WebAdmin/include/functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ function PrintCheckboxRow($name, $caption, $checked, $disabled = false)
"
<tr>
<td>$caption</td>
<td><input type=\"checkbox\"' . $disabledstr . 'name=\"$name\" value=\"1\" $checked_text></td>
<td><input type=\"checkbox\"$disabledstr name=\"$name\" value=\"1\" $checked_text></td>
</tr>
";
}
Expand Down

0 comments on commit 9395f17

Please sign in to comment.