domainaware / checkdmarc

A parser for SPF and DMARC DNS records
https://domainaware.github.io/checkdmarc
Apache License 2.0
245 stars 76 forks source link

tls true if starttls success #56

Closed G0ldwave closed 3 years ago

G0ldwave commented 3 years ago
#Snippet from get_mx_hosts, line 2169
try: 
    starttls = test_starttls(host["hostname"],
                            cache=STARTTLS_CACHE)
    if starttls:
        tls = True
    else:
        warnings.append("STARTTLS is not supported on {0}".format(
            host["hostname"]))
        tls = test_tls(host["hostname"], cache=TLS_CACHE)

    if not tls:
        warnings.append("SSL/TLS is not supported on {0}".format(
            host["hostname"]))
    host["tls"] = tls
    host["starttls"] = starttls
except DNSException as warning:

Why is tls being set to true, if starttls is successful. Isn't tls supposed to indicate if a connection to port 465 using SMTP_SSL is successful?