Skip to content

Commit

Permalink
Will check enabled mail policies even if no MX.
Browse files Browse the repository at this point in the history
  • Loading branch information
Tor Vigesdal committed Oct 8, 2020
1 parent fb7bef6 commit 604c796
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Get-Domain-MailInfo.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -543,7 +543,8 @@ ForEach ( $domainname in $arrDomains )
{
# Next we try to resolve the MX and SPF records
$dominfoMXDet = fnMXRecord -domname $domainName If ( $dominfoMXDet ) { $dominfoMX = $true } Else {$dominfoMX = $false}

If ($dominfoMXDet) { $dominfoMX = $True } else { $dominfoMX = $false }

# If there is an MX record we check if the MX supports StartTLS
If ($CheckStartTLS -and $dominfoMXDet -ne $False) {
If (!$dominfoMXDet.StartsWith("Null MX") -and !$dominfoMXDet.StartsWith("[Invalid:]")) {
Expand Down

0 comments on commit 604c796

Please sign in to comment.