summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorklm1998-03-08 17:03:38 +0000
committerklm1998-03-08 17:03:38 +0000
commitbe9208323119b21d3fc03e895da42c8440f1f02f (patch)
treeadf1fc30d7626e17059cf81d264165c53aed36f3
parent2465b4fccbb8ccedfe80b6e04a0e2518e8713667 (diff)
downloadmailman-be9208323119b21d3fc03e895da42c8440f1f02f.tar.gz
mailman-be9208323119b21d3fc03e895da42c8440f1f02f.tar.zst
mailman-be9208323119b21d3fc03e895da42c8440f1f02f.zip
HTMLFormatter.FormatOneUser(): Use new ObscureEmail() routine to mask
the email address from web spiders, to thwart spam address scrapers. The url passed to the options script is always transfored, but the id presented textually only is when list.obscure_addresses is set.
-rw-r--r--Mailman/HTMLFormatter.py7
-rw-r--r--modules/mm_html.py7
2 files changed, 12 insertions, 2 deletions
diff --git a/Mailman/HTMLFormatter.py b/Mailman/HTMLFormatter.py
index 83b57dd9c..79322d9a7 100644
--- a/Mailman/HTMLFormatter.py
+++ b/Mailman/HTMLFormatter.py
@@ -49,8 +49,13 @@ class HTMLFormatter:
def FormatOneUser(person, me=self):
import htmlformat, os
+ id = mm_utils.ObscureEmail(person)
+ if me.obscure_addresses:
+ showing = mm_utils.ObscureEmail(person, for_text=1)
+ else:
+ showing = person
return htmlformat.Link(os.path.join(me.GetScriptURL('options'),
- person), person)
+ id), showing)
items = map(FormatOneUser, people)
# Just return the .Format() so this works until I finish
# converting everything to htmlformat...
diff --git a/modules/mm_html.py b/modules/mm_html.py
index 83b57dd9c..79322d9a7 100644
--- a/modules/mm_html.py
+++ b/modules/mm_html.py
@@ -49,8 +49,13 @@ class HTMLFormatter:
def FormatOneUser(person, me=self):
import htmlformat, os
+ id = mm_utils.ObscureEmail(person)
+ if me.obscure_addresses:
+ showing = mm_utils.ObscureEmail(person, for_text=1)
+ else:
+ showing = person
return htmlformat.Link(os.path.join(me.GetScriptURL('options'),
- person), person)
+ id), showing)
items = map(FormatOneUser, people)
# Just return the .Format() so this works until I finish
# converting everything to htmlformat...