PR comments
This commit is contained in:
parent
33e83fc153
commit
44c77439c1
|
@ -1119,14 +1119,14 @@ def handle_reply(envelope, msg: Message, rcpt_to: str) -> (bool, str):
|
||||||
alias,
|
alias,
|
||||||
contact,
|
contact,
|
||||||
)
|
)
|
||||||
return (False, status.E504)
|
return False, status.E504
|
||||||
|
|
||||||
# Check if we need to reject or quarantine based on dmarc
|
# Check if we need to reject or quarantine based on dmarc
|
||||||
dmarc_delivery_status = apply_dmarc_policy_for_reply_phase(
|
dmarc_delivery_status = apply_dmarc_policy_for_reply_phase(
|
||||||
alias, contact, envelope, msg
|
alias, contact, envelope, msg
|
||||||
)
|
)
|
||||||
if dmarc_delivery_status is not None:
|
if dmarc_delivery_status is not None:
|
||||||
return (False, dmarc_delivery_status)
|
return False, dmarc_delivery_status
|
||||||
|
|
||||||
# Anti-spoofing
|
# Anti-spoofing
|
||||||
mailbox = get_mailbox_from_mail_from(mail_from, alias)
|
mailbox = get_mailbox_from_mail_from(mail_from, alias)
|
||||||
|
|
|
@ -182,7 +182,6 @@ def test_dmarc_reply_quarantine(flask_client, dmarc_result):
|
||||||
website_email="random-{}@nowhere.net".format(int(random.random())),
|
website_email="random-{}@nowhere.net".format(int(random.random())),
|
||||||
name="Name {}".format(int(random.random())),
|
name="Name {}".format(int(random.random())),
|
||||||
reply_email="random-{}@{}".format(random.random(), EMAIL_DOMAIN),
|
reply_email="random-{}@{}".format(random.random(), EMAIL_DOMAIN),
|
||||||
automatic_created=True,
|
|
||||||
)
|
)
|
||||||
Session.commit()
|
Session.commit()
|
||||||
msg = load_eml_file(
|
msg = load_eml_file(
|
||||||
|
|
Loading…
Reference in New Issue