Fix: Pflicht-Footer in Outreach-Mails (UWG §7, DSGVO Art. 14, Anschrift)
This commit is contained in:
parent
ab197d3ca2
commit
5e0dcde523
1 changed files with 12 additions and 1 deletions
|
|
@ -98,11 +98,22 @@ def _build_message(to: str, subject: str, body: str, account: str, html: str = N
|
|||
return msg
|
||||
|
||||
|
||||
_LEGAL_FOOTER = (
|
||||
"\n\n---\n"
|
||||
"Ban Yaro | René Degelmann | Ringstr. 26, D-85560 Ebersberg\n"
|
||||
"Web: https://banyaro.app | Mail: partner@banyaro.app\n\n"
|
||||
"Datenschutzhinweis: Deine Kontaktdaten stammen aus deinem öffentlichen Profil. "
|
||||
"Verarbeitung auf Basis berechtigten Interesses (Art. 6 Abs. 1 lit. f DSGVO). "
|
||||
"Datenschutzerklärung: https://banyaro.app/datenschutz\n"
|
||||
"Widerspruch/Löschung: Einfach auf diese Mail antworten."
|
||||
)
|
||||
|
||||
|
||||
def _send_smtp(to: str, subject: str, body: str, account: str = "partner", html: str = None):
|
||||
acc = _ACCOUNTS.get(account) or _ACCOUNTS["partner"]
|
||||
if not acc["user"] or not acc["pass"]:
|
||||
raise RuntimeError(f"SMTP-Account '{account}' nicht konfiguriert.")
|
||||
msg = _build_message(to, subject, body, account, html=html)
|
||||
msg = _build_message(to, subject, body + _LEGAL_FOOTER, account, html=html)
|
||||
msg_bytes = msg.as_bytes()
|
||||
ctx = ssl.create_default_context()
|
||||
with smtplib.SMTP(_SMTP_HOST, _SMTP_PORT, timeout=15) as s:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue