Update mailman from 2.1.29 to 3.3.2
This commit is contained in:
parent
991869f0d4
commit
8615691fc6
351
0001-fix-test-syntax-error.patch
Normal file
351
0001-fix-test-syntax-error.patch
Normal file
@ -0,0 +1,351 @@
|
|||||||
|
From 2212bab26df1517f24920d27977ae882e9089f8e Mon Sep 17 00:00:00 2001
|
||||||
|
From: lei_ju <lj3074194431@163.com>
|
||||||
|
Date: Tue, 22 Dec 2020 20:01:20 +0800
|
||||||
|
Subject: [PATCH] fix test syntax error
|
||||||
|
|
||||||
|
|
||||||
|
diff --git a/src/mailman/commands/tests/test_cli_addmembers.py b/src/mailman/commands/tests/test_cli_addmembers.py
|
||||||
|
index 37e3864..9cbb564 100644
|
||||||
|
--- a/src/mailman/commands/tests/test_cli_addmembers.py
|
||||||
|
+++ b/src/mailman/commands/tests/test_cli_addmembers.py
|
||||||
|
@@ -45,7 +45,7 @@ class TestCLIAddMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: addmembers [OPTIONS] FILENAME LISTSPEC\n'
|
||||||
|
- 'Try \'addmembers --help\' for help.\n\n'
|
||||||
|
+ 'Try "addmembers --help" for help.\n\n'
|
||||||
|
'Error: No such list: bee.example.com\n')
|
||||||
|
|
||||||
|
def test_bad_filename(self):
|
||||||
|
@@ -54,8 +54,8 @@ class TestCLIAddMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: addmembers [OPTIONS] FILENAME LISTSPEC\n'
|
||||||
|
- 'Try \'addmembers --help\' for help.\n\n'
|
||||||
|
- 'Error: Invalid value for \'FILENAME\': Could not open '
|
||||||
|
+ 'Try "addmembers --help" for help.\n\n'
|
||||||
|
+ 'Error: Invalid value for "FILENAME": Could not open '
|
||||||
|
'file: bad: No such file or directory\n')
|
||||||
|
|
||||||
|
def test_already_subscribed_with_display_name(self):
|
||||||
|
@@ -243,8 +243,8 @@ class TestCLIAddMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: addmembers [OPTIONS] FILENAME LISTSPEC\n'
|
||||||
|
- 'Try \'addmembers --help\' for help.\n\n'
|
||||||
|
- 'Error: Invalid value for \'--delivery\' / \'-d\': '
|
||||||
|
+ 'Try "addmembers --help" for help.\n\n'
|
||||||
|
+ 'Error: Invalid value for "--delivery" / "-d": '
|
||||||
|
'invalid choice: bogus. (choose from regular, mime, '
|
||||||
|
'plain, summary, disabled)\n')
|
||||||
|
|
||||||
|
diff --git a/src/mailman/commands/tests/test_cli_conf.py b/src/mailman/commands/tests/test_cli_conf.py
|
||||||
|
index 2aeed0c..0c21548 100644
|
||||||
|
--- a/src/mailman/commands/tests/test_cli_conf.py
|
||||||
|
+++ b/src/mailman/commands/tests/test_cli_conf.py
|
||||||
|
@@ -40,7 +40,7 @@ class TestConf(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: conf [OPTIONS]\n'
|
||||||
|
- 'Try \'conf --help\' for help.\n\n'
|
||||||
|
+ 'Try "conf --help" for help.\n\n'
|
||||||
|
'Error: No such section: thissectiondoesnotexist\n')
|
||||||
|
|
||||||
|
def test_cannot_access_nonexistent_section_and_key(self):
|
||||||
|
@@ -50,7 +50,7 @@ class TestConf(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: conf [OPTIONS]\n'
|
||||||
|
- 'Try \'conf --help\' for help.\n\n'
|
||||||
|
+ 'Try "conf --help" for help.\n\n'
|
||||||
|
'Error: No such section: thissectiondoesnotexist\n')
|
||||||
|
|
||||||
|
def test_cannot_access_nonexistent_key(self):
|
||||||
|
@@ -60,7 +60,7 @@ class TestConf(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: conf [OPTIONS]\n'
|
||||||
|
- 'Try \'conf --help\' for help.\n\n'
|
||||||
|
+ 'Try "conf --help" for help.\n\n'
|
||||||
|
'Error: Section mailman: No such key: thiskeydoesnotexist\n')
|
||||||
|
|
||||||
|
def test_pushed_section_is_found(self):
|
||||||
|
diff --git a/src/mailman/commands/tests/test_cli_control.py b/src/mailman/commands/tests/test_cli_control.py
|
||||||
|
index 6222fb8..96948c7 100644
|
||||||
|
--- a/src/mailman/commands/tests/test_cli_control.py
|
||||||
|
+++ b/src/mailman/commands/tests/test_cli_control.py
|
||||||
|
@@ -254,7 +254,7 @@ class TestControl(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: start [OPTIONS]\n'
|
||||||
|
- 'Try \'start --help\' for help.\n\n'
|
||||||
|
+ 'Try "start --help" for help.\n\n'
|
||||||
|
'Error: A previous run of GNU Mailman did not exit cleanly '
|
||||||
|
'(stale_lock). Try using --force\n')
|
||||||
|
|
||||||
|
@@ -304,7 +304,7 @@ class TestControlSimple(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
results.output,
|
||||||
|
'Usage: start [OPTIONS]\n'
|
||||||
|
- 'Try \'start --help\' for help.\n\n'
|
||||||
|
+ 'Try "start --help" for help.\n\n'
|
||||||
|
'Error: GNU Mailman is already running\n')
|
||||||
|
|
||||||
|
def test_reopen(self):
|
||||||
|
diff --git a/src/mailman/commands/tests/test_cli_create.py b/src/mailman/commands/tests/test_cli_create.py
|
||||||
|
index b501976..6a3ab9b 100644
|
||||||
|
--- a/src/mailman/commands/tests/test_cli_create.py
|
||||||
|
+++ b/src/mailman/commands/tests/test_cli_create.py
|
||||||
|
@@ -41,7 +41,7 @@ class TestCreate(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: create [OPTIONS] LISTNAME\n'
|
||||||
|
- 'Try \'create --help\' for help.\n\n'
|
||||||
|
+ 'Try "create --help" for help.\n\n'
|
||||||
|
'Error: List already exists: ant@example.com\n')
|
||||||
|
|
||||||
|
def test_invalid_posting_address(self):
|
||||||
|
@@ -51,7 +51,7 @@ class TestCreate(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: create [OPTIONS] LISTNAME\n'
|
||||||
|
- 'Try \'create --help\' for help.\n\n'
|
||||||
|
+ 'Try "create --help" for help.\n\n'
|
||||||
|
'Error: Illegal list name: foo\n')
|
||||||
|
|
||||||
|
def test_invalid_owner_addresses(self):
|
||||||
|
@@ -62,7 +62,7 @@ class TestCreate(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: create [OPTIONS] LISTNAME\n'
|
||||||
|
- 'Try \'create --help\' for help.\n\n'
|
||||||
|
+ 'Try "create --help" for help.\n\n'
|
||||||
|
'Error: Illegal owner addresses: invalid\n')
|
||||||
|
|
||||||
|
def test_create_without_domain_option(self):
|
||||||
|
@@ -92,7 +92,7 @@ class TestCreate(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: create [OPTIONS] LISTNAME\n'
|
||||||
|
- 'Try \'create --help\' for help.\n\n'
|
||||||
|
+ 'Try "create --help" for help.\n\n'
|
||||||
|
'Error: Undefined domain: example.org\n')
|
||||||
|
|
||||||
|
def test_create_with_nodomain(self):
|
||||||
|
@@ -102,7 +102,7 @@ class TestCreate(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: create [OPTIONS] LISTNAME\n'
|
||||||
|
- 'Try \'create --help\' for help.\n\n'
|
||||||
|
+ 'Try "create --help" for help.\n\n'
|
||||||
|
'Error: Undefined domain: example.org\n')
|
||||||
|
|
||||||
|
|
||||||
|
diff --git a/src/mailman/commands/tests/test_cli_delmembers.py b/src/mailman/commands/tests/test_cli_delmembers.py
|
||||||
|
index e038e36..d5b6663 100644
|
||||||
|
--- a/src/mailman/commands/tests/test_cli_delmembers.py
|
||||||
|
+++ b/src/mailman/commands/tests/test_cli_delmembers.py
|
||||||
|
@@ -45,7 +45,7 @@ class TestCLIDelMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: delmembers [OPTIONS]\n'
|
||||||
|
- 'Try \'delmembers --help\' for help.\n\n'
|
||||||
|
+ 'Try "delmembers --help" for help.\n\n'
|
||||||
|
'Error: No such list: bee.example.com\n')
|
||||||
|
|
||||||
|
def test_bad_filename(self):
|
||||||
|
@@ -55,8 +55,8 @@ class TestCLIDelMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: delmembers [OPTIONS]\n'
|
||||||
|
- 'Try \'delmembers --help\' for help.\n\n'
|
||||||
|
- 'Error: Invalid value for \'--file\' / \'-f\': Could not open '
|
||||||
|
+ 'Try "delmembers --help" for help.\n\n'
|
||||||
|
+ 'Error: Invalid value for "--file" / "-f": Could not open '
|
||||||
|
'file: bad: No such file or directory\n')
|
||||||
|
|
||||||
|
def test_not_subscribed_without_display_name(self):
|
||||||
|
@@ -212,7 +212,7 @@ class TestCLIDelMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: delmembers [OPTIONS]\n'
|
||||||
|
- 'Try \'delmembers --help\' for help.\n\n'
|
||||||
|
+ 'Try "delmembers --help" for help.\n\n'
|
||||||
|
'Error: --fromall may not be specified with -l/--list, '
|
||||||
|
'or -a/--all\n')
|
||||||
|
|
||||||
|
@@ -223,7 +223,7 @@ class TestCLIDelMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: delmembers [OPTIONS]\n'
|
||||||
|
- 'Try \'delmembers --help\' for help.\n\n'
|
||||||
|
+ 'Try "delmembers --help" for help.\n\n'
|
||||||
|
'Error: --fromall may not be specified with -l/--list, '
|
||||||
|
'or -a/--all\n')
|
||||||
|
|
||||||
|
@@ -234,7 +234,7 @@ class TestCLIDelMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: delmembers [OPTIONS]\n'
|
||||||
|
- 'Try \'delmembers --help\' for help.\n\n'
|
||||||
|
+ 'Try "delmembers --help" for help.\n\n'
|
||||||
|
'Error: -a/--all must not be specified with '
|
||||||
|
'-f/--file or -m/--member.\n')
|
||||||
|
|
||||||
|
@@ -245,7 +245,7 @@ class TestCLIDelMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: delmembers [OPTIONS]\n'
|
||||||
|
- 'Try \'delmembers --help\' for help.\n\n'
|
||||||
|
+ 'Try "delmembers --help" for help.\n\n'
|
||||||
|
'Error: -a/--all must not be specified with '
|
||||||
|
'-f/--file or -m/--member.\n')
|
||||||
|
|
||||||
|
@@ -256,7 +256,7 @@ class TestCLIDelMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: delmembers [OPTIONS]\n'
|
||||||
|
- 'Try \'delmembers --help\' for help.\n\n'
|
||||||
|
+ 'Try "delmembers --help" for help.\n\n'
|
||||||
|
'Error: Without --fromall, -l/--list is required.\n')
|
||||||
|
|
||||||
|
def test_invalid_no_all_file_or_member(self):
|
||||||
|
@@ -266,7 +266,7 @@ class TestCLIDelMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: delmembers [OPTIONS]\n'
|
||||||
|
- 'Try \'delmembers --help\' for help.\n\n'
|
||||||
|
+ 'Try "delmembers --help" for help.\n\n'
|
||||||
|
'Error: At least one of -a/--all, -f/--file or -m/--member '
|
||||||
|
'is required.\n')
|
||||||
|
|
||||||
|
diff --git a/src/mailman/commands/tests/test_cli_import.py b/src/mailman/commands/tests/test_cli_import.py
|
||||||
|
index 3080691..4bb8602 100644
|
||||||
|
--- a/src/mailman/commands/tests/test_cli_import.py
|
||||||
|
+++ b/src/mailman/commands/tests/test_cli_import.py
|
||||||
|
@@ -58,8 +58,8 @@ class TestImport(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: import21 [OPTIONS] LISTSPEC PICKLE_FILE\n'
|
||||||
|
- 'Try \'import21 --help\' for help.\n\n'
|
||||||
|
- 'Error: Missing argument \'LISTSPEC\'.\n')
|
||||||
|
+ 'Try "import21 --help" for help.\n\n'
|
||||||
|
+ 'Error: Missing argument "LISTSPEC".\n')
|
||||||
|
|
||||||
|
def test_pickle_with_nondict(self):
|
||||||
|
with NamedTemporaryFile() as pckfile:
|
||||||
|
diff --git a/src/mailman/commands/tests/test_cli_inject.py b/src/mailman/commands/tests/test_cli_inject.py
|
||||||
|
index 637080b..2dec6ed 100644
|
||||||
|
--- a/src/mailman/commands/tests/test_cli_inject.py
|
||||||
|
+++ b/src/mailman/commands/tests/test_cli_inject.py
|
||||||
|
@@ -63,7 +63,7 @@ class TestInject(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: inject [OPTIONS] LISTSPEC\n'
|
||||||
|
- 'Try \'inject --help\' for help.\n\n'
|
||||||
|
+ 'Try "inject --help" for help.\n\n'
|
||||||
|
'Error: No such list: bee.example.com\n')
|
||||||
|
|
||||||
|
def test_inject_no_such_queue(self):
|
||||||
|
@@ -73,7 +73,7 @@ class TestInject(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: inject [OPTIONS] LISTSPEC\n'
|
||||||
|
- 'Try \'inject --help\' for help.\n\n'
|
||||||
|
+ 'Try "inject --help" for help.\n\n'
|
||||||
|
'Error: No such queue: bogus\n')
|
||||||
|
|
||||||
|
def test_inject_no_filename_option(self):
|
||||||
|
diff --git a/src/mailman/commands/tests/test_cli_members.py b/src/mailman/commands/tests/test_cli_members.py
|
||||||
|
index 18301f4..7eb5371 100644
|
||||||
|
--- a/src/mailman/commands/tests/test_cli_members.py
|
||||||
|
+++ b/src/mailman/commands/tests/test_cli_members.py
|
||||||
|
@@ -41,7 +41,7 @@ class TestCLIMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: members [OPTIONS] LISTSPEC\n'
|
||||||
|
- 'Try \'members --help\' for help.\n\n'
|
||||||
|
+ 'Try "members --help" for help.\n\n'
|
||||||
|
'Error: No such list: bee.example.com\n')
|
||||||
|
|
||||||
|
def test_role_administrator(self):
|
||||||
|
diff --git a/src/mailman/commands/tests/test_cli_shell.py b/src/mailman/commands/tests/test_cli_shell.py
|
||||||
|
index 3d2dd39..03f6509 100644
|
||||||
|
--- a/src/mailman/commands/tests/test_cli_shell.py
|
||||||
|
+++ b/src/mailman/commands/tests/test_cli_shell.py
|
||||||
|
@@ -142,7 +142,7 @@ Exit with ctrl+D does an implicit commit() but exit() does not.\n""")
|
||||||
|
self.assertEqual(
|
||||||
|
results.output,
|
||||||
|
'Usage: shell [OPTIONS] [RUN_ARGS]...\n'
|
||||||
|
- 'Try \'shell --help\' for help.\n\n'
|
||||||
|
+ 'Try "shell --help" for help.\n\n'
|
||||||
|
'Error: Regular expression requires --run\n')
|
||||||
|
|
||||||
|
def test_listspec_without_run(self):
|
||||||
|
@@ -165,7 +165,7 @@ Exit with ctrl+D does an implicit commit() but exit() does not.\n""")
|
||||||
|
self.assertEqual(
|
||||||
|
results.output,
|
||||||
|
'Usage: shell [OPTIONS] [RUN_ARGS]...\n'
|
||||||
|
- 'Try \'shell --help\' for help.\n\n'
|
||||||
|
+ 'Try "shell --help" for help.\n\n'
|
||||||
|
'Error: No such list: ant.example.com\n')
|
||||||
|
|
||||||
|
def test_run_without_listspec(self):
|
||||||
|
@@ -183,5 +183,5 @@ Exit with ctrl+D does an implicit commit() but exit() does not.\n""")
|
||||||
|
self.assertEqual(
|
||||||
|
results.output,
|
||||||
|
'Usage: shell [OPTIONS] [RUN_ARGS]...\n'
|
||||||
|
- 'Try \'shell --help\' for help.\n\n'
|
||||||
|
+ 'Try "shell --help" for help.\n\n'
|
||||||
|
'Error: No such list: bee.example.com\n')
|
||||||
|
diff --git a/src/mailman/commands/tests/test_cli_syncmembers.py b/src/mailman/commands/tests/test_cli_syncmembers.py
|
||||||
|
index e0d9caa..cf78cc5 100644
|
||||||
|
--- a/src/mailman/commands/tests/test_cli_syncmembers.py
|
||||||
|
+++ b/src/mailman/commands/tests/test_cli_syncmembers.py
|
||||||
|
@@ -48,7 +48,7 @@ class TestCLISyncMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: syncmembers [OPTIONS] FILENAME LISTSPEC\n'
|
||||||
|
- 'Try \'syncmembers --help\' for help.\n\n'
|
||||||
|
+ 'Try "syncmembers --help" for help.\n\n'
|
||||||
|
'Error: No such list: bee.example.com\n')
|
||||||
|
|
||||||
|
def test_bad_filename(self):
|
||||||
|
@@ -57,8 +57,8 @@ class TestCLISyncMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: syncmembers [OPTIONS] FILENAME LISTSPEC\n'
|
||||||
|
- 'Try \'syncmembers --help\' for help.\n\n'
|
||||||
|
- 'Error: Invalid value for \'FILENAME\': Could not open '
|
||||||
|
+ 'Try "syncmembers --help" for help.\n\n'
|
||||||
|
+ 'Error: Invalid value for "FILENAME": Could not open '
|
||||||
|
'file: bad: No such file or directory\n')
|
||||||
|
|
||||||
|
def test_sync_invalid_email(self):
|
||||||
|
@@ -372,8 +372,8 @@ class TestCLISyncMembers(unittest.TestCase):
|
||||||
|
self.assertEqual(
|
||||||
|
result.output,
|
||||||
|
'Usage: syncmembers [OPTIONS] FILENAME LISTSPEC\n'
|
||||||
|
- 'Try \'syncmembers --help\' for help.\n\n'
|
||||||
|
- 'Error: Invalid value for \'--delivery\' / \'-d\': '
|
||||||
|
+ 'Try "syncmembers --help" for help.\n\n'
|
||||||
|
+ 'Error: Invalid value for "--delivery" / "-d": '
|
||||||
|
'invalid choice: bogus. (choose from regular, mime, '
|
||||||
|
'plain, summary, disabled)\n')
|
||||||
|
|
||||||
|
diff --git a/src/mailman/database/alembic/versions/33e1f5f6fa8_.py b/src/mailman/database/alembic/versions/33e1f5f6fa8_.py
|
||||||
|
index 580e43c..e88c1b6 100644
|
||||||
|
--- a/src/mailman/database/alembic/versions/33e1f5f6fa8_.py
|
||||||
|
+++ b/src/mailman/database/alembic/versions/33e1f5f6fa8_.py
|
||||||
|
@@ -64,7 +64,7 @@ def downgrade():
|
||||||
|
# yet.
|
||||||
|
op.execute(
|
||||||
|
('ALTER TABLE "{table}" ALTER COLUMN "{column}" '
|
||||||
|
- 'TYPE BYTEA USING decode("{column}", \'UTF8\')').format(
|
||||||
|
+ 'TYPE BYTEA USING decode("{column}", "UTF8")').format(
|
||||||
|
table=table, column=column))
|
||||||
|
else:
|
||||||
|
op.alter_column(table, column, type_=sa.LargeBinary)
|
||||||
|
--
|
||||||
|
2.23.0
|
||||||
|
|
||||||
@ -1,27 +0,0 @@
|
|||||||
<VirtualHost *:80>
|
|
||||||
ServerName lists.example.com
|
|
||||||
DocumentRoot /var/www/lists
|
|
||||||
ErrorLog /var/log/apache2/lists-error.log
|
|
||||||
CustomLog /var/log/apache2/lists-access.log combined
|
|
||||||
|
|
||||||
<Directory /var/lib/mailman/archives/>
|
|
||||||
Options FollowSymLinks
|
|
||||||
AllowOverride None
|
|
||||||
</Directory>
|
|
||||||
|
|
||||||
Alias /pipermail/ /var/lib/mailman/archives/public/
|
|
||||||
Alias /images/mailman/ /usr/share/images/mailman/
|
|
||||||
ScriptAlias /admin /usr/lib/cgi-bin/mailman/admin
|
|
||||||
ScriptAlias /admindb /usr/lib/cgi-bin/mailman/admindb
|
|
||||||
ScriptAlias /confirm /usr/lib/cgi-bin/mailman/confirm
|
|
||||||
ScriptAlias /create /usr/lib/cgi-bin/mailman/create
|
|
||||||
ScriptAlias /edithtml /usr/lib/cgi-bin/mailman/edithtml
|
|
||||||
ScriptAlias /listinfo /usr/lib/cgi-bin/mailman/listinfo
|
|
||||||
ScriptAlias /options /usr/lib/cgi-bin/mailman/options
|
|
||||||
ScriptAlias /private /usr/lib/cgi-bin/mailman/private
|
|
||||||
ScriptAlias /rmlist /usr/lib/cgi-bin/mailman/rmlist
|
|
||||||
ScriptAlias /roster /usr/lib/cgi-bin/mailman/roster
|
|
||||||
ScriptAlias /subscribe /usr/lib/cgi-bin/mailman/subscribe
|
|
||||||
ScriptAlias /mailman/ /usr/lib/cgi-bin/mailman/
|
|
||||||
ScriptAlias / /usr/lib/cgi-bin/mailman/listinfo
|
|
||||||
</VirtualHost>
|
|
||||||
@ -1,715 +0,0 @@
|
|||||||
diff --git a/Mailman/Archiver/Makefile.in b/Mailman/Archiver/Makefile.in
|
|
||||||
index 65e46cb..dc3a1c6 100644
|
|
||||||
--- a/Mailman/Archiver/Makefile.in
|
|
||||||
+++ b/Mailman/Archiver/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -47,7 +46,7 @@ pipermail.py
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -63,8 +62,6 @@ install:
|
|
||||||
$(INSTALL) -m $(FILEMODE) $(srcdir)/$$f $(DESTDIR)$(PACKAGEDIR); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/Mailman/Bouncers/Makefile.in b/Mailman/Bouncers/Makefile.in
|
|
||||||
index 8865a9f..8878cd9 100644
|
|
||||||
--- a/Mailman/Bouncers/Makefile.in
|
|
||||||
+++ b/Mailman/Bouncers/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -45,7 +44,7 @@ MODULES= *.py
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -61,8 +60,6 @@ install:
|
|
||||||
$(INSTALL) -m $(FILEMODE) $(srcdir)/$$f $(DESTDIR)$(PACKAGEDIR); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/Mailman/Cgi/Makefile.in b/Mailman/Cgi/Makefile.in
|
|
||||||
index 47929e9..e20c07e 100644
|
|
||||||
--- a/Mailman/Cgi/Makefile.in
|
|
||||||
+++ b/Mailman/Cgi/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -47,7 +46,7 @@ CGI_MODULES= *.py
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -63,8 +62,6 @@ install:
|
|
||||||
$(INSTALL) -m $(FILEMODE) $(srcdir)/$$f $(DESTDIR)$(CGIDIR); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/Mailman/Commands/Makefile.in b/Mailman/Commands/Makefile.in
|
|
||||||
index 645d78b..12bbc1b 100644
|
|
||||||
--- a/Mailman/Commands/Makefile.in
|
|
||||||
+++ b/Mailman/Commands/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -45,7 +44,7 @@ MODULES= *.py
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -61,8 +60,6 @@ install:
|
|
||||||
$(INSTALL) -m $(FILEMODE) $(srcdir)/$$f $(DESTDIR)$(PACKAGEDIR); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/Mailman/Gui/Makefile.in b/Mailman/Gui/Makefile.in
|
|
||||||
index 000441e..9273b8a 100644
|
|
||||||
--- a/Mailman/Gui/Makefile.in
|
|
||||||
+++ b/Mailman/Gui/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -45,7 +44,7 @@ MODULES= *.py
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -61,8 +60,6 @@ install:
|
|
||||||
$(INSTALL) -m $(FILEMODE) $(srcdir)/$$f $(DESTDIR)$(PACKAGEDIR); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/Mailman/Handlers/Makefile.in b/Mailman/Handlers/Makefile.in
|
|
||||||
index 71e5576..56ee2eb 100644
|
|
||||||
--- a/Mailman/Handlers/Makefile.in
|
|
||||||
+++ b/Mailman/Handlers/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -45,7 +44,7 @@ MODULES= *.py
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -61,8 +60,6 @@ install:
|
|
||||||
$(INSTALL) -m $(FILEMODE) $(srcdir)/$$f $(DESTDIR)$(PACKAGEDIR); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/Mailman/Logging/Makefile.in b/Mailman/Logging/Makefile.in
|
|
||||||
index e185775..ad5c128 100644
|
|
||||||
--- a/Mailman/Logging/Makefile.in
|
|
||||||
+++ b/Mailman/Logging/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -45,7 +44,7 @@ MODULES= *.py
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -61,8 +60,6 @@ install:
|
|
||||||
$(INSTALL) -m $(FILEMODE) $(srcdir)/$$f $(DESTDIR)$(PACKAGEDIR); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/Mailman/MTA/Makefile.in b/Mailman/MTA/Makefile.in
|
|
||||||
index 0338806..e1de296 100644
|
|
||||||
--- a/Mailman/MTA/Makefile.in
|
|
||||||
+++ b/Mailman/MTA/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -45,7 +44,7 @@ MODULES= *.py
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -61,8 +60,6 @@ install:
|
|
||||||
$(INSTALL) -m $(FILEMODE) $(srcdir)/$$f $(DESTDIR)$(PACKAGEDIR); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/Mailman/Makefile.in b/Mailman/Makefile.in
|
|
||||||
index 93c7efd..45439f0 100644
|
|
||||||
--- a/Mailman/Makefile.in
|
|
||||||
+++ b/Mailman/Makefile.in
|
|
||||||
@@ -20,8 +20,6 @@
|
|
||||||
|
|
||||||
# Variables set by configure
|
|
||||||
|
|
||||||
-VERSION= @VERSION@
|
|
||||||
-
|
|
||||||
VPATH= @srcdir@
|
|
||||||
srcdir= @srcdir@
|
|
||||||
bindir= @bindir@
|
|
||||||
@@ -30,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -48,7 +45,7 @@ SUBDIRS= Cgi Logging Archiver Handlers Bouncers Queue MTA Gui Commands
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -79,12 +76,6 @@ install: install-here
|
|
||||||
(cd $$d; $(MAKE) DESTDIR=$(DESTDIR) install); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
- @for d in $(SUBDIRS); \
|
|
||||||
- do \
|
|
||||||
- (cd $$d; $(MAKE) DESTDIR=$(DESTDIR) finish); \
|
|
||||||
- done
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
for d in $(SUBDIRS); \
|
|
||||||
do \
|
|
||||||
diff --git a/Mailman/Queue/Makefile.in b/Mailman/Queue/Makefile.in
|
|
||||||
index 179f3d9..e0e97ad 100644
|
|
||||||
--- a/Mailman/Queue/Makefile.in
|
|
||||||
+++ b/Mailman/Queue/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -45,7 +44,7 @@ MODULES= *.py
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -61,8 +60,6 @@ install:
|
|
||||||
$(INSTALL) -m $(FILEMODE) $(srcdir)/$$f $(DESTDIR)$(PACKAGEDIR); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/Makefile.in b/Makefile.in
|
|
||||||
index 40e04f5..eb40844 100644
|
|
||||||
--- a/Makefile.in
|
|
||||||
+++ b/Makefile.in
|
|
||||||
@@ -61,11 +61,10 @@ SUBDIRS= bin cron misc Mailman scripts src templates messages tests
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
-DIRSETGID= chmod g+s
|
|
||||||
|
|
||||||
DATE = $(shell python -c 'import time; print time.strftime("%d-%b-%Y"),')
|
|
||||||
LANGPACK = README-I18N.en templates messages
|
|
||||||
@@ -85,14 +84,24 @@ install: doinstall update
|
|
||||||
|
|
||||||
doinstall: $(SUBDIRS)
|
|
||||||
@echo "Creating architecture independent directories..."
|
|
||||||
+ dir=$(DESTDIR)$(prefix); \
|
|
||||||
+ if test ! -d $$dir; then \
|
|
||||||
+ echo "Creating directory hierarchy $$dir"; \
|
|
||||||
+ $(INSTALL) -d -m $(DIRMODE) $$dir; \
|
|
||||||
+ else true; \
|
|
||||||
+ fi;
|
|
||||||
+ dir=$(DESTDIR)$(var_prefix); \
|
|
||||||
+ if test ! -d $$dir; then \
|
|
||||||
+ echo "Creating directory hierarchy $$dir"; \
|
|
||||||
+ $(INSTALL) -d -m $(DIRMODE) $$dir; \
|
|
||||||
+ else true; \
|
|
||||||
+ fi;
|
|
||||||
@for d in $(VAR_DIRS); \
|
|
||||||
do \
|
|
||||||
dir=$(DESTDIR)$(var_prefix)/$$d; \
|
|
||||||
if test ! -d $$dir; then \
|
|
||||||
echo "Creating directory hierarchy $$dir"; \
|
|
||||||
- $(srcdir)/mkinstalldirs $$dir; \
|
|
||||||
- chmod $(DIRMODE) $$dir; \
|
|
||||||
- $(DIRSETGID) $$dir; \
|
|
||||||
+ $(INSTALL) -d -m $(DIRMODE) $$dir; \
|
|
||||||
else true; \
|
|
||||||
fi; \
|
|
||||||
done
|
|
||||||
@@ -102,9 +111,7 @@ doinstall: $(SUBDIRS)
|
|
||||||
dir=$(DESTDIR)$(prefix)/$$d; \
|
|
||||||
if test ! -d $$dir; then \
|
|
||||||
echo "Creating directory hierarchy $$dir"; \
|
|
||||||
- $(srcdir)/mkinstalldirs $$dir; \
|
|
||||||
- chmod $(DIRMODE) $$dir; \
|
|
||||||
- $(DIRSETGID) $$dir; \
|
|
||||||
+ $(INSTALL) -d -m $(DIRMODE) $$dir; \
|
|
||||||
else true; \
|
|
||||||
fi; \
|
|
||||||
done
|
|
||||||
@@ -114,9 +121,7 @@ doinstall: $(SUBDIRS)
|
|
||||||
dir=$(DESTDIR)$(exec_prefix)/$$d; \
|
|
||||||
if test ! -d $$dir; then \
|
|
||||||
echo "Creating directory hierarchy $$dir"; \
|
|
||||||
- $(srcdir)/mkinstalldirs $$dir; \
|
|
||||||
- chmod $(DIRMODE) $$dir; \
|
|
||||||
- $(DIRSETGID) $$dir; \
|
|
||||||
+ $(INSTALL) -d -m $(DIRMODE) $$dir; \
|
|
||||||
else true; \
|
|
||||||
fi; \
|
|
||||||
done
|
|
||||||
diff --git a/bin/Makefile.in b/bin/Makefile.in
|
|
||||||
index 22c24b0..d795333 100644
|
|
||||||
--- a/bin/Makefile.in
|
|
||||||
+++ b/bin/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -56,7 +55,7 @@ BUILDDIR= ../build/bin
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -72,8 +71,6 @@ install:
|
|
||||||
$(INSTALL) -m $(EXEMODE) $(BUILDDIR)/$$f $(DESTDIR)$(SCRIPTSDIR); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/cron/Makefile.in b/cron/Makefile.in
|
|
||||||
index 2a7c8fd..c14d119 100644
|
|
||||||
--- a/cron/Makefile.in
|
|
||||||
+++ b/cron/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -68,8 +67,6 @@ install:
|
|
||||||
$(INSTALL) -m $(EXEMODE) $(BUILDDIR)/$$f $(DESTDIR)$(CRONDIR); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/messages/Makefile.in b/messages/Makefile.in
|
|
||||||
index 2bbec3f..0b8b7d6 100644
|
|
||||||
--- a/messages/Makefile.in
|
|
||||||
+++ b/messages/Makefile.in
|
|
||||||
@@ -32,7 +32,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -43,7 +42,6 @@ OPT= @OPT@
|
|
||||||
CFLAGS= $(OPT) $(DEFS)
|
|
||||||
PACKAGEDIR= $(prefix)/messages
|
|
||||||
SHELL= /bin/sh
|
|
||||||
-DIRSETGID= chmod g+s
|
|
||||||
MSGFMT= @PYTHON@ ../build/bin/msgfmt.py
|
|
||||||
MSGMERGE= msgmerge
|
|
||||||
|
|
||||||
@@ -60,7 +58,7 @@ TARGETS= $(MOFILES)
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -90,9 +88,8 @@ doinstall: mofiles
|
|
||||||
do \
|
|
||||||
dir=$(DESTDIR)$(prefix)/$$d; \
|
|
||||||
echo "Creating language directory $$dir"; \
|
|
||||||
- $(srcdir)/../mkinstalldirs $$dir; \
|
|
||||||
- chmod $(DIRMODE) $$dir; \
|
|
||||||
- $(DIRSETGID) $$dir; \
|
|
||||||
+ $(INSTALL) -d -m $(DIRMODE) `dirname $$dir`; \
|
|
||||||
+ $(INSTALL) -d -m $(DIRMODE) $$dir; \
|
|
||||||
done
|
|
||||||
@for d in $(LANGUAGES); \
|
|
||||||
do \
|
|
||||||
@@ -113,8 +110,6 @@ doinstall: mofiles
|
|
||||||
|
|
||||||
mofiles: $(MOFILES)
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
-rm -f */LC_MESSAGES/mailman.mo
|
|
||||||
|
|
||||||
diff --git a/misc/Makefile.in b/misc/Makefile.in
|
|
||||||
index 5125cd8..af99c04 100644
|
|
||||||
--- a/misc/Makefile.in
|
|
||||||
+++ b/misc/Makefile.in
|
|
||||||
@@ -30,7 +30,6 @@ var_prefix= @VAR_PREFIX@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
PYTHON= @PYTHON@
|
|
||||||
|
|
||||||
@@ -62,7 +61,7 @@ PACKAGES= $(EMAILPKG) $(JACODECSPKG) $(KOCODECSPKG)
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
DATAMODE= 664
|
|
||||||
@@ -101,8 +100,6 @@ install-packages:
|
|
||||||
(cd $(PKGDIR)/$$p ; umask 02 ; PYTHONPATH=$(PYTHONLIBDIR) $(PYTHON) $(SETUPCMD)); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/scripts/Makefile.in b/scripts/Makefile.in
|
|
||||||
index 49b82ec..cea250c 100644
|
|
||||||
--- a/scripts/Makefile.in
|
|
||||||
+++ b/scripts/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -49,7 +48,7 @@ SCRIPTS= bounces confirm driver join leave owner post request
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -68,8 +67,6 @@ install:
|
|
||||||
$(INSTALL) -m $(FILEMODE) $(srcdir)/join $(DESTDIR)$(SCRIPTSDIR)/subscribe
|
|
||||||
$(INSTALL) -m $(FILEMODE) $(srcdir)/leave $(DESTDIR)$(SCRIPTSDIR)/unsubscribe
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/src/Makefile.in b/src/Makefile.in
|
|
||||||
index ce52356..7ed820b 100644
|
|
||||||
--- a/src/Makefile.in
|
|
||||||
+++ b/src/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ bindir= @bindir@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
PYTHON= @PYTHON@
|
|
||||||
|
|
||||||
@@ -65,10 +64,9 @@ COMMON_FLAGS= -DPREFIX="\"$(prefix)\"" \
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
-EXEMODE= 755
|
|
||||||
+DIRMODE= 2775
|
|
||||||
+EXEMODE= 2755
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
-DIRSETGID= chmod g+s
|
|
||||||
|
|
||||||
# Fixed definitions
|
|
||||||
|
|
||||||
@@ -112,20 +110,10 @@ install: all
|
|
||||||
do \
|
|
||||||
exe=$(DESTDIR)$(CGIDIR)/$$f$(CGIEXT); \
|
|
||||||
$(INSTALL_PROGRAM) $$f $$exe; \
|
|
||||||
- $(DIRSETGID) $$exe; \
|
|
||||||
done
|
|
||||||
for f in $(MAIL_PROGS); \
|
|
||||||
do \
|
|
||||||
$(INSTALL_PROGRAM) $$f $(DESTDIR)$(MAILDIR); \
|
|
||||||
- $(DIRSETGID) $(DESTDIR)$(MAILDIR)/$$f; \
|
|
||||||
- done
|
|
||||||
-
|
|
||||||
-finish:
|
|
||||||
- -for f in $(SUID_CGI_PROGS); \
|
|
||||||
- do \
|
|
||||||
- exe=$(DESTDIR)$(CGIDIR)/$$f$(CGIEXT); \
|
|
||||||
- chown $(MAILMAN_USER) $$exe; \
|
|
||||||
- chmod u+s $$exe; \
|
|
||||||
done
|
|
||||||
|
|
||||||
clean:
|
|
||||||
diff --git a/templates/Makefile.in b/templates/Makefile.in
|
|
||||||
index 3dfee3a..b23d7c1 100644
|
|
||||||
--- a/templates/Makefile.in
|
|
||||||
+++ b/templates/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
TRUE= @TRUE@
|
|
||||||
|
|
||||||
@@ -48,7 +47,7 @@ LANGUAGES= ar ast ca cs da de el en es et eu fi fr gl he hr hu ia it ja \
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -61,15 +60,13 @@ all:
|
|
||||||
install:
|
|
||||||
for d in $(LANGUAGES); \
|
|
||||||
do \
|
|
||||||
- $(srcdir)/../mkinstalldirs $(DESTDIR)$(TEMPLATEDIR)/$$d; \
|
|
||||||
+ $(INSTALL) -d -m $(DIRMODE) $(DESTDIR)$(TEMPLATEDIR)/$$d; \
|
|
||||||
for f in $(srcdir)/$$d/*.html $(srcdir)/$$d/*.txt; \
|
|
||||||
do \
|
|
||||||
$(INSTALL) -m $(FILEMODE) $$f $(DESTDIR)$(TEMPLATEDIR)/$$d; \
|
|
||||||
done; \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/tests/Makefile.in b/tests/Makefile.in
|
|
||||||
index 26d6e31..ca92425 100644
|
|
||||||
--- a/tests/Makefile.in
|
|
||||||
+++ b/tests/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -46,7 +45,7 @@ EXECS= $(srcdir)/onebounce.py $(srcdir)/fblast.py
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -71,8 +70,6 @@ install:
|
|
||||||
(cd $$d; $(MAKE) DESTDIR=$(DESTDIR) install); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/tests/bounces/Makefile.in b/tests/bounces/Makefile.in
|
|
||||||
index 5798097..f7014cb 100644
|
|
||||||
--- a/tests/bounces/Makefile.in
|
|
||||||
+++ b/tests/bounces/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -46,7 +45,7 @@ BOUNCE_FILES= $(srcdir)/*.txt
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -60,8 +59,6 @@ install:
|
|
||||||
$(INSTALL) -m $(FILEMODE) $$f $(DESTDIR)$(BOUNCEDIR); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
diff --git a/tests/msgs/Makefile.in b/tests/msgs/Makefile.in
|
|
||||||
index 736d721..edef5ae 100644
|
|
||||||
--- a/tests/msgs/Makefile.in
|
|
||||||
+++ b/tests/msgs/Makefile.in
|
|
||||||
@@ -28,7 +28,6 @@ exec_prefix= @exec_prefix@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
-CHMOD= @CHMOD@
|
|
||||||
INSTALL= @INSTALL@
|
|
||||||
|
|
||||||
DEFS= @DEFS@
|
|
||||||
@@ -46,7 +45,7 @@ MSG_FILES= $(srcdir)/*.txt
|
|
||||||
# Modes for directories and executables created by the install
|
|
||||||
# process. Default to group-writable directories but
|
|
||||||
# user-only-writable for executables.
|
|
||||||
-DIRMODE= 775
|
|
||||||
+DIRMODE= 2775
|
|
||||||
EXEMODE= 755
|
|
||||||
FILEMODE= 644
|
|
||||||
INSTALL_PROGRAM=$(INSTALL) -m $(EXEMODE)
|
|
||||||
@@ -60,8 +59,6 @@ install:
|
|
||||||
$(INSTALL) -m $(FILEMODE) $$f $(DESTDIR)$(MSGSDIR); \
|
|
||||||
done
|
|
||||||
|
|
||||||
-finish:
|
|
||||||
-
|
|
||||||
clean:
|
|
||||||
|
|
||||||
distclean:
|
|
||||||
@ -1,109 +0,0 @@
|
|||||||
diff --git a/bin/mailmanctl b/bin/mailmanctl
|
|
||||||
index fa14a2c..e291df1 100644
|
|
||||||
--- a/bin/mailmanctl
|
|
||||||
+++ b/bin/mailmanctl
|
|
||||||
@@ -36,7 +36,7 @@ in the file data/master-qrunner.pid but you normally don't need to use this
|
|
||||||
pid directly. The `start', `stop', `restart', and `reopen' commands handle
|
|
||||||
everything for you.
|
|
||||||
|
|
||||||
-Usage: %(PROGRAM)s [options] [ start | stop | restart | reopen ]
|
|
||||||
+Usage: %(PROGRAM)s [options] [ start | stop | restart | reopen | status ]
|
|
||||||
|
|
||||||
Options:
|
|
||||||
|
|
||||||
@@ -90,6 +90,9 @@ Commands:
|
|
||||||
|
|
||||||
reopen - This will close all log files, causing them to be re-opened the
|
|
||||||
next time a message is written to them
|
|
||||||
+
|
|
||||||
+ status - This returns a string indicating the status of the master
|
|
||||||
+ qrunner
|
|
||||||
"""
|
|
||||||
|
|
||||||
import sys
|
|
||||||
@@ -190,6 +193,52 @@ def qrunner_state():
|
|
||||||
return 0
|
|
||||||
return 1
|
|
||||||
|
|
||||||
+def mailman_status():
|
|
||||||
+ # return status, pid
|
|
||||||
+ #
|
|
||||||
+ # These status values match the /etc/init.d status values
|
|
||||||
+ # (at least on Red Hat), try to return equivalent status if possible
|
|
||||||
+ # status is 0 if running,
|
|
||||||
+ # status is 1 if dead but pid file exists
|
|
||||||
+ # status is 2 if dead but subsys locked
|
|
||||||
+ # status is 3 if stopped (pid returned will be 0)
|
|
||||||
+ #
|
|
||||||
+ #
|
|
||||||
+ # We want any user to be able to query the status and this presents
|
|
||||||
+ # few interesting permission problems and is why we don't use
|
|
||||||
+ # qrunner_state(). The pidfile is only readable by the mailman owner
|
|
||||||
+ # and group, however the lockfile is world readable. So we will
|
|
||||||
+ # get the master pid from the lockfile. We try to determine if the
|
|
||||||
+ # master process exists by sending it a signal. If we don't have
|
|
||||||
+ # permission to signal the process, but the process exists we'll
|
|
||||||
+ # get a EPERM error, if the process does not exist then we'll get
|
|
||||||
+ # a ESRCH error.
|
|
||||||
+
|
|
||||||
+ try:
|
|
||||||
+ hostname, pid, tempfile = get_lock_data()
|
|
||||||
+ except IOError, e:
|
|
||||||
+ if e.errno == errno.ENOENT:
|
|
||||||
+ # Lock file didn't exist, can't be running
|
|
||||||
+ return 3, 0
|
|
||||||
+ else:
|
|
||||||
+ raise
|
|
||||||
+ if hostname <> socket.gethostname():
|
|
||||||
+ # not running on this host
|
|
||||||
+ return 3, 0
|
|
||||||
+ # Find out if the process exists by calling kill with a signal 0.
|
|
||||||
+ try:
|
|
||||||
+ os.kill(pid, 0)
|
|
||||||
+ except OSError, e:
|
|
||||||
+ if e.errno == errno.ESRCH:
|
|
||||||
+ # process does not exist
|
|
||||||
+ return 1, pid
|
|
||||||
+ elif e.errno == errno.EPERM:
|
|
||||||
+ # we don't have permission signal the process but it exists
|
|
||||||
+ return 0, pid
|
|
||||||
+ else:
|
|
||||||
+ raise
|
|
||||||
+ return 0, pid
|
|
||||||
+
|
|
||||||
|
|
||||||
def acquire_lock_1(force):
|
|
||||||
# Be sure we can acquire the master qrunner lock. If not, it means some
|
|
||||||
@@ -338,13 +387,15 @@ def main():
|
|
||||||
command = COMMASPACE.join(args)
|
|
||||||
usage(1, C_('Bad command: %(command)s'))
|
|
||||||
|
|
||||||
+ command = args[0].lower()
|
|
||||||
+
|
|
||||||
if checkprivs:
|
|
||||||
check_privs()
|
|
||||||
else:
|
|
||||||
- print C_('Warning! You may encounter permission problems.')
|
|
||||||
+ if command != 'status':
|
|
||||||
+ print C_('Warning! You may encounter permission problems.')
|
|
||||||
|
|
||||||
# Handle the commands
|
|
||||||
- command = args[0].lower()
|
|
||||||
if command == 'stop':
|
|
||||||
# Sent the master qrunner process a SIGINT, which is equivalent to
|
|
||||||
# giving cron/qrunner a ctrl-c or KeyboardInterrupt. This will
|
|
||||||
@@ -363,6 +414,14 @@ def main():
|
|
||||||
if not quiet:
|
|
||||||
print C_('Re-opening all log files')
|
|
||||||
kill_watcher(signal.SIGHUP)
|
|
||||||
+ elif command == 'status':
|
|
||||||
+ status, pid = mailman_status()
|
|
||||||
+ if not quiet:
|
|
||||||
+ if status == 0:
|
|
||||||
+ print C_("mailman (pid %(pid)d) is running...")
|
|
||||||
+ else:
|
|
||||||
+ print C_("mailman is stopped")
|
|
||||||
+ sys.exit(status)
|
|
||||||
elif command == 'start':
|
|
||||||
# First, complain loudly if there's no site list.
|
|
||||||
check_for_site_list()
|
|
||||||
@ -1,142 +0,0 @@
|
|||||||
diff --git a/cron/crontab.in.in b/cron/crontab.in.in
|
|
||||||
index 540dfc1..45c5022 100644
|
|
||||||
--- a/cron/crontab.in.in
|
|
||||||
+++ b/cron/crontab.in.in
|
|
||||||
@@ -1,27 +1,50 @@
|
|
||||||
+#
|
|
||||||
+# -- WARNING -- WARNING -- WARNING -- WARNING -- WARNING -- WARNING --
|
|
||||||
+# ------------------ EDIT THE CORRECT FILE -------------------------
|
|
||||||
+#
|
|
||||||
+# This file is copied to /etc/cron.d/mailman from
|
|
||||||
+# @prefix@/cron/crontab.in when the mailman service is started via its
|
|
||||||
+# init.d script and the file /etc/cron.d/mailman is removed when the
|
|
||||||
+# service is stopped. Therefore any edits made directly to
|
|
||||||
+# /etc/cron.d/mailman will be lost anytime the mailman service
|
|
||||||
+# restarts.
|
|
||||||
+#
|
|
||||||
+# To make changes edit the master copy @prefix@/cron/crontab.in and then
|
|
||||||
+# restart the service to pick up the changes (/sbin/service mailman restart).
|
|
||||||
+#
|
|
||||||
+# The reason this is done this way is because the mailman cron jobs
|
|
||||||
+# should only be invoked if the mailman service is enabled and not
|
|
||||||
+# just as a consequence of installing the rpm as was the case
|
|
||||||
+# previously. The file /etc/cron.d/mailman cannot simply be linked to
|
|
||||||
+# the master copy in @prefix@/cron because for security reasons cron
|
|
||||||
+# will not process crontab files that are links or writeable by
|
|
||||||
+# anybody else but root, thus the file must be copied into /etc/cron.d
|
|
||||||
+# with the right ownership and permissions.
|
|
||||||
+#
|
|
||||||
# At 8AM every day, mail reminders to admins as to pending requests.
|
|
||||||
# They are less likely to ignore these reminders if they're mailed
|
|
||||||
# early in the morning, but of course, this is local time... ;)
|
|
||||||
-0 8 * * * @PYTHON@ -S @prefix@/cron/checkdbs
|
|
||||||
+0 8 * * * @MAILMAN_USER@ @prefix@/cron/checkdbs
|
|
||||||
#
|
|
||||||
# At 9AM, send notifications to disabled members that are due to be
|
|
||||||
# reminded to re-enable their accounts.
|
|
||||||
-0 9 * * * @PYTHON@ -S @prefix@/cron/disabled
|
|
||||||
+0 9 * * * @MAILMAN_USER@ @prefix@/cron/disabled
|
|
||||||
#
|
|
||||||
# Noon, mail digests for lists that do periodic as well as threshhold delivery.
|
|
||||||
-0 12 * * * @PYTHON@ -S @prefix@/cron/senddigests
|
|
||||||
+0 12 * * * @MAILMAN_USER@ @prefix@/cron/senddigests
|
|
||||||
#
|
|
||||||
# 5 AM on the first of each month, mail out password reminders.
|
|
||||||
-0 5 1 * * @PYTHON@ -S @prefix@/cron/mailpasswds
|
|
||||||
+0 5 1 * * @MAILMAN_USER@ @prefix@/cron/mailpasswds
|
|
||||||
#
|
|
||||||
# Every 5 mins, try to gate news to mail. You can comment this one out
|
|
||||||
# if you don't want to allow gating, or don't have any going on right now,
|
|
||||||
# or want to exclusively use a callback strategy instead of polling.
|
|
||||||
-0,5,10,15,20,25,30,35,40,45,50,55 * * * * @PYTHON@ -S @prefix@/cron/gate_news
|
|
||||||
+0,5,10,15,20,25,30,35,40,45,50,55 * * * * @MAILMAN_USER@ @prefix@/cron/gate_news
|
|
||||||
#
|
|
||||||
# At 3:27am every night, regenerate the gzip'd archive file. Only
|
|
||||||
# turn this on if the internal archiver is used and
|
|
||||||
# GZIP_ARCHIVE_TXT_FILES is false in mm_cfg.py
|
|
||||||
-27 3 * * * @PYTHON@ -S @prefix@/cron/nightly_gzip
|
|
||||||
+27 3 * * * @MAILMAN_USER@ @prefix@/cron/nightly_gzip
|
|
||||||
#
|
|
||||||
# At 4:30AM daily, cull old entries from the 'bad' and 'shunt' queues.
|
|
||||||
-30 4 * * * @PYTHON@ -S @prefix@/cron/cull_bad_shunt
|
|
||||||
+30 4 * * * @MAILMAN_USER@ @prefix@/cron/cull_bad_shunt
|
|
||||||
diff --git a/cron/bumpdigests b/cron/bumpdigests
|
|
||||||
index da5597b..7be0d14 100755
|
|
||||||
--- a/cron/bumpdigests
|
|
||||||
+++ b/cron/bumpdigests
|
|
||||||
@@ -1,4 +1,4 @@
|
|
||||||
-#! @PYTHON@
|
|
||||||
+#! @PYTHON@ -S
|
|
||||||
#
|
|
||||||
# Copyright (C) 1998-2018 by the Free Software Foundation, Inc.
|
|
||||||
#
|
|
||||||
diff --git a/cron/checkdbs b/cron/checkdbs
|
|
||||||
index 1a3b3cc..d6a521a 100755
|
|
||||||
--- a/cron/checkdbs
|
|
||||||
+++ b/cron/checkdbs
|
|
||||||
@@ -1,4 +1,4 @@
|
|
||||||
-#! @PYTHON@
|
|
||||||
+#! @PYTHON@ -S
|
|
||||||
#
|
|
||||||
# Copyright (C) 1998-2018 by the Free Software Foundation, Inc.
|
|
||||||
#
|
|
||||||
diff --git a/cron/cull_bad_shunt b/cron/cull_bad_shunt
|
|
||||||
index eaef0a6..0eeb1fe 100755
|
|
||||||
--- a/cron/cull_bad_shunt
|
|
||||||
+++ b/cron/cull_bad_shunt
|
|
||||||
@@ -1,4 +1,4 @@
|
|
||||||
-#! @PYTHON@
|
|
||||||
+#! @PYTHON@ -S
|
|
||||||
#
|
|
||||||
# Copyright (C) 2008-2018 by the Free Software Foundation, Inc.
|
|
||||||
#
|
|
||||||
diff --git a/cron/disabled b/cron/disabled
|
|
||||||
index ebd4027..f8a6441 100755
|
|
||||||
--- a/cron/disabled
|
|
||||||
+++ b/cron/disabled
|
|
||||||
@@ -1,4 +1,4 @@
|
|
||||||
-#! @PYTHON@
|
|
||||||
+#! @PYTHON@ -S
|
|
||||||
#
|
|
||||||
# Copyright (C) 2001-2018 by the Free Software Foundation, Inc.
|
|
||||||
#
|
|
||||||
diff --git a/cron/gate_news b/cron/gate_news
|
|
||||||
index 22caea7..74dca5e 100755
|
|
||||||
--- a/cron/gate_news
|
|
||||||
+++ b/cron/gate_news
|
|
||||||
@@ -1,4 +1,4 @@
|
|
||||||
-#! @PYTHON@
|
|
||||||
+#! @PYTHON@ -S
|
|
||||||
#
|
|
||||||
# Copyright (C) 1998-2018 by the Free Software Foundation, Inc.
|
|
||||||
#
|
|
||||||
diff --git a/cron/mailpasswds b/cron/mailpasswds
|
|
||||||
index 9738e23..9c9e8f2 100755
|
|
||||||
--- a/cron/mailpasswds
|
|
||||||
+++ b/cron/mailpasswds
|
|
||||||
@@ -1,4 +1,4 @@
|
|
||||||
-#! @PYTHON@
|
|
||||||
+#! @PYTHON@ -S
|
|
||||||
#
|
|
||||||
# Copyright (C) 1998-2018 by the Free Software Foundation, Inc.
|
|
||||||
#
|
|
||||||
diff --git a/cron/nightly_gzip b/cron/nightly_gzip
|
|
||||||
index 9d4a07f..d94dcba 100755
|
|
||||||
--- a/cron/nightly_gzip
|
|
||||||
+++ b/cron/nightly_gzip
|
|
||||||
@@ -1,4 +1,4 @@
|
|
||||||
-#! @PYTHON@
|
|
||||||
+#! @PYTHON@ -S
|
|
||||||
#
|
|
||||||
# Copyright (C) 1998-2018 by the Free Software Foundation, Inc.
|
|
||||||
#
|
|
||||||
diff --git a/cron/senddigests b/cron/senddigests
|
|
||||||
index 24408df..dc4f369 100755
|
|
||||||
--- a/cron/senddigests
|
|
||||||
+++ b/cron/senddigests
|
|
||||||
@@ -1,4 +1,4 @@
|
|
||||||
-#! @PYTHON@
|
|
||||||
+#! @PYTHON@ -S
|
|
||||||
#
|
|
||||||
# Copyright (C) 1998-2018 by the Free Software Foundation, Inc.
|
|
||||||
#
|
|
||||||
@ -1,387 +0,0 @@
|
|||||||
diff -ruN mailman-2.1.12-a/configure.in mailman-2.1.12-b/configure.in
|
|
||||||
--- mailman-2.1.12-a/configure.in 2009-02-23 22:23:35.000000000 +0100
|
|
||||||
+++ mailman-2.1.12-b/configure.in 2009-07-28 12:19:47.000000000 +0200
|
|
||||||
@@ -249,26 +249,101 @@
|
|
||||||
fi
|
|
||||||
|
|
||||||
# new macro for finding group names
|
|
||||||
-AC_DEFUN([MM_FIND_GROUP_NAME], [
|
|
||||||
+# returns a comma separated list of quoted group names
|
|
||||||
+# the list is returned in the same order as specified with any duplicates removed
|
|
||||||
+# the filter flag must be "yes" or "no", e.g. this is permcheck
|
|
||||||
+# "no" ==> none existing groups are not filtered out
|
|
||||||
+# "yes" ==> only those groups that are in the group database are included
|
|
||||||
+# in the list
|
|
||||||
+AC_DEFUN(MM_FIND_GROUP_LIST, [
|
|
||||||
# $1 == variable name
|
|
||||||
-# $2 == user id to check for
|
|
||||||
+# $2 == white space separated list of groups to check,
|
|
||||||
+# list may contain mix of id's and names
|
|
||||||
+# $3 == filter, if == 'yes' then remove any non-existing groups
|
|
||||||
AC_SUBST($1)
|
|
||||||
changequote(,)
|
|
||||||
if test -z "$$1"
|
|
||||||
then
|
|
||||||
cat > conftest.py <<EOF
|
|
||||||
import grp
|
|
||||||
-gid = ''
|
|
||||||
+group_names = []
|
|
||||||
+seen = {}
|
|
||||||
+filter = "$3"
|
|
||||||
+
|
|
||||||
for group in "$2".split():
|
|
||||||
try:
|
|
||||||
+ gid = int(group)
|
|
||||||
+ try:
|
|
||||||
+ gname = grp.getgrgid(gid)[0]
|
|
||||||
+ except KeyError:
|
|
||||||
+ gname = ''
|
|
||||||
+ except ValueError:
|
|
||||||
try:
|
|
||||||
- gname = grp.getgrgid(int(group))[0]
|
|
||||||
- break
|
|
||||||
- except ValueError:
|
|
||||||
gname = grp.getgrnam(group)[0]
|
|
||||||
+ except KeyError:
|
|
||||||
+ if filter == "yes":
|
|
||||||
+ gname = ''
|
|
||||||
+ else:
|
|
||||||
+ gname = group
|
|
||||||
+ if gname:
|
|
||||||
+ if gname not in seen:
|
|
||||||
+ seen[gname] = 1
|
|
||||||
+ group_names.append(gname)
|
|
||||||
+
|
|
||||||
+if group_names:
|
|
||||||
+ val = '"' + '", "'.join(group_names) + '"'
|
|
||||||
+ #val = "'"+val+"'"
|
|
||||||
+else:
|
|
||||||
+ val = ''
|
|
||||||
+
|
|
||||||
+fp = open("conftest.out", "w")
|
|
||||||
+fp.write("%s\n" % val)
|
|
||||||
+fp.close()
|
|
||||||
+EOF
|
|
||||||
+ $PYTHON conftest.py
|
|
||||||
+ $1=`cat conftest.out`
|
|
||||||
+fi
|
|
||||||
+changequote([, ])
|
|
||||||
+rm -f conftest.out conftest.py])
|
|
||||||
+
|
|
||||||
+
|
|
||||||
+# new macro for finding group names
|
|
||||||
+AC_DEFUN(MM_FIND_GROUP_NAME, [
|
|
||||||
+# Given a list of tokens, either a name or a number (gid)
|
|
||||||
+# return the first one in the list that is found in the
|
|
||||||
+# group database. The return value is always a name, possibly
|
|
||||||
+# translated from a gid. If permcheck is "no" then the group
|
|
||||||
+# database is not checked, instead the first token in the list
|
|
||||||
+# which is a name is returned (e.g. the default value). If permcheck
|
|
||||||
+# is no and only gid's are in the list then the null string is returned.
|
|
||||||
+# $1 == variable name
|
|
||||||
+# $2 == group id to check for
|
|
||||||
+# $3 == permcheck, either "yes" or "no"
|
|
||||||
+AC_SUBST($1)
|
|
||||||
+changequote(,)
|
|
||||||
+if test -z "$$1"
|
|
||||||
+then
|
|
||||||
+ cat > conftest.py <<EOF
|
|
||||||
+import grp
|
|
||||||
+gname=''
|
|
||||||
+if "$3" == "yes":
|
|
||||||
+ for group in "$2".split():
|
|
||||||
+ try:
|
|
||||||
+ try:
|
|
||||||
+ gname = grp.getgrgid(int(group))[0]
|
|
||||||
+ break
|
|
||||||
+ except ValueError:
|
|
||||||
+ gname = grp.getgrnam(group)[0]
|
|
||||||
+ break
|
|
||||||
+ except KeyError:
|
|
||||||
+ gname = ''
|
|
||||||
+else:
|
|
||||||
+ for group in "$2".split():
|
|
||||||
+ try:
|
|
||||||
+ int(group)
|
|
||||||
+ except ValueError:
|
|
||||||
+ gname = group
|
|
||||||
break
|
|
||||||
- except KeyError:
|
|
||||||
- gname = ''
|
|
||||||
fp = open("conftest.out", "w")
|
|
||||||
fp.write("%s\n" % gname)
|
|
||||||
fp.close()
|
|
||||||
@@ -282,25 +357,41 @@
|
|
||||||
|
|
||||||
# new macro for finding UIDs
|
|
||||||
AC_DEFUN([MM_FIND_USER_NAME], [
|
|
||||||
+# Given a list of tokens, either a name or a number (uid)
|
|
||||||
+# return the first one in the list that is found in the
|
|
||||||
+# password database. The return value is always a name, possibly
|
|
||||||
+# translated from a uid. If permcheck is "no" then the password
|
|
||||||
+# database is not checked, instead the first token in the list
|
|
||||||
+# which is a name is returned (e.g. the default value). If permcheck
|
|
||||||
+# is no and only uid's are in the list then the null string is returned.
|
|
||||||
# $1 == variable name
|
|
||||||
# $2 == user id to check for
|
|
||||||
+# $3 == permcheck, either "yes" or "no"
|
|
||||||
AC_SUBST($1)
|
|
||||||
changequote(,)
|
|
||||||
if test -z "$$1"
|
|
||||||
then
|
|
||||||
cat > conftest.py <<EOF
|
|
||||||
import pwd
|
|
||||||
-uid = ''
|
|
||||||
-for user in "$2".split():
|
|
||||||
- try:
|
|
||||||
+uname=''
|
|
||||||
+if "$3" == "yes":
|
|
||||||
+ for user in "$2".split():
|
|
||||||
try:
|
|
||||||
- uname = pwd.getpwuid(int(user))[0]
|
|
||||||
- break
|
|
||||||
+ try:
|
|
||||||
+ uname = pwd.getpwuid(int(user))[0]
|
|
||||||
+ break
|
|
||||||
+ except ValueError:
|
|
||||||
+ uname = pwd.getpwnam(user)[0]
|
|
||||||
+ break
|
|
||||||
+ except KeyError:
|
|
||||||
+ uname = ''
|
|
||||||
+else:
|
|
||||||
+ for user in "$2".split():
|
|
||||||
+ try:
|
|
||||||
+ int(user)
|
|
||||||
except ValueError:
|
|
||||||
- uname = pwd.getpwnam(user)[0]
|
|
||||||
+ uname = user
|
|
||||||
break
|
|
||||||
- except KeyError:
|
|
||||||
- uname = ''
|
|
||||||
fp = open("conftest.out", "w")
|
|
||||||
fp.write("%s\n" % uname)
|
|
||||||
fp.close()
|
|
||||||
@@ -326,7 +417,7 @@
|
|
||||||
# User `mailman' must exist
|
|
||||||
AC_SUBST(MAILMAN_USER)
|
|
||||||
AC_MSG_CHECKING(for user name \"$USERNAME\")
|
|
||||||
-MM_FIND_USER_NAME(MAILMAN_USER, $USERNAME)
|
|
||||||
+MM_FIND_USER_NAME(MAILMAN_USER, $USERNAME, $with_permcheck)
|
|
||||||
if test -z "$MAILMAN_USER"
|
|
||||||
then
|
|
||||||
if test "$with_permcheck" = "yes"
|
|
||||||
@@ -357,7 +448,7 @@
|
|
||||||
# Target group must exist
|
|
||||||
AC_SUBST(MAILMAN_GROUP)
|
|
||||||
AC_MSG_CHECKING(for group name \"$GROUPNAME\")
|
|
||||||
-MM_FIND_GROUP_NAME(MAILMAN_GROUP, $GROUPNAME)
|
|
||||||
+MM_FIND_GROUP_NAME(MAILMAN_GROUP, $GROUPNAME, $with_permcheck)
|
|
||||||
if test -z "$MAILMAN_GROUP"
|
|
||||||
then
|
|
||||||
if test "$with_permcheck" = "yes"
|
|
||||||
@@ -380,11 +471,11 @@
|
|
||||||
prefix = "$prefixcheck"
|
|
||||||
groupname = "$GROUPNAME"
|
|
||||||
mailmangroup = "$MAILMAN_GROUP"
|
|
||||||
-try:
|
|
||||||
- mailmangid = grp.getgrnam(mailmangroup)[2]
|
|
||||||
-except KeyError:
|
|
||||||
- mailmangid = -1
|
|
||||||
problems = []
|
|
||||||
+try: mailmangid = grp.getgrnam(mailmangroup)[2]
|
|
||||||
+except KeyError:
|
|
||||||
+ problems.append("group doesn't exist: " + mailmangroup)
|
|
||||||
+ mailmangid = 41
|
|
||||||
try: statdata = os.stat(prefix)
|
|
||||||
except OSError:
|
|
||||||
problems.append("Directory doesn't exist: " + prefix)
|
|
||||||
@@ -434,7 +525,7 @@
|
|
||||||
then
|
|
||||||
with_mail_gid="mailman other mail daemon"
|
|
||||||
fi
|
|
||||||
-MM_FIND_GROUP_NAME(MAIL_GROUP, $with_mail_gid)
|
|
||||||
+MM_FIND_GROUP_LIST(MAIL_GROUP, $with_mail_gid, $with_permcheck)
|
|
||||||
if test -z "$MAIL_GROUP"
|
|
||||||
then
|
|
||||||
if test "$with_permcheck" = "yes"
|
|
||||||
@@ -461,7 +552,7 @@
|
|
||||||
with_cgi_gid="www www-data nobody"
|
|
||||||
fi
|
|
||||||
|
|
||||||
-MM_FIND_GROUP_NAME(CGI_GROUP, $with_cgi_gid)
|
|
||||||
+MM_FIND_GROUP_LIST(CGI_GROUP, $with_cgi_gid, $with_permcheck)
|
|
||||||
if test -z "$CGI_GROUP"
|
|
||||||
then
|
|
||||||
if test "$with_permcheck" = "yes"
|
|
||||||
diff -ruN mailman-2.1.12-a/src/cgi-wrapper.c mailman-2.1.12-b/src/cgi-wrapper.c
|
|
||||||
--- mailman-2.1.12-a/src/cgi-wrapper.c 2009-02-23 22:23:35.000000000 +0100
|
|
||||||
+++ mailman-2.1.12-b/src/cgi-wrapper.c 2009-07-28 12:19:47.000000000 +0200
|
|
||||||
@@ -28,11 +28,11 @@
|
|
||||||
/* Group name that CGI scripts run as. See your web server's documentation
|
|
||||||
* for details.
|
|
||||||
*/
|
|
||||||
-#define LEGAL_PARENT_GROUP CGI_GROUP
|
|
||||||
+#define LEGAL_PARENT_GROUPS CGI_GROUP
|
|
||||||
|
|
||||||
const char* logident = LOG_IDENT;
|
|
||||||
char* script = SCRIPTNAME;
|
|
||||||
-const char* parentgroup = LEGAL_PARENT_GROUP;
|
|
||||||
+const char* parentgroups[] = {LEGAL_PARENT_GROUPS};
|
|
||||||
|
|
||||||
|
|
||||||
int
|
|
||||||
@@ -42,7 +42,7 @@
|
|
||||||
char* fake_argv[3];
|
|
||||||
|
|
||||||
running_as_cgi = 1;
|
|
||||||
- check_caller(logident, parentgroup);
|
|
||||||
+ check_caller(logident, parentgroups, sizeof(parentgroups) / sizeof(parentgroups[0]));
|
|
||||||
|
|
||||||
/* For these CGI programs, we can ignore argc and argv since they
|
|
||||||
* don't contain anything useful. `script' will always be the driver
|
|
||||||
diff -ruN mailman-2.1.12-a/src/common.c mailman-2.1.12-b/src/common.c
|
|
||||||
--- mailman-2.1.12-a/src/common.c 2009-02-23 22:23:35.000000000 +0100
|
|
||||||
+++ mailman-2.1.12-b/src/common.c 2009-07-28 12:19:47.000000000 +0200
|
|
||||||
@@ -117,13 +117,14 @@
|
|
||||||
/* Is the parent process allowed to call us?
|
|
||||||
*/
|
|
||||||
void
|
|
||||||
-check_caller(const char* ident, const char* parentgroup)
|
|
||||||
+check_caller(const char* ident, const char** parentgroups, size_t numgroups)
|
|
||||||
{
|
|
||||||
GID_T mygid = getgid();
|
|
||||||
struct group *mygroup = getgrgid(mygid);
|
|
||||||
char* option;
|
|
||||||
char* server;
|
|
||||||
char* wrapper;
|
|
||||||
+ int i;
|
|
||||||
|
|
||||||
if (running_as_cgi) {
|
|
||||||
option = "--with-cgi-gid";
|
|
||||||
@@ -136,28 +137,46 @@
|
|
||||||
wrapper = "mail";
|
|
||||||
}
|
|
||||||
|
|
||||||
- if (!mygroup)
|
|
||||||
- fatal(ident, GROUP_NAME_NOT_FOUND,
|
|
||||||
- "Failure to find group name for GID %d. Mailman\n"
|
|
||||||
- "expected the %s wrapper to be executed as group\n"
|
|
||||||
- "\"%s\", but the system's %s server executed the\n"
|
|
||||||
- "wrapper as GID %d for which the name could not be\n"
|
|
||||||
- "found. Try adding GID %d to your system as \"%s\",\n"
|
|
||||||
- "or tweak your %s server to run the wrapper as group\n"
|
|
||||||
- "\"%s\".",
|
|
||||||
- mygid, wrapper, parentgroup, server, mygid, mygid,
|
|
||||||
- parentgroup, server, parentgroup);
|
|
||||||
+ if (!mygroup)
|
|
||||||
+ fatal(ident, GROUP_ID_NOT_FOUND,
|
|
||||||
+ "Failure to lookup via getgrgid() the group info for group id %d that this Mailman %s wrapper is executing under.\n"
|
|
||||||
+ "This is probably due to an incorrectly configured system and is not a Mailman problem",
|
|
||||||
+ mygid, wrapper);
|
|
||||||
+
|
|
||||||
+ for (i = 0; i < numgroups; i++) {
|
|
||||||
+ if (strcmp(parentgroups[i], mygroup->gr_name) == 0) break;
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
+ if (i >= numgroups) {
|
|
||||||
+ char *groupset = NULL;
|
|
||||||
+ size_t size = 0;
|
|
||||||
+
|
|
||||||
+ for (i = 0; i < numgroups; i++) {
|
|
||||||
+ size += strlen(parentgroups[i]) + 2;
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
+ groupset = malloc(size);
|
|
||||||
+
|
|
||||||
+ if (groupset) {
|
|
||||||
+ groupset[0] = 0;
|
|
||||||
+ for (i = 0; i < numgroups; i++) {
|
|
||||||
+ strcat(groupset, parentgroups[i]);
|
|
||||||
+ if (i < numgroups-1) strcat(groupset, ", ");
|
|
||||||
+ }
|
|
||||||
+ }
|
|
||||||
|
|
||||||
- if (strcmp(parentgroup, mygroup->gr_name))
|
|
||||||
fatal(ident, GROUP_MISMATCH,
|
|
||||||
- "Group mismatch error. Mailman expected the %s\n"
|
|
||||||
- "wrapper script to be executed as group \"%s\", but\n"
|
|
||||||
- "the system's %s server executed the %s script as\n"
|
|
||||||
- "group \"%s\". Try tweaking the %s server to run the\n"
|
|
||||||
- "script as group \"%s\", or re-run configure, \n"
|
|
||||||
- "providing the command line option `%s=%s'.",
|
|
||||||
- wrapper, parentgroup, server, wrapper, mygroup->gr_name,
|
|
||||||
- server, parentgroup, option, mygroup->gr_name);
|
|
||||||
+ "Group mismatch error. Mailman expected the %s wrapper script to be\n"
|
|
||||||
+ "executed as one of the following groups:\n"
|
|
||||||
+ "[%s],\n"
|
|
||||||
+ "but the system's %s server executed the %s script as group: \"%s\".\n"
|
|
||||||
+ "Try tweaking the %s server to run the script as one of these groups:\n"
|
|
||||||
+ "[%s],\n"
|
|
||||||
+ "or re-run configure providing the command line option:\n"
|
|
||||||
+ "'%s=%s'.",
|
|
||||||
+ wrapper, groupset, server, wrapper, mygroup->gr_name,
|
|
||||||
+ server, groupset, option, mygroup->gr_name);
|
|
||||||
+ }
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
diff -ruN mailman-2.1.12-a/src/common.h mailman-2.1.12-b/src/common.h
|
|
||||||
--- mailman-2.1.12-a/src/common.h 2009-02-23 22:23:35.000000000 +0100
|
|
||||||
+++ mailman-2.1.12-b/src/common.h 2009-07-28 12:19:47.000000000 +0200
|
|
||||||
@@ -33,7 +33,7 @@
|
|
||||||
#define GID_T GETGROUPS_T
|
|
||||||
|
|
||||||
extern void fatal(const char*, int, char*, ...);
|
|
||||||
-extern void check_caller(const char*, const char*);
|
|
||||||
+extern void check_caller(const char* ident, const char**, size_t);
|
|
||||||
extern int run_script(const char*, int, char**, char**);
|
|
||||||
|
|
||||||
/* Global variable used as a flag. */
|
|
||||||
@@ -51,7 +51,7 @@
|
|
||||||
#define MAIL_USAGE_ERROR 5
|
|
||||||
#define MAIL_ILLEGAL_COMMAND 6
|
|
||||||
#define ADDALIAS_USAGE_ERROR 7
|
|
||||||
-#define GROUP_NAME_NOT_FOUND 8
|
|
||||||
+#define GROUP_ID_NOT_FOUND 8
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
diff -ruN mailman-2.1.12-a/src/mail-wrapper.c mailman-2.1.12-b/src/mail-wrapper.c
|
|
||||||
--- mailman-2.1.12-a/src/mail-wrapper.c 2009-02-23 22:23:35.000000000 +0100
|
|
||||||
+++ mailman-2.1.12-b/src/mail-wrapper.c 2009-07-28 12:19:47.000000000 +0200
|
|
||||||
@@ -23,9 +23,9 @@
|
|
||||||
/* Group name that your mail programs run as. See your mail server's
|
|
||||||
* documentation for details.
|
|
||||||
*/
|
|
||||||
-#define LEGAL_PARENT_GROUP MAIL_GROUP
|
|
||||||
+#define LEGAL_PARENT_GROUPS MAIL_GROUP
|
|
||||||
|
|
||||||
-const char* parentgroup = LEGAL_PARENT_GROUP;
|
|
||||||
+const char* parentgroups[] = {LEGAL_PARENT_GROUPS};
|
|
||||||
const char* logident = "Mailman mail-wrapper";
|
|
||||||
|
|
||||||
|
|
||||||
@@ -74,7 +74,7 @@
|
|
||||||
fatal(logident, MAIL_ILLEGAL_COMMAND,
|
|
||||||
"Illegal command: %s", argv[1]);
|
|
||||||
|
|
||||||
- check_caller(logident, parentgroup);
|
|
||||||
+ check_caller(logident, parentgroups, sizeof(parentgroups) / sizeof(parentgroups[0]));
|
|
||||||
|
|
||||||
/* If we got here, everything must be OK */
|
|
||||||
status = run_script(argv[1], argc, argv, env);
|
|
||||||
diff -ruN mailman-2.1.12-a/src/Makefile.in mailman-2.1.12-b/src/Makefile.in
|
|
||||||
--- mailman-2.1.12-a/src/Makefile.in 2009-02-23 22:23:35.000000000 +0100
|
|
||||||
+++ mailman-2.1.12-b/src/Makefile.in 2009-07-28 12:19:47.000000000 +0200
|
|
||||||
@@ -49,9 +49,9 @@
|
|
||||||
|
|
||||||
SHELL= /bin/sh
|
|
||||||
|
|
||||||
-MAIL_FLAGS= -DMAIL_GROUP="\"$(MAIL_GROUP)\""
|
|
||||||
+MAIL_FLAGS= -DMAIL_GROUP='$(MAIL_GROUP)'
|
|
||||||
|
|
||||||
-CGI_FLAGS= -DCGI_GROUP="\"$(CGI_GROUP)\""
|
|
||||||
+CGI_FLAGS= -DCGI_GROUP='$(CGI_GROUP)'
|
|
||||||
|
|
||||||
HELPFUL= -DHELPFUL
|
|
||||||
|
|
||||||
@ -1,243 +0,0 @@
|
|||||||
diff --git a/Mailman/Defaults.py.in b/Mailman/Defaults.py.in
|
|
||||||
index fb3f4f3..7dde965 100644
|
|
||||||
--- a/Mailman/Defaults.py.in
|
|
||||||
+++ b/Mailman/Defaults.py.in
|
|
||||||
@@ -1431,20 +1431,22 @@ AuthListPoster = 6 # List poster (Approved: <pw> header in posts only)
|
|
||||||
|
|
||||||
# Useful directories
|
|
||||||
LIST_DATA_DIR = os.path.join(VAR_PREFIX, 'lists')
|
|
||||||
-LOG_DIR = os.path.join(VAR_PREFIX, 'logs')
|
|
||||||
-LOCK_DIR = os.path.join(VAR_PREFIX, 'locks')
|
|
||||||
+LOG_DIR = '@LOG_DIR@'
|
|
||||||
+LOCK_DIR = '@LOCK_DIR@'
|
|
||||||
+CONFIG_DIR = '@CONFIG_DIR@'
|
|
||||||
DATA_DIR = os.path.join(VAR_PREFIX, 'data')
|
|
||||||
+PID_DIR = '@PID_DIR@'
|
|
||||||
SPAM_DIR = os.path.join(VAR_PREFIX, 'spam')
|
|
||||||
WRAPPER_DIR = os.path.join(EXEC_PREFIX, 'mail')
|
|
||||||
BIN_DIR = os.path.join(PREFIX, 'bin')
|
|
||||||
SCRIPTS_DIR = os.path.join(PREFIX, 'scripts')
|
|
||||||
-TEMPLATE_DIR = os.path.join(PREFIX, 'templates')
|
|
||||||
+TEMPLATE_DIR = '@TEMPLATE_DIR@'
|
|
||||||
MESSAGES_DIR = os.path.join(PREFIX, 'messages')
|
|
||||||
PUBLIC_ARCHIVE_FILE_DIR = os.path.join(VAR_PREFIX, 'archives', 'public')
|
|
||||||
PRIVATE_ARCHIVE_FILE_DIR = os.path.join(VAR_PREFIX, 'archives', 'private')
|
|
||||||
|
|
||||||
# Directories used by the qrunner subsystem
|
|
||||||
-QUEUE_DIR = os.path.join(VAR_PREFIX, 'qfiles')
|
|
||||||
+QUEUE_DIR = '@QUEUE_DIR@'
|
|
||||||
INQUEUE_DIR = os.path.join(QUEUE_DIR, 'in')
|
|
||||||
OUTQUEUE_DIR = os.path.join(QUEUE_DIR, 'out')
|
|
||||||
CMDQUEUE_DIR = os.path.join(QUEUE_DIR, 'commands')
|
|
||||||
@@ -1458,9 +1460,9 @@ RETRYQUEUE_DIR = os.path.join(QUEUE_DIR, 'retry')
|
|
||||||
MAILDIR_DIR = os.path.join(QUEUE_DIR, 'maildir')
|
|
||||||
|
|
||||||
# Other useful files
|
|
||||||
-PIDFILE = os.path.join(DATA_DIR, 'master-qrunner.pid')
|
|
||||||
-SITE_PW_FILE = os.path.join(DATA_DIR, 'adm.pw')
|
|
||||||
-LISTCREATOR_PW_FILE = os.path.join(DATA_DIR, 'creator.pw')
|
|
||||||
+PIDFILE = os.path.join(PID_DIR, 'master-qrunner.pid')
|
|
||||||
+SITE_PW_FILE = os.path.join(CONFIG_DIR, 'adm.pw')
|
|
||||||
+LISTCREATOR_PW_FILE = os.path.join(CONFIG_DIR, 'creator.pw')
|
|
||||||
|
|
||||||
# Import a bunch of version numbers
|
|
||||||
from Version import *
|
|
||||||
diff --git a/Mailman/MTA/Postfix.py b/Mailman/MTA/Postfix.py
|
|
||||||
index 801ddc0..8506b9b 100644
|
|
||||||
--- a/Mailman/MTA/Postfix.py
|
|
||||||
+++ b/Mailman/MTA/Postfix.py
|
|
||||||
@@ -32,8 +32,8 @@ from Mailman.MTA.Utils import makealiases
|
|
||||||
from Mailman.Logging.Syslog import syslog
|
|
||||||
|
|
||||||
LOCKFILE = os.path.join(mm_cfg.LOCK_DIR, 'creator')
|
|
||||||
-ALIASFILE = os.path.join(mm_cfg.DATA_DIR, 'aliases')
|
|
||||||
-VIRTFILE = os.path.join(mm_cfg.DATA_DIR, 'virtual-mailman')
|
|
||||||
+ALIASFILE = os.path.join(mm_cfg.CONFIG_DIR, 'aliases')
|
|
||||||
+VIRTFILE = os.path.join(mm_cfg.CONFIG_DIR, 'virtual-mailman')
|
|
||||||
# Desired mode for aliases(.db) and virtual-mailman(.db) for both creation
|
|
||||||
# and check_perms.
|
|
||||||
targetmode = S_IFREG | S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH
|
|
||||||
diff --git a/Makefile.in b/Makefile.in
|
|
||||||
index eb40844..289aeee 100644
|
|
||||||
--- a/Makefile.in
|
|
||||||
+++ b/Makefile.in
|
|
||||||
@@ -28,6 +28,12 @@ bindir= @bindir@
|
|
||||||
prefix= @prefix@
|
|
||||||
exec_prefix= @exec_prefix@
|
|
||||||
var_prefix= @VAR_PREFIX@
|
|
||||||
+configdir= @CONFIG_DIR@
|
|
||||||
+lockdir= @LOCK_DIR@
|
|
||||||
+logdir= @LOG_DIR@
|
|
||||||
+piddir= @PID_DIR@
|
|
||||||
+queuedir= @QUEUE_DIR@
|
|
||||||
+templatedir= @TEMPLATE_DIR@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
@@ -41,8 +47,11 @@ DEFS= @DEFS@
|
|
||||||
OPT= @OPT@
|
|
||||||
CFLAGS= @CFLAGS@ $(OPT) $(DEFS)
|
|
||||||
|
|
||||||
+FHS_DIRS= \
|
|
||||||
+ ${configdir} ${lockdir} ${logdir} ${piddir} ${queuedir} ${templatedir}
|
|
||||||
+
|
|
||||||
VAR_DIRS= \
|
|
||||||
- logs archives lists locks data spam qfiles \
|
|
||||||
+ archives lists data spam \
|
|
||||||
archives/private archives/public
|
|
||||||
|
|
||||||
ARCH_INDEP_DIRS= \
|
|
||||||
@@ -105,6 +114,15 @@ doinstall: $(SUBDIRS)
|
|
||||||
else true; \
|
|
||||||
fi; \
|
|
||||||
done
|
|
||||||
+ @for d in $(FHS_DIRS); \
|
|
||||||
+ do \
|
|
||||||
+ dir=$(DESTDIR)/$$d; \
|
|
||||||
+ if test ! -d $$dir; then \
|
|
||||||
+ echo "Creating directory $$dir"; \
|
|
||||||
+ $(INSTALL) -d -m $(DIRMODE) $$dir; \
|
|
||||||
+ else true; \
|
|
||||||
+ fi; \
|
|
||||||
+ done
|
|
||||||
chmod o-r $(DESTDIR)$(var_prefix)/archives/private
|
|
||||||
@for d in $(ARCH_INDEP_DIRS); \
|
|
||||||
do \
|
|
||||||
diff --git a/bin/check_perms b/bin/check_perms
|
|
||||||
index 137ebfb..1f45f84 100755
|
|
||||||
--- a/bin/check_perms
|
|
||||||
+++ b/bin/check_perms
|
|
||||||
@@ -183,7 +183,8 @@ def checkall():
|
|
||||||
print C_('checking mode for %(prefix)s')
|
|
||||||
dirs = {}
|
|
||||||
for d in (mm_cfg.PREFIX, mm_cfg.EXEC_PREFIX, mm_cfg.VAR_PREFIX,
|
|
||||||
- mm_cfg.LOG_DIR):
|
|
||||||
+ mm_cfg.CONFIG_DIR, mm_cfg.DATA_DIR, mm_cfg.LOCK_DIR,
|
|
||||||
+ mm_cfg.LOG_DIR, mm_cfg.QUEUE_DIR, mm_cfg.PID_DIR):
|
|
||||||
dirs[d] = True
|
|
||||||
for d in dirs.keys():
|
|
||||||
try:
|
|
||||||
diff --git a/configure.in b/configure.in
|
|
||||||
index f2eb1c0..c01129c 100644
|
|
||||||
--- a/configure.in
|
|
||||||
+++ b/configure.in
|
|
||||||
@@ -305,6 +305,72 @@ else
|
|
||||||
prefixcheck=$VAR_PREFIX
|
|
||||||
fi
|
|
||||||
|
|
||||||
+# Get the configuration file directory
|
|
||||||
+AC_SUBST(CONFIG_DIR)
|
|
||||||
+AC_MSG_CHECKING(for --with-config-dir)
|
|
||||||
+AC_ARG_WITH(config-dir, dnl
|
|
||||||
+[ --with-config-dir specify directory for configuration data other than [VAR_]PREFIX/data])
|
|
||||||
+case "$with_config_dir" in
|
|
||||||
+ yes|no|"") CONFIG_DIR="$VAR_PREFIX/data";;
|
|
||||||
+ *) CONFIG_DIR=$with_config_dir;;
|
|
||||||
+esac
|
|
||||||
+AC_MSG_RESULT($CONFIG_DIR)
|
|
||||||
+
|
|
||||||
+# Get the lock directory
|
|
||||||
+AC_SUBST(LOCK_DIR)
|
|
||||||
+AC_MSG_CHECKING(for --with-lock-dir)
|
|
||||||
+AC_ARG_WITH(lock-dir, dnl
|
|
||||||
+[ --with-lock-dir specify directory for lock files other than [VAR_]PREFIX/locks])
|
|
||||||
+case "$with_lock_dir" in
|
|
||||||
+ yes|no|"") LOCK_DIR="$VAR_PREFIX/locks";;
|
|
||||||
+ *) LOCK_DIR=$with_lock_dir;;
|
|
||||||
+esac
|
|
||||||
+AC_MSG_RESULT($LOCK_DIR)
|
|
||||||
+
|
|
||||||
+# Get the log directory
|
|
||||||
+AC_SUBST(LOG_DIR)
|
|
||||||
+AC_MSG_CHECKING(for --with-log-dir)
|
|
||||||
+AC_ARG_WITH(log-dir, dnl
|
|
||||||
+[ --with-log-dir specify directory for log files other than [VAR_]PREFIX/logs])
|
|
||||||
+case "$with_log_dir" in
|
|
||||||
+ yes|no|"") LOG_DIR="$VAR_PREFIX/logs";;
|
|
||||||
+ *) LOG_DIR=$with_log_dir;;
|
|
||||||
+esac
|
|
||||||
+AC_MSG_RESULT($LOG_DIR)
|
|
||||||
+
|
|
||||||
+# Get the pid directory
|
|
||||||
+AC_SUBST(PID_DIR)
|
|
||||||
+AC_MSG_CHECKING(for --with-pid-dir)
|
|
||||||
+AC_ARG_WITH(pid-dir, dnl
|
|
||||||
+[ --with-pid-dir specify directory for the pid file other than [VAR_]PREFIX/data])
|
|
||||||
+case "$with_pid_dir" in
|
|
||||||
+ yes|no|"") PID_DIR="$VAR_PREFIX/data";;
|
|
||||||
+ *) PID_DIR=$with_pid_dir;;
|
|
||||||
+esac
|
|
||||||
+AC_MSG_RESULT($PID_DIR)
|
|
||||||
+
|
|
||||||
+# Get the queue directory
|
|
||||||
+AC_SUBST(QUEUE_DIR)
|
|
||||||
+AC_MSG_CHECKING(for --with-queue-dir)
|
|
||||||
+AC_ARG_WITH(queue-dir, dnl
|
|
||||||
+[ --with-queue-dir specify directory for queue files other than [VAR_]PREFIX/qfiles])
|
|
||||||
+case "$with_queue_dir" in
|
|
||||||
+ yes|no|"") QUEUE_DIR="$VAR_PREFIX/qfiles";;
|
|
||||||
+ *) QUEUE_DIR=$with_queue_dir;;
|
|
||||||
+esac
|
|
||||||
+AC_MSG_RESULT($QUEUE_DIR)
|
|
||||||
+
|
|
||||||
+# Get the template directory
|
|
||||||
+AC_SUBST(TEMPLATE_DIR)
|
|
||||||
+AC_MSG_CHECKING(for --with-template-dir)
|
|
||||||
+AC_ARG_WITH(template-dir, dnl
|
|
||||||
+[ --with-template-dir specify directory for template files other than [VAR_]PREFIX/templates])
|
|
||||||
+case "$with_template_dir" in
|
|
||||||
+ yes|no|"") TEMPLATE_DIR="$VAR_PREFIX/templates";;
|
|
||||||
+ *) TEMPLATE_DIR=$with_template_dir;;
|
|
||||||
+esac
|
|
||||||
+AC_MSG_RESULT($TEMPLATE_DIR)
|
|
||||||
+
|
|
||||||
# new macro for finding group names
|
|
||||||
# returns a comma separated list of quoted group names
|
|
||||||
# the list is returned in the same order as specified with any duplicates removed
|
|
||||||
diff --git a/misc/Makefile.in b/misc/Makefile.in
|
|
||||||
index af99c04..df50a06 100644
|
|
||||||
--- a/misc/Makefile.in
|
|
||||||
+++ b/misc/Makefile.in
|
|
||||||
@@ -27,6 +27,12 @@ bindir= @bindir@
|
|
||||||
prefix= @prefix@
|
|
||||||
exec_prefix= @exec_prefix@
|
|
||||||
var_prefix= @VAR_PREFIX@
|
|
||||||
+configdir= @CONFIG_DIR@
|
|
||||||
+lockdir= @LOCK_DIR@
|
|
||||||
+logdir= @LOG_DIR@
|
|
||||||
+piddir= @PID_DIR@
|
|
||||||
+queuedir= @QUEUE_DIR@
|
|
||||||
+MAILMAN_GROUP= @MAILMAN_GROUP@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
@@ -87,7 +93,7 @@ install-other:
|
|
||||||
$(INSTALL) -m $(FILEMODE) paths.py $$dir; \
|
|
||||||
done
|
|
||||||
$(INSTALL) -m $(EXEMODE) mailman $(DESTDIR)$(SCRIPTSDIR)
|
|
||||||
- $(INSTALL) -m $(FILEMODE) sitelist.cfg $(DESTDIR)$(DATADIR)
|
|
||||||
+ $(INSTALL) -m $(FILEMODE) sitelist.cfg $(DESTDIR)$(configdir)
|
|
||||||
|
|
||||||
install-packages:
|
|
||||||
if [ -z "$(EMAILPKG)" -a -d $(DESTDIR)$(PYTHONLIBDIR)/email ] ; \
|
|
||||||
diff --git a/templates/Makefile.in b/templates/Makefile.in
|
|
||||||
index b23d7c1..16930a2 100644
|
|
||||||
--- a/templates/Makefile.in
|
|
||||||
+++ b/templates/Makefile.in
|
|
||||||
@@ -25,6 +25,7 @@ srcdir= @srcdir@
|
|
||||||
bindir= @bindir@
|
|
||||||
prefix= @prefix@
|
|
||||||
exec_prefix= @exec_prefix@
|
|
||||||
+template_dir= @TEMPLATE_DIR@
|
|
||||||
DESTDIR=
|
|
||||||
|
|
||||||
CC= @CC@
|
|
||||||
@@ -37,7 +38,7 @@ DEFS= @DEFS@
|
|
||||||
|
|
||||||
OPT= @OPT@
|
|
||||||
CFLAGS= $(OPT) $(DEFS)
|
|
||||||
-TEMPLATEDIR= $(prefix)/templates
|
|
||||||
+TEMPLATEDIR= $(template_dir)
|
|
||||||
|
|
||||||
SHELL= /bin/sh
|
|
||||||
|
|
||||||
@ -1,21 +0,0 @@
|
|||||||
diff -up mailman-2.1.13/templates/en/article.html.archive-reply mailman-2.1.13/templates/en/article.html
|
|
||||||
--- mailman-2.1.13/templates/en/article.html.archive-reply 2009-12-22 19:00:43.000000000 +0100
|
|
||||||
+++ mailman-2.1.13/templates/en/article.html 2010-03-25 13:50:02.000000000 +0100
|
|
||||||
@@ -4,7 +4,7 @@
|
|
||||||
<TITLE> %(title)s
|
|
||||||
</TITLE>
|
|
||||||
<LINK REL="Index" HREF="index.html" >
|
|
||||||
- <LINK REL="made" HREF="mailto:%(email_url)s?Subject=%(subject_url)s&In-Reply-To=%(in_reply_to_url)s">
|
|
||||||
+ <LINK REL="made" HREF="mailto:%(email_url)s?Subject=Re:%%20%(subject_url)s&In-Reply-To=%(in_reply_to_url)s">
|
|
||||||
<META NAME="robots" CONTENT="index,nofollow">
|
|
||||||
<style type="text/css">
|
|
||||||
pre {
|
|
||||||
@@ -18,7 +18,7 @@
|
|
||||||
<BODY BGCOLOR="#ffffff">
|
|
||||||
<H1>%(subject_html)s</H1>
|
|
||||||
<B>%(author_html)s</B>
|
|
||||||
- <A HREF="mailto:%(email_url)s?Subject=%(subject_url)s&In-Reply-To=%(in_reply_to_url)s"
|
|
||||||
+ <A HREF="mailto:%(email_url)s?Subject=Re:%%20%(subject_url)s&In-Reply-To=%(in_reply_to_url)s"
|
|
||||||
TITLE="%(subject_html)s">%(email_html)s
|
|
||||||
</A><BR>
|
|
||||||
<I>%(datestr_html)s</I>
|
|
||||||
@ -1,25 +0,0 @@
|
|||||||
diff --git a/tests/onebounce.py b/tests/onebounce.py
|
|
||||||
index 00a695f..ae7fe1a 100644
|
|
||||||
--- a/tests/onebounce.py
|
|
||||||
+++ b/tests/onebounce.py
|
|
||||||
@@ -1,4 +1,4 @@
|
|
||||||
-#! /usr/bin/env python
|
|
||||||
+#! /usr/bin/python2
|
|
||||||
|
|
||||||
# Copyright (C) 2002-2018 by the Free Software Foundation, Inc.
|
|
||||||
#
|
|
||||||
diff --git a/configure.in b/configure.in
|
|
||||||
index eee7f3a..2250ade 100644
|
|
||||||
--- a/configure.in
|
|
||||||
+++ b/configure.in
|
|
||||||
@@ -892,6 +892,10 @@ cron/gate_news \
|
|
||||||
cron/mailpasswds \
|
|
||||||
cron/nightly_gzip \
|
|
||||||
cron/senddigests \
|
|
||||||
+contrib/check_perms_grsecurity.py \
|
|
||||||
+contrib/qmail-to-mailman.py \
|
|
||||||
+contrib/rotatelogs.py \
|
|
||||||
+contrib/sitemapgen
|
|
||||||
])
|
|
||||||
|
|
||||||
dnl Please make sure to leave a space at the end of the last entry.
|
|
||||||
@ -1,22 +0,0 @@
|
|||||||
diff --git a/bin/check_perms b/bin/check_perms
|
|
||||||
index 5ef3306..d50518a 100755
|
|
||||||
--- a/bin/check_perms
|
|
||||||
+++ b/bin/check_perms
|
|
||||||
@@ -70,7 +70,7 @@ class State:
|
|
||||||
|
|
||||||
STATE = State()
|
|
||||||
|
|
||||||
-DIRPERMS = S_ISGID | S_IRWXU | S_IRWXG | S_IROTH | S_IXOTH
|
|
||||||
+DIRPERMS = S_IRWXU | S_IRGRP | S_IROTH | S_IXOTH
|
|
||||||
QFILEPERMS = S_ISGID | S_IRWXU | S_IRWXG
|
|
||||||
PYFILEPERMS = S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH
|
|
||||||
ARTICLEFILEPERMS = S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP
|
|
||||||
@@ -195,7 +195,7 @@ def checkall():
|
|
||||||
continue
|
|
||||||
if (mode & DIRPERMS) <> DIRPERMS:
|
|
||||||
STATE.ERRORS += 1
|
|
||||||
- print C_('directory must be at least 02775: %(d)s'),
|
|
||||||
+ print C_('directory must be at least 0755: %(d)s'),
|
|
||||||
if STATE.FIX:
|
|
||||||
print C_('(fixing)')
|
|
||||||
os.chmod(d, mode | DIRPERMS)
|
|
||||||
Binary file not shown.
@ -1,48 +0,0 @@
|
|||||||
diff -ruN mailman-2.1.12-a/Mailman/Archiver/pipermail.py mailman-2.1.12-b/Mailman/Archiver/pipermail.py
|
|
||||||
--- mailman-2.1.12-a/Mailman/Archiver/pipermail.py 2009-02-23 22:23:35.000000000 +0100
|
|
||||||
+++ mailman-2.1.12-b/Mailman/Archiver/pipermail.py 2009-07-28 12:19:53.000000000 +0200
|
|
||||||
@@ -45,24 +45,27 @@
|
|
||||||
|
|
||||||
def fixAuthor(author):
|
|
||||||
"Canonicalize a name into Last, First format"
|
|
||||||
- # If there's a comma, guess that it's already in "Last, First" format
|
|
||||||
- if ',' in author:
|
|
||||||
+ try:
|
|
||||||
+ # If there's a comma, guess that it's already in "Last, First" format
|
|
||||||
+ if ',' in author:
|
|
||||||
+ return author
|
|
||||||
+ L = author.split()
|
|
||||||
+ i = len(L) - 1
|
|
||||||
+ if i == 0:
|
|
||||||
+ return author # The string's one word--forget it
|
|
||||||
+ if author.upper() == author or author.lower() == author:
|
|
||||||
+ # Damn, the name is all upper- or lower-case.
|
|
||||||
+ while i > 0 and L[i-1].lower() in smallNameParts:
|
|
||||||
+ i = i - 1
|
|
||||||
+ else:
|
|
||||||
+ # Mixed case; assume that small parts of the last name will be
|
|
||||||
+ # in lowercase, and check them against the list.
|
|
||||||
+ while i>0 and (L[i-1][0] in lowercase or
|
|
||||||
+ L[i-1].lower() in smallNameParts):
|
|
||||||
+ i = i - 1
|
|
||||||
+ author = SPACE.join(L[-1:] + L[i:-1]) + ', ' + SPACE.join(L[:i])
|
|
||||||
+ except UnicodeDecodeError:
|
|
||||||
return author
|
|
||||||
- L = author.split()
|
|
||||||
- i = len(L) - 1
|
|
||||||
- if i == 0:
|
|
||||||
- return author # The string's one word--forget it
|
|
||||||
- if author.upper() == author or author.lower() == author:
|
|
||||||
- # Damn, the name is all upper- or lower-case.
|
|
||||||
- while i > 0 and L[i-1].lower() in smallNameParts:
|
|
||||||
- i = i - 1
|
|
||||||
- else:
|
|
||||||
- # Mixed case; assume that small parts of the last name will be
|
|
||||||
- # in lowercase, and check them against the list.
|
|
||||||
- while i>0 and (L[i-1][0] in lowercase or
|
|
||||||
- L[i-1].lower() in smallNameParts):
|
|
||||||
- i = i - 1
|
|
||||||
- author = SPACE.join(L[-1:] + L[i:-1]) + ', ' + SPACE.join(L[:i])
|
|
||||||
return author
|
|
||||||
|
|
||||||
# Abstract class for databases
|
|
||||||
BIN
mailman-3.3.2.tar.gz
Normal file
BIN
mailman-3.3.2.tar.gz
Normal file
Binary file not shown.
@ -1,47 +0,0 @@
|
|||||||
#!/usr/bin/python
|
|
||||||
|
|
||||||
# This script inserts the mailman user name into the crontab entries after
|
|
||||||
# the 5 time/date fields so that it can be installed under /etc/cron.d
|
|
||||||
#
|
|
||||||
# usage: mailman-crontab-edit [-s src_file] [-u mailman_user] [-d dst_file]
|
|
||||||
# src_file defaults to stdin
|
|
||||||
# mailman_user defaults to mailman
|
|
||||||
# dst_file defaults to stdout
|
|
||||||
|
|
||||||
import sys, re, getopt
|
|
||||||
|
|
||||||
srcFile = None
|
|
||||||
dstFile = None
|
|
||||||
mmUser = None
|
|
||||||
|
|
||||||
opts, args = getopt.getopt(sys.argv[1:], "s:d:u:")
|
|
||||||
for o, a in opts:
|
|
||||||
if o == "-s":
|
|
||||||
srcFile = a
|
|
||||||
if o == "-d":
|
|
||||||
dstFile = a
|
|
||||||
if o == "-u":
|
|
||||||
mmUser = a
|
|
||||||
|
|
||||||
if srcFile:
|
|
||||||
inFD = open(srcFile)
|
|
||||||
else:
|
|
||||||
inFD = sys.stdin
|
|
||||||
|
|
||||||
if dstFile:
|
|
||||||
outFD = open(dstFile, mode='w')
|
|
||||||
else:
|
|
||||||
outFD = sys.stdout
|
|
||||||
|
|
||||||
if not mmUser:
|
|
||||||
mmUser = "mailman"
|
|
||||||
|
|
||||||
comment_re = re.compile(r'^\s*#')
|
|
||||||
time_date_re = re.compile(r'(^\s*(\S+\s+){5,5})')
|
|
||||||
|
|
||||||
for line in inFD:
|
|
||||||
if not comment_re.search(line):
|
|
||||||
match = time_date_re.search(line)
|
|
||||||
if match:
|
|
||||||
line = time_date_re.sub(r'\1 %s ' % mmUser, line)
|
|
||||||
print >>outFD, line,
|
|
||||||
@ -1,13 +0,0 @@
|
|||||||
diff --git a/Makefile.in b/Makefile.in
|
|
||||||
index dc2fc59..45988b4 100644
|
|
||||||
--- a/Makefile.in
|
|
||||||
+++ b/Makefile.in
|
|
||||||
@@ -129,7 +129,7 @@ doinstall: $(SUBDIRS)
|
|
||||||
do \
|
|
||||||
(cd $$d; $(MAKE) DESTDIR=$(DESTDIR) install); \
|
|
||||||
done
|
|
||||||
- $(PYTHON) -c 'from compileall import *; compile_dir("$(DESTDIR)$(prefix)/Mailman", ddir="$(prefix)/Mailman")'
|
|
||||||
+ $(PYTHON) -c 'from compileall import *; compile_dir("$(DESTDIR)$(prefix)/Mailman", 20, "$(prefix)", 1)'
|
|
||||||
|
|
||||||
# Only run bin/update if we aren't installing in DESTDIR, as this
|
|
||||||
# means there are probably no lists to deal with, and it wouldn't
|
|
||||||
224
mailman-subject-prefix.patch
Normal file
224
mailman-subject-prefix.patch
Normal file
@ -0,0 +1,224 @@
|
|||||||
|
From 700a1e2e3572ec2c8766da9acdaf8babce5d8d20 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Neal Gompa <ngompa13@gmail.com>
|
||||||
|
Date: Thu, 15 Oct 2020 10:30:07 -0400
|
||||||
|
Subject: [PATCH] Cover some subject prefix use cases
|
||||||
|
MIME-Version: 1.0
|
||||||
|
Content-Type: text/plain; charset=UTF-8
|
||||||
|
Content-Transfer-Encoding: 8bit
|
||||||
|
|
||||||
|
The subject_prefix handler has many bugs and was mostly not covered
|
||||||
|
for lists with a non-ascii charset.
|
||||||
|
|
||||||
|
Co-authored-by: Aurélien Bompard <aurelien@bompard.org>
|
||||||
|
Signed-off-by: Neal Gompa <ngompa13@gmail.com>
|
||||||
|
---
|
||||||
|
src/mailman/handlers/subject_prefix.py | 19 +++--
|
||||||
|
.../handlers/tests/test_subject_prefix.py | 81 +++++++++++++++++--
|
||||||
|
2 files changed, 87 insertions(+), 13 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/src/mailman/handlers/subject_prefix.py b/src/mailman/handlers/subject_prefix.py
|
||||||
|
index 95ec0ec2d..10ad07875 100644
|
||||||
|
--- a/src/mailman/handlers/subject_prefix.py
|
||||||
|
+++ b/src/mailman/handlers/subject_prefix.py
|
||||||
|
@@ -39,13 +39,12 @@ def ascii_header(mlist, msgdata, subject, prefix, prefix_pattern, ws):
|
||||||
|
if charset not in ASCII_CHARSETS:
|
||||||
|
return None
|
||||||
|
subject_text = EMPTYSTRING.join(str(subject).splitlines())
|
||||||
|
+ subject_text = re.sub(prefix_pattern, '', subject_text)
|
||||||
|
# At this point, the subject may become null if someone posted mail
|
||||||
|
# with "Subject: [subject prefix]".
|
||||||
|
if subject_text.strip() == '':
|
||||||
|
with _.using(mlist.preferred_language.code):
|
||||||
|
subject_text = _('(no subject)')
|
||||||
|
- else:
|
||||||
|
- subject_text = re.sub(prefix_pattern, '', subject_text)
|
||||||
|
msgdata['stripped_subject'] = subject_text
|
||||||
|
rematch = re.match(RE_PATTERN, subject_text, re.I)
|
||||||
|
if rematch:
|
||||||
|
@@ -83,13 +82,12 @@ def all_same_charset(mlist, msgdata, subject, prefix, prefix_pattern, ws):
|
||||||
|
if charset != list_charset:
|
||||||
|
return None
|
||||||
|
subject_text = EMPTYSTRING.join(chunks)
|
||||||
|
+ subject_text = re.sub(prefix_pattern, '', subject_text)
|
||||||
|
# At this point, the subject may become null if someone posted mail
|
||||||
|
# with "Subject: [subject prefix]".
|
||||||
|
if subject_text.strip() == '':
|
||||||
|
- with _.push(mlist.preferred_language.code):
|
||||||
|
+ with _.using(mlist.preferred_language.code):
|
||||||
|
subject_text = _('(no subject)')
|
||||||
|
- else:
|
||||||
|
- subject_text = re.sub(prefix_pattern, '', subject_text)
|
||||||
|
msgdata['stripped_subject'] = subject_text
|
||||||
|
rematch = re.match(RE_PATTERN, subject_text, re.I)
|
||||||
|
if rematch:
|
||||||
|
@@ -114,7 +112,7 @@ def mixed_charsets(mlist, msgdata, subject, prefix, prefix_pattern, ws):
|
||||||
|
list_charset = mlist.preferred_language.charset
|
||||||
|
chunks = decode_header(subject.encode())
|
||||||
|
if len(chunks) == 0:
|
||||||
|
- with _.push(mlist.preferred_language.code):
|
||||||
|
+ with _.using(mlist.preferred_language.code):
|
||||||
|
subject_text = _('(no subject)')
|
||||||
|
chunks = [(prefix, list_charset),
|
||||||
|
(subject_text, list_charset),
|
||||||
|
@@ -134,13 +132,20 @@ def mixed_charsets(mlist, msgdata, subject, prefix, prefix_pattern, ws):
|
||||||
|
chunks.insert(0, ('', 'us-ascii'))
|
||||||
|
first_text = ''
|
||||||
|
first_text = re.sub(prefix_pattern, '', first_text).lstrip()
|
||||||
|
+ if not first_text.strip() and len(chunks) <= 1:
|
||||||
|
+ with _.using(mlist.preferred_language.code):
|
||||||
|
+ subject_text = _('(no subject)')
|
||||||
|
+ chunks = [(prefix.strip(), list_charset),
|
||||||
|
+ (subject_text, list_charset),
|
||||||
|
+ ]
|
||||||
|
+ return make_header(chunks, continuation_ws=ws)
|
||||||
|
rematch = re.match(RE_PATTERN, first_text, re.I)
|
||||||
|
if rematch:
|
||||||
|
first_text = 'Re: ' + first_text[rematch.end():]
|
||||||
|
chunks[0] = (first_text, chunk_charset)
|
||||||
|
# The subject text stripped of the prefix, for use in the NNTP gateway.
|
||||||
|
msgdata['stripped_subject'] = str(make_header(chunks, continuation_ws=ws))
|
||||||
|
- chunks.insert(0, (prefix, list_charset))
|
||||||
|
+ chunks.insert(0, (prefix.strip(), list_charset))
|
||||||
|
return make_header(chunks, continuation_ws=ws)
|
||||||
|
|
||||||
|
|
||||||
|
diff --git a/src/mailman/handlers/tests/test_subject_prefix.py b/src/mailman/handlers/tests/test_subject_prefix.py
|
||||||
|
index c2a257035..1d8bc175d 100644
|
||||||
|
--- a/src/mailman/handlers/tests/test_subject_prefix.py
|
||||||
|
+++ b/src/mailman/handlers/tests/test_subject_prefix.py
|
||||||
|
@@ -33,6 +33,13 @@ class TestSubjectPrefix(unittest.TestCase):
|
||||||
|
def setUp(self):
|
||||||
|
self._mlist = create_list('test@example.com')
|
||||||
|
self._process = config.handlers['subject-prefix'].process
|
||||||
|
+ language_manager = getUtility(ILanguageManager)
|
||||||
|
+ if 'xx' not in language_manager:
|
||||||
|
+ language_manager.add('xx', 'utf-8', 'Freedonia')
|
||||||
|
+
|
||||||
|
+ def tearDown(self):
|
||||||
|
+ # The LanguageManager may need a 'remove' method.
|
||||||
|
+ del getUtility(ILanguageManager)._languages['xx']
|
||||||
|
|
||||||
|
def test_isdigest(self):
|
||||||
|
# If the message is destined for the digest, the Subject header does
|
||||||
|
@@ -114,6 +121,14 @@ class TestSubjectPrefix(unittest.TestCase):
|
||||||
|
self._process(self._mlist, msg, {})
|
||||||
|
self.assertEqual(str(msg['subject']), '[Test] A test message')
|
||||||
|
|
||||||
|
+ def test_multiline_subject_non_ascii_list(self):
|
||||||
|
+ # The subject appears on multiple lines on a non-ascii list.
|
||||||
|
+ self._mlist.preferred_language = 'xx'
|
||||||
|
+ msg = Message()
|
||||||
|
+ msg['Subject'] = '\n A test message'
|
||||||
|
+ self._process(self._mlist, msg, {})
|
||||||
|
+ self.assertEqual(str(msg['subject']), '[Test] A test message')
|
||||||
|
+
|
||||||
|
def test_i18n_prefix(self):
|
||||||
|
# The Subject header is encoded, but the prefix is still added.
|
||||||
|
msg = Message()
|
||||||
|
@@ -130,7 +145,7 @@ class TestSubjectPrefix(unittest.TestCase):
|
||||||
|
msg['Subject'] = '[Test] '
|
||||||
|
self._process(self._mlist, msg, {})
|
||||||
|
subject = msg['subject']
|
||||||
|
- self.assertEqual(str(subject), '[Test] ')
|
||||||
|
+ self.assertEqual(str(subject), '[Test] (no subject)')
|
||||||
|
|
||||||
|
def test_prefix_only_all_same(self):
|
||||||
|
# Incoming subject is only the prefix.
|
||||||
|
@@ -141,7 +156,7 @@ class TestSubjectPrefix(unittest.TestCase):
|
||||||
|
self._process(self._mlist, msg, {})
|
||||||
|
self._mlist.preferred_language.charset = old_charset
|
||||||
|
subject = msg['subject']
|
||||||
|
- self.assertEqual(str(subject), '[Test] ')
|
||||||
|
+ self.assertEqual(str(subject), '[Test] (no subject)')
|
||||||
|
|
||||||
|
def test_prefix_only_mixed(self):
|
||||||
|
# Incoming subject is only the prefix.
|
||||||
|
@@ -149,7 +164,7 @@ class TestSubjectPrefix(unittest.TestCase):
|
||||||
|
msg['Subject'] = '=?utf-8?Q?[Test]_?='
|
||||||
|
self._process(self._mlist, msg, {})
|
||||||
|
subject = msg['subject']
|
||||||
|
- self.assertEqual(str(subject), '[Test] ')
|
||||||
|
+ self.assertEqual(str(subject), '[Test] (no subject)')
|
||||||
|
|
||||||
|
def test_re_only(self):
|
||||||
|
# Incoming subject is only Re:.
|
||||||
|
@@ -198,15 +213,13 @@ class TestSubjectPrefix(unittest.TestCase):
|
||||||
|
def test_decode_header_returns_string(self):
|
||||||
|
# Under some circumstances, email.header.decode_header() returns a
|
||||||
|
# string value. Ensure we can handle that.
|
||||||
|
- manager = getUtility(ILanguageManager)
|
||||||
|
- manager.add('xx', 'iso-8859-1', 'Xlandia')
|
||||||
|
self._mlist.preferred_language = 'xx'
|
||||||
|
msg = Message()
|
||||||
|
msg['Subject'] = 'Plain text'
|
||||||
|
self._process(self._mlist, msg, {})
|
||||||
|
subject = msg['subject']
|
||||||
|
self.assertEqual(subject.encode(),
|
||||||
|
- '=?iso-8859-1?q?=5BTest=5D_?= Plain text')
|
||||||
|
+ '=?utf-8?b?W1Rlc3Rd?= Plain text')
|
||||||
|
|
||||||
|
def test_unknown_encoded_subject(self):
|
||||||
|
msg = Message()
|
||||||
|
@@ -215,3 +228,59 @@ class TestSubjectPrefix(unittest.TestCase):
|
||||||
|
subject = msg['subject']
|
||||||
|
self.assertEqual(str(subject),
|
||||||
|
'[Test] Non-ascii subject - fran<61>ais')
|
||||||
|
+
|
||||||
|
+ def test_non_ascii_list(self):
|
||||||
|
+ # The mailing list has a non-ascii language
|
||||||
|
+ self._mlist.preferred_language = 'xx'
|
||||||
|
+ msg = Message()
|
||||||
|
+ msg['Subject'] = 'A test message'
|
||||||
|
+ self._process(self._mlist, msg, {})
|
||||||
|
+ self.assertEqual(str(msg['subject']), '[Test] A test message')
|
||||||
|
+
|
||||||
|
+ def test_no_subject(self):
|
||||||
|
+ # The email has no subject
|
||||||
|
+ msg = Message()
|
||||||
|
+ msg['Subject'] = ''
|
||||||
|
+ self._process(self._mlist, msg, {})
|
||||||
|
+ self.assertEqual(str(msg['subject']), '[Test] (no subject)')
|
||||||
|
+
|
||||||
|
+ def test_no_subject_non_ascii_list(self):
|
||||||
|
+ # The email has no subject on a non-ascii list
|
||||||
|
+ self._mlist.preferred_language = 'xx'
|
||||||
|
+ msg = Message()
|
||||||
|
+ msg['Subject'] = ''
|
||||||
|
+ self._process(self._mlist, msg, {})
|
||||||
|
+ self.assertEqual(str(msg['subject']), '[Test] (no subject)')
|
||||||
|
+
|
||||||
|
+ def test_no_real_subject(self):
|
||||||
|
+ # The email has no subject
|
||||||
|
+ msg = Message()
|
||||||
|
+ msg['Subject'] = '[Test] '
|
||||||
|
+ self._process(self._mlist, msg, {})
|
||||||
|
+ self.assertEqual(str(msg['subject']), '[Test] (no subject)')
|
||||||
|
+
|
||||||
|
+ def test_no_real_subject_non_ascii_list(self):
|
||||||
|
+ # The email has no subject on a non-ascii list
|
||||||
|
+ self._mlist.preferred_language = 'xx'
|
||||||
|
+ msg = Message()
|
||||||
|
+ msg['Subject'] = '[Test] '
|
||||||
|
+ self._process(self._mlist, msg, {})
|
||||||
|
+ self.assertEqual(str(msg['subject']), '[Test] (no subject)')
|
||||||
|
+
|
||||||
|
+ def test_non_ascii_subject_and_list(self):
|
||||||
|
+ # The mailing list has a non-ascii language and the subject is
|
||||||
|
+ # non-ascii with the same encoding.
|
||||||
|
+ self._mlist.preferred_language = 'xx'
|
||||||
|
+ msg = Message()
|
||||||
|
+ msg['Subject'] = '=?utf-8?q?d=C3=A9sirable?='
|
||||||
|
+ self._process(self._mlist, msg, {})
|
||||||
|
+ self.assertEqual(str(msg['subject']), '[Test] d\xe9sirable')
|
||||||
|
+
|
||||||
|
+ def test_non_ascii_empty_subject_and_non_ascii_list(self):
|
||||||
|
+ # The mailing list has a non-ascii language and the subject is
|
||||||
|
+ # non-ascii with the same encoding, but actually empty.
|
||||||
|
+ self._mlist.preferred_language = 'xx'
|
||||||
|
+ msg = Message()
|
||||||
|
+ msg['Subject'] = '=?utf-8?q?[Test]_?='
|
||||||
|
+ self._process(self._mlist, msg, {})
|
||||||
|
+ self.assertEqual(str(msg['subject']), '[Test] (no subject)')
|
||||||
|
--
|
||||||
|
2.28.0
|
||||||
|
|
||||||
@ -1,2 +0,0 @@
|
|||||||
d /var/lock/mailman 0775 root mailman
|
|
||||||
d /var/run/mailman 0775 root mailman
|
|
||||||
@ -1,13 +0,0 @@
|
|||||||
#!/usr/bin/python
|
|
||||||
|
|
||||||
# This script is needed, when SELinux is enabled:
|
|
||||||
# mailman_mail_t context cannot write to the directory
|
|
||||||
# @mmdir@/Mailman so when you change mm_cfg.py,
|
|
||||||
# mailman cannot create the .pyc
|
|
||||||
#
|
|
||||||
# This script is called in the init script, which is run in unconfined_t
|
|
||||||
# so the .pyc is created and the AVC denial is avoided. (bz#481446)
|
|
||||||
|
|
||||||
import py_compile
|
|
||||||
|
|
||||||
py_compile.compile("@mmdir@/Mailman/mm_cfg.py")
|
|
||||||
@ -0,0 +1,73 @@
|
|||||||
|
From a4bcacc25398fcea819bd9e6b9a531c3007aa386 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Neal Gompa <ngompa13@gmail.com>
|
||||||
|
Date: Fri, 16 Oct 2020 03:47:38 -0400
|
||||||
|
Subject: [PATCH] Use importlib.resources for Python 3.9+ and
|
||||||
|
importlib_resources otherwise
|
||||||
|
|
||||||
|
This makes it possible to use Mailman 3 in environments where importlib_resources
|
||||||
|
is not available.
|
||||||
|
|
||||||
|
Signed-off-by: Neal Gompa <ngompa13@gmail.com>
|
||||||
|
---
|
||||||
|
setup.py | 2 +-
|
||||||
|
src/mailman/__init__.py | 5 +++++
|
||||||
|
src/mailman/testing/__init__.py | 23 +++++++++++++++++++++++
|
||||||
|
3 files changed, 29 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/setup.py b/setup.py
|
||||||
|
index e1b2e07c5..b768ef3d2 100644
|
||||||
|
--- a/setup.py
|
||||||
|
+++ b/setup.py
|
||||||
|
@@ -121,7 +121,7 @@ case second 'm'. Any other spelling is incorrect.""",
|
||||||
|
'flufl.bounce',
|
||||||
|
'flufl.i18n>=2.0',
|
||||||
|
'flufl.lock>=3.1',
|
||||||
|
- 'importlib_resources>=1.1.0',
|
||||||
|
+ 'importlib_resources>=1.1.0 ; python_version<"3.9"',
|
||||||
|
'gunicorn',
|
||||||
|
'lazr.config',
|
||||||
|
'python-dateutil>=2.0',
|
||||||
|
diff --git a/src/mailman/__init__.py b/src/mailman/__init__.py
|
||||||
|
index fa5233fab..00990be45 100644
|
||||||
|
--- a/src/mailman/__init__.py
|
||||||
|
+++ b/src/mailman/__init__.py
|
||||||
|
@@ -37,3 +37,8 @@ if 'build_sphinx' not in sys.argv: # pragma: nocover
|
||||||
|
else:
|
||||||
|
from mailman.core.i18n import initialize
|
||||||
|
initialize()
|
||||||
|
+
|
||||||
|
+# Switch over to the internal importlib.resources module on Python 3.9+
|
||||||
|
+if sys.version_info >= (3, 9, 0):
|
||||||
|
+ import importlib.resources
|
||||||
|
+ sys.modules['importlib_resources'] = importlib.resources
|
||||||
|
diff --git a/src/mailman/testing/__init__.py b/src/mailman/testing/__init__.py
|
||||||
|
index e69de29bb..2b2ed536a 100644
|
||||||
|
--- a/src/mailman/testing/__init__.py
|
||||||
|
+++ b/src/mailman/testing/__init__.py
|
||||||
|
@@ -0,0 +1,23 @@
|
||||||
|
+# Copyright (C) 2009-2020 by the Free Software Foundation, Inc.
|
||||||
|
+#
|
||||||
|
+# This file is part of GNU Mailman.
|
||||||
|
+#
|
||||||
|
+# GNU Mailman is free software: you can redistribute it and/or modify it under
|
||||||
|
+# the terms of the GNU General Public License as published by the Free
|
||||||
|
+# Software Foundation, either version 3 of the License, or (at your option)
|
||||||
|
+# any later version.
|
||||||
|
+#
|
||||||
|
+# GNU Mailman is distributed in the hope that it will be useful, but WITHOUT
|
||||||
|
+# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
|
+# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
||||||
|
+# more details.
|
||||||
|
+#
|
||||||
|
+# You should have received a copy of the GNU General Public License along with
|
||||||
|
+# GNU Mailman. If not, see <https://www.gnu.org/licenses/>.
|
||||||
|
+
|
||||||
|
+import sys
|
||||||
|
+
|
||||||
|
+# Switch over to the internal importlib.resources module on Python 3.9+
|
||||||
|
+if sys.version_info >= (3, 9, 0):
|
||||||
|
+ import importlib.resources
|
||||||
|
+ sys.modules['importlib_resources'] = importlib.resources
|
||||||
|
--
|
||||||
|
2.28.0
|
||||||
|
|
||||||
26
mailman.cfg
Normal file
26
mailman.cfg
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
# This is the absolute bare minimum base configuration file. User supplied
|
||||||
|
# configurations are pushed onto this.
|
||||||
|
|
||||||
|
[mailman]
|
||||||
|
# This address is the "site owner" address. Certain messages which must be
|
||||||
|
# delivered to a human, but which can't be delivered to a list owner (e.g. a
|
||||||
|
# bounce from a list owner), will be sent to this address. It should point to
|
||||||
|
# a human.
|
||||||
|
site_owner: root@localhost
|
||||||
|
|
||||||
|
# The local URL part to the administration interface (Postorius).
|
||||||
|
# The full URL will be constructed by prepending the domain URL set in the
|
||||||
|
# list's domain properties.
|
||||||
|
#listinfo_url = /postorius/
|
||||||
|
|
||||||
|
|
||||||
|
# Set the paths to be Fedora-compliant
|
||||||
|
layout: fhs
|
||||||
|
[paths.fhs]
|
||||||
|
bin_dir: /usr/libexec/mailman3
|
||||||
|
var_dir: /var/lib/mailman3
|
||||||
|
queue_dir: /var/spool/mailman3
|
||||||
|
log_dir: /var/log/mailman3
|
||||||
|
lock_dir: /run/lock/mailman3
|
||||||
|
ext_dir: /etc/mailman3.d
|
||||||
|
pid_file: /run/mailman3/master.pid
|
||||||
@ -1,8 +0,0 @@
|
|||||||
@LOG_DIR@/bounce @LOG_DIR@/digest @LOG_DIR@/error @LOG_DIR@/post @LOG_DIR@/smtp @LOG_DIR@/smtp-failure @LOG_DIR@/qrunner @LOG_DIR@/locks @LOG_DIR@/fromusenet @LOG_DIR@/subscribe @LOG_DIR@/vette {
|
|
||||||
missingok
|
|
||||||
sharedscripts
|
|
||||||
su root root
|
|
||||||
postrotate
|
|
||||||
@MMDIR@/bin/mailmanctl reopen >/dev/null 2>&1 || true
|
|
||||||
endscript
|
|
||||||
}
|
|
||||||
@ -1,20 +0,0 @@
|
|||||||
[Unit]
|
|
||||||
Description=GNU Mailing List Manager
|
|
||||||
After=syslog.target network.target
|
|
||||||
|
|
||||||
[Service]
|
|
||||||
ExecStartPre=/usr/lib/mailman/bin/mailman-update-cfg
|
|
||||||
ExecStartPre=/usr/bin/install -m644 -o root -g root /usr/lib/mailman/cron/crontab.in /etc/cron.d/mailman
|
|
||||||
ExecStartPre=/bin/touch /var/log/mailman/error
|
|
||||||
ExecStartPre=/bin/chown mailman:mailman /var/log/mailman/error
|
|
||||||
ExecStartPre=/bin/chmod 660 /var/log/mailman/error
|
|
||||||
ExecStart=/usr/lib/mailman/bin/mailmanctl -s start
|
|
||||||
ExecReload=/usr/lib/mailman/bin/mailmanctl restart
|
|
||||||
ExecStop=/usr/lib/mailman/bin/mailman-update-cfg
|
|
||||||
ExecStop=/usr/lib/mailman/bin/mailmanctl stop
|
|
||||||
ExecStop=/bin/sh -c 'echo -e "# DO NOT EDIT THIS FILE!\n#\n# Contents of this file managed by /etc/init.d/mailman\n# Master copy is /usr/lib/mailman/cron/crontab.in" > /etc/cron.d/mailman'
|
|
||||||
Type=forking
|
|
||||||
|
|
||||||
[Install]
|
|
||||||
WantedBy=multi-user.target
|
|
||||||
|
|
||||||
579
mailman.spec
579
mailman.spec
@ -1,425 +1,210 @@
|
|||||||
%global __os_install_post %(echo '%{__os_install_post}' | sed -e 's!/usr/lib[^[:space:]]*/brp-python-bytecompile[[:space:]].*$!!g')
|
%global pypi_name mailman
|
||||||
%global docdir %{?_pkgdocdir}%{!?_pkgdocdir:%{_docdir}/%{name}-%{version}}
|
%global mmuser mailman
|
||||||
|
%global mmuserid 41
|
||||||
|
%global mmgroup mailman
|
||||||
|
%global mmgroupid 41
|
||||||
|
%{?python_enable_dependency_generator}
|
||||||
|
|
||||||
Name: mailman
|
Name: mailman
|
||||||
Version: 2.1.29
|
Version: 3.3.2
|
||||||
Release: 5
|
Release: 1
|
||||||
Epoch: 3
|
Epoch: 3
|
||||||
Summary: GNU Mailing List Manager
|
Summary: The GNU mailing list manager
|
||||||
License: GPLv2+
|
License: GPLv3
|
||||||
URL: http://www.list.org/
|
URL: https://pypi.org/project/mailman
|
||||||
Source0: ftp://ftp.gnu.org/pub/gnu/mailman/mailman-%{version}.tgz
|
Source0: https://files.pythonhosted.org/packages/source/m/mailman/mailman-%{version}.tar.gz
|
||||||
Source1: mm_cfg.py
|
Source1: mailman.cfg
|
||||||
Source3: httpd-mailman.conf
|
Source2: mailman3-tmpfiles.conf
|
||||||
Source4: mailman.logrotate
|
Source3: mailman3.service
|
||||||
Source6: mailman-crontab-edit
|
Source4: mailman3.logrotate
|
||||||
Source8: mailman-update-cfg
|
Source5: mailman3-digests.service
|
||||||
Source9: mailman-tmpfiles.conf
|
Source6: mailman3-digests.timer
|
||||||
Source10: mailman.service
|
Patch11: mailman-subject-prefix.patch
|
||||||
|
Patch14: mailman-use-either-importlib_resources-or-directly-importlib.patch
|
||||||
Patch1: mailman-2.1.12-multimail.patch
|
Patch15: 0001-fix-test-syntax-error.patch
|
||||||
Patch2: mailman-2.1-build.patch
|
BuildArch: noarch
|
||||||
Patch3: mailman-2.1-mailmanctl-status.patch
|
BuildRequires: glibc-langpack-en
|
||||||
Patch4: mailman-2.1.11-cron.patch
|
BuildRequires: python%{python3_pkgversion}-devel >= 3.5 python%{python3_pkgversion}-setuptools
|
||||||
Patch5: mailman-2.1.13-FHS.patch
|
%if %{undefined python_enable_dependency_generator}
|
||||||
Patch6: mailman-python-compile.patch
|
Requires: python%{python3_pkgversion} >= 3.5 python%{python3_pkgversion}-setuptools
|
||||||
Patch7: mailman-2.1.13-archive-reply.patch
|
Requires: python%{python3_pkgversion}-aiosmtpd >= 1.1 python%{python3_pkgversion}-alembic
|
||||||
Patch13: mailman-2.1.9-unicode.patch
|
Requires: python%{python3_pkgversion}-atpublic
|
||||||
Patch21: mailman-2.1.13-env-python.patch
|
Requires: python%{python3_pkgversion}-authheaders >= 0.9.2
|
||||||
Patch22: mailman-2.1.15-check_perms.patch
|
Requires: python%{python3_pkgversion}-authres >= 1.0.1
|
||||||
|
Requires: python%{python3_pkgversion}-click >= 7.0
|
||||||
BuildRequires: automake gcc python2-devel systemd python2-dns
|
Requires: python%{python3_pkgversion}-dateutil >= 2.0
|
||||||
Requires(pre): shadow-utils
|
Requires: python%{python3_pkgversion}-dns >= 1.14.0
|
||||||
Requires: cronie httpd python2 coreutils python2-dns
|
Requires: python%{python3_pkgversion}-falcon >= 1.0.0
|
||||||
|
Requires: python%{python3_pkgversion}-flufl.bounce
|
||||||
|
Requires: python%{python3_pkgversion}-flufl.i18n >= 2.0.1
|
||||||
|
Requires: python%{python3_pkgversion}-flufl.lock >= 3.1
|
||||||
|
Requires: python%{python3_pkgversion}-gunicorn python%{python3_pkgversion}-lazr.config
|
||||||
|
Requires: python%{python3_pkgversion}-passlib >= 1.6.0
|
||||||
|
Requires: python%{python3_pkgversion}-requests
|
||||||
|
Requires: python%{python3_pkgversion}-sqlalchemy >= 1.2.3
|
||||||
|
Requires: python%{python3_pkgversion}-zope-component
|
||||||
|
Requires: python%{python3_pkgversion}-zope-configuration
|
||||||
|
Requires: python%{python3_pkgversion}-zope-event
|
||||||
|
Requires: python%{python3_pkgversion}-zope-interface >= 5.0
|
||||||
|
Requires: python%{python3_pkgversion}-importlib-resources
|
||||||
|
%endif
|
||||||
|
BuildRequires: python%{python3_pkgversion}-aiosmtpd >= 1.1 python%{python3_pkgversion}-alembic
|
||||||
|
BuildRequires: python%{python3_pkgversion}-atpublic
|
||||||
|
BuildRequires: python%{python3_pkgversion}-authheaders >= 0.9.2
|
||||||
|
BuildRequires: python%{python3_pkgversion}-authres >= 1.0.1
|
||||||
|
BuildRequires: python%{python3_pkgversion}-click >= 7.0
|
||||||
|
BuildRequires: python%{python3_pkgversion}-dateutil >= 2.0
|
||||||
|
BuildRequires: python%{python3_pkgversion}-dns >= 1.14.0
|
||||||
|
BuildRequires: python%{python3_pkgversion}-falcon >= 1.0.0
|
||||||
|
BuildRequires: python%{python3_pkgversion}-flufl.bounce
|
||||||
|
BuildRequires: python%{python3_pkgversion}-flufl.i18n >= 2.0.1
|
||||||
|
BuildRequires: python%{python3_pkgversion}-flufl.lock >= 3.1
|
||||||
|
BuildRequires: python%{python3_pkgversion}-flufl.testing python%{python3_pkgversion}-gunicorn
|
||||||
|
BuildRequires: python%{python3_pkgversion}-lazr.config
|
||||||
|
BuildRequires: python%{python3_pkgversion}-mock
|
||||||
|
BuildRequires: python%{python3_pkgversion}-nose2 python%{python3_pkgversion}-passlib >= 1.6.0
|
||||||
|
BuildRequires: python%{python3_pkgversion}-psycopg2 python%{python3_pkgversion}-requests
|
||||||
|
BuildRequires: python%{python3_pkgversion}-sqlalchemy >= 1.2.3
|
||||||
|
BuildRequires: python%{python3_pkgversion}-zope-component
|
||||||
|
BuildRequires: python%{python3_pkgversion}-zope-configuration
|
||||||
|
BuildRequires: python%{python3_pkgversion}-zope-event
|
||||||
|
BuildRequires: python%{python3_pkgversion}-zope-interface >= 5.0
|
||||||
|
BuildRequires: python%{python3_pkgversion}-importlib-resources
|
||||||
|
Provides: %{name}-selinux == %{version}-%{release}
|
||||||
|
%global selinux_variants mls targeted
|
||||||
|
Requires: selinux-policy >= %{_selinux_policy_version}
|
||||||
|
BuildRequires: git pkgconfig(systemd) selinux-policy selinux-policy-devel
|
||||||
|
Requires(post): selinux-policy-base >= %{_selinux_policy_version}
|
||||||
|
Requires(post): libselinux-utils
|
||||||
|
Requires(post): policycoreutils
|
||||||
|
Requires(post): policycoreutils-python-utils
|
||||||
|
BuildRequires: checkpolicy, selinux-policy-devel util-linux
|
||||||
%{?systemd_requires}
|
%{?systemd_requires}
|
||||||
|
BuildRequires: systemd
|
||||||
|
Requires(pre): shadow-utils
|
||||||
|
|
||||||
%description
|
%description
|
||||||
Mailman is free software for managing electronic mail discussion and
|
This is GNU Mailman, a mailing list management system distributed under the
|
||||||
e-newsletter lists. Mailman is integrated with the web, making it easy
|
terms of the GNU General Public License (GPL) version 3 or later. The name of
|
||||||
for users to manage their accounts and for list owners to administer
|
this software is spelled 'Mailman' with a leading capital 'M' but with a lower
|
||||||
their lists. Mailman supports built-in archiving, automatic bounce
|
case second `m'. Any other spelling is incorrect.
|
||||||
processing, content filtering, digest delivery, spam filters, and more.
|
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%autosetup -n %{name}-%{version} -p1
|
%autosetup -n %{pypi_name}-%{version} -p1
|
||||||
|
mkdir SELinux
|
||||||
rm -f contrib/redhat_fhs.patch
|
echo '%{_localstatedir}/lib/mailman3/data(/.*)? gen_context(system_u:object_r:etc_mail_t,s0)' \
|
||||||
mv contrib/sitemapgen contrib/sitemapgen.in
|
> SELinux/mailman3.fc
|
||||||
|
cat > SELinux/mailman3.te << EOF
|
||||||
|
policy_module(mailman3, 1.4)
|
||||||
|
EOF
|
||||||
|
|
||||||
%build
|
%build
|
||||||
CFLAGS="$RPM_OPT_FLAGS -fPIE -DPIE"; export CFLAGS
|
%py3_build
|
||||||
export LDFLAGS="$LDFLAGS -pie -Wl,-z,relro -Wl,-z,now"
|
cd SELinux
|
||||||
|
for selinuxvariant in %{selinux_variants}; do
|
||||||
rm -f configure
|
make NAME=${selinuxvariant} -f /usr/share/selinux/devel/Makefile
|
||||||
aclocal
|
mv mailman3.pp mailman3.pp.${selinuxvariant}
|
||||||
autoconf
|
make NAME=${selinuxvariant} -f /usr/share/selinux/devel/Makefile clean
|
||||||
|
done
|
||||||
./configure \
|
cd -
|
||||||
--libdir=/usr/lib \
|
|
||||||
--prefix=/usr/lib/%{name} \
|
|
||||||
--with-var-prefix=/var/lib/%{name} \
|
|
||||||
--with-config-dir=/etc/%{name} \
|
|
||||||
--with-lock-dir=/var/lock/%{name} \
|
|
||||||
--with-log-dir=/var/log/%{name} \
|
|
||||||
--with-pid-dir=/var/run/%{name} \
|
|
||||||
--with-queue-dir=/var/spool/%{name} \
|
|
||||||
--with-template-dir=/etc/%{name}/templates \
|
|
||||||
--with-python=%{__python2} \
|
|
||||||
--with-mail-gid="mail postfix mailman nobody daemon" \
|
|
||||||
--with-cgi-id=apache \
|
|
||||||
--with-cgi-gid=apache \
|
|
||||||
--with-mailhost=localhost.localdomain \
|
|
||||||
--with-urlhost=localhost.localdomain \
|
|
||||||
--without-permcheck
|
|
||||||
|
|
||||||
function SubstituteParameters()
|
|
||||||
{
|
|
||||||
sed -e 's|@VAR_PREFIX@|/var/lib/%{name}|g' \
|
|
||||||
-e 's|@VARMMDIR@|/var/lib/%{name}|g' \
|
|
||||||
-e 's|@prefix@|/usr/lib/%{name}|g' \
|
|
||||||
-e 's|@MMDIR@|/usr/lib/%{name}|g' \
|
|
||||||
-e 's|@CONFIG_DIR@|/etc/%{name}|g' \
|
|
||||||
-e 's|@DATA_DIR@|/var/lib/%{name}/data|g' \
|
|
||||||
-e 's|@LOCK_DIR@|/var/lock/%{name}|g' \
|
|
||||||
-e 's|@LOG_DIR@|/var/log/%{name}|g' \
|
|
||||||
-e 's|@PID_DIR@|/var/run/%{name}|g' \
|
|
||||||
-e 's|@QUEUE_DIR@|/var/spool/%{name}|g' \
|
|
||||||
-e 's|@DOC_DIR@|%{docdir}|g' \
|
|
||||||
-e 's|@HTTPD_CONF_DIR@|/etc/httpd/conf.d|g' \
|
|
||||||
-e 's|@HTTPD_CONF_FILE@|%{name}.conf|g' \
|
|
||||||
$1 > $2
|
|
||||||
}
|
|
||||||
|
|
||||||
SubstituteParameters "%{SOURCE1}" "Mailman/mm_cfg.py.dist"
|
|
||||||
SubstituteParameters "%{SOURCE3}" "httpd-mailman.conf"
|
|
||||||
SubstituteParameters "%{SOURCE4}" "mailman.logrotate"
|
|
||||||
rm -f contrib/*.in
|
|
||||||
|
|
||||||
%make_build
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%make_install
|
%py3_install
|
||||||
|
mkdir -p %{buildroot}%{_libexecdir}/mailman3
|
||||||
mkdir -p %{buildroot}/etc/cron.d
|
mv %{buildroot}%{_bindir}/* %{buildroot}%{_libexecdir}/mailman3/
|
||||||
cat > %{buildroot}/etc/cron.d/%{name} <<EOF
|
cat > %{buildroot}%{_bindir}/mailman3 << EOF
|
||||||
|
#!/bin/bash
|
||||||
|
if [ "\$(whoami)" != "mailman" ]; then
|
||||||
|
echo "This command must be run under the mailman user."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
%{_libexecdir}/mailman3/mailman \$@
|
||||||
EOF
|
EOF
|
||||||
|
chmod +x %{buildroot}%{_bindir}/mailman3
|
||||||
|
install -D -m 0640 %{SOURCE1} %{buildroot}%{_sysconfdir}/mailman.cfg
|
||||||
|
install -D -m 0644 %{SOURCE2} %{buildroot}%{_prefix}/lib/tmpfiles.d/mailman3.conf
|
||||||
|
install -D -m 0644 %{SOURCE3} %{buildroot}%{_unitdir}/mailman3.service
|
||||||
|
mkdir -p %{buildroot}%{_sysconfdir}/logrotate.d/
|
||||||
|
sed -e 's,@LOGDIR@,%{_localstatedir}/log/mailman3,g;s,@BINDIR@,%{_bindir},g' \
|
||||||
|
%{SOURCE4} > %{buildroot}%{_sysconfdir}/logrotate.d/mailman3
|
||||||
|
install -D -m 0644 %{SOURCE5} %{buildroot}%{_unitdir}/mailman3-digests.service
|
||||||
|
install -D -m 0644 %{SOURCE6} %{buildroot}%{_unitdir}/mailman3-digests.timer
|
||||||
|
mkdir -p %{buildroot}%{_localstatedir}/{lib,spool,log}/mailman3
|
||||||
|
mkdir -p %{buildroot}/run/mailman3 %{buildroot}/run/lock/mailman3
|
||||||
|
mkdir -p %{buildroot}%{_sysconfdir}/mailman3.d
|
||||||
|
mkdir -p %{buildroot}%{_localstatedir}/lib/mailman3/data
|
||||||
|
for selinuxvariant in %{selinux_variants}; do
|
||||||
|
install -d %{buildroot}%{_datadir}/selinux/${selinuxvariant}
|
||||||
|
install -p -m 644 SELinux/mailman3.pp.${selinuxvariant} \
|
||||||
|
%{buildroot}%{_datadir}/selinux/${selinuxvariant}/mailman3.pp
|
||||||
|
done
|
||||||
|
hardlink -cv %{buildroot}%{_datadir}/selinux
|
||||||
|
|
||||||
mkdir -p %{buildroot}/usr/share/httpd/icons
|
%check
|
||||||
cp %{buildroot}//usr/lib/%{name}/icons/* %{buildroot}/usr/share/httpd/icons
|
export LANG=en_US.UTF-8
|
||||||
|
export LC_ALL=en_US.UTF-8
|
||||||
mkdir -p %{buildroot}/etc/smrsh
|
find -name '*.rst' -exec rm {} \;
|
||||||
ln -s ../../usr/lib/%{name}/mail/%{name} %{buildroot}/etc/smrsh
|
rm -rf src/mailman/core/tests/test_logging.py
|
||||||
|
%{__python3} -m venv --system-site-packages --without-pip --clear venv
|
||||||
ln -s /etc/%{name}/sitelist.cfg %{buildroot}/var/lib/%{name}/data
|
venv/bin/python setup.py develop
|
||||||
|
venv/bin/python -m nose2 -v
|
||||||
mkdir -p %{buildroot}/etc/logrotate.d
|
|
||||||
install -m644 %{_builddir}/%{name}-%{version}/mailman.logrotate %{buildroot}/etc/logrotate.d/%{name}
|
|
||||||
|
|
||||||
install -m755 -d %{buildroot}/etc/httpd/conf.d
|
|
||||||
install -m644 %{_builddir}/%{name}-%{version}/httpd-mailman.conf %{buildroot}/etc/httpd/conf.d/%{name}.conf
|
|
||||||
|
|
||||||
install -m 755 -d %{buildroot}%{docdir}
|
|
||||||
install -m 644 %{_builddir}/%{name}-%{version}/ACKNOWLEDGMENTS %{buildroot}%{docdir}
|
|
||||||
install -m 644 %{_builddir}/%{name}-%{version}/FAQ %{buildroot}%{docdir}
|
|
||||||
install -m 644 %{_builddir}/%{name}-%{version}/NEWS %{buildroot}%{docdir}
|
|
||||||
install -m 644 %{_builddir}/%{name}-%{version}/README %{buildroot}%{docdir}
|
|
||||||
install -m 644 %{_builddir}/%{name}-%{version}/README.CONTRIB %{buildroot}%{docdir}
|
|
||||||
install -m 644 %{_builddir}/%{name}-%{version}/README-I18N.en %{buildroot}%{docdir}
|
|
||||||
install -m 644 %{_builddir}/%{name}-%{version}/README.NETSCAPE %{buildroot}%{docdir}
|
|
||||||
install -m 644 %{_builddir}/%{name}-%{version}/README.USERAGENT %{buildroot}%{docdir}
|
|
||||||
install -m 644 %{_builddir}/%{name}-%{version}/STYLEGUIDE.txt %{buildroot}%{docdir}
|
|
||||||
install -m 644 %{_builddir}/%{name}-%{version}/UPGRADING %{buildroot}%{docdir}
|
|
||||||
|
|
||||||
cp -r %{_builddir}/%{name}-%{version}/contrib %{buildroot}%{docdir}
|
|
||||||
install -m 755 -d %{buildroot}%{docdir}/admin
|
|
||||||
cp -r %{_builddir}/%{name}-%{version}/doc %{buildroot}%{docdir}/admin
|
|
||||||
|
|
||||||
mkdir -p %{buildroot}/usr/lib/%{name}/bin/
|
|
||||||
install -m755 %{SOURCE8} %{buildroot}/usr/lib/%{name}/bin/
|
|
||||||
|
|
||||||
sed -i 's,@mmdir@,/usr/lib/%{name},g' %{buildroot}/usr/lib/%{name}/bin/mailman-update-cfg
|
|
||||||
|
|
||||||
rm -rf %{buildroot}/var/lib/%{name}/icons
|
|
||||||
|
|
||||||
chmod 0644 %{buildroot}//usr/lib/%{name}/tests/fblast.py
|
|
||||||
|
|
||||||
mkdir -p %{buildroot}//var/lock/%{name}
|
|
||||||
mkdir -p %{buildroot}//var/log/%{name}
|
|
||||||
mkdir -p %{buildroot}//var/run/%{name}
|
|
||||||
mkdir -p %{buildroot}//var/spool/%{name}
|
|
||||||
mkdir -p %{buildroot}/%{_prefix}/lib/tmpfiles.d
|
|
||||||
|
|
||||||
install -m 644 -p %{SOURCE9} %{buildroot}%{_prefix}/lib/tmpfiles.d/mailman.conf
|
|
||||||
|
|
||||||
mkdir -p %{buildroot}%{_unitdir}
|
|
||||||
install -m 644 %{SOURCE10} %{buildroot}%{_unitdir}
|
|
||||||
|
|
||||||
mkdir -p %{buildroot}/etc/%{name}
|
|
||||||
mv %{buildroot}/usr/lib/%{name}/Mailman/mm_cfg.py %{buildroot}/etc/%{name}
|
|
||||||
ln -s /etc/%{name}/mm_cfg.py %{buildroot}/usr/lib/%{name}/Mailman/
|
|
||||||
|
|
||||||
cat > %{buildroot}/usr/lib/%{name}/templates/README <<EOF
|
|
||||||
Templates have been moved to /etc/%{name}/templates.
|
|
||||||
EOF
|
|
||||||
|
|
||||||
# byte-compile /usr/lib/%{name}
|
|
||||||
#py_byte_compile %{__python2} %{buildroot}/usr/lib/%{name}
|
|
||||||
find %{buildroot}/usr/lib/%{name} -type f -a -name "*.py" -print0 | xargs -0 %{__python2} -c 'import py_compile, sys; [py_compile.compile(f, dfile=f.partition("$RPM_BUILD_ROOT")[2]) for f in sys.argv[1:]]' || :
|
|
||||||
find %{buildroot}/usr/lib/%{name} -type f -a -name "*.py" -print0 | xargs -0 %{__python2} -O -c 'import py_compile, sys; [py_compile.compile(f, dfile=f.partition("$RPM_BUILD_ROOT")[2]) for f in sys.argv[1:]]' || :
|
|
||||||
|
|
||||||
|
|
||||||
find %{buildroot}//usr/lib/%{name} -type d -exec chmod 755 {} \;
|
|
||||||
find %{buildroot}//etc/%{name}/templates -type d -exec chmod 755 {} \;
|
|
||||||
|
|
||||||
chmod %{buildroot}//usr/lib/%{name} -s -R
|
|
||||||
|
|
||||||
chmod g+s %{buildroot}//usr/lib/%{name}/cgi-bin/*
|
|
||||||
chmod g+s %{buildroot}//usr/lib/%{name}/mail/mailman
|
|
||||||
|
|
||||||
chmod %{buildroot}//etc/%{name} -s -R
|
|
||||||
|
|
||||||
%pre
|
%pre
|
||||||
if grep -q "^mailman:" /etc/group 2> /dev/null ; then
|
getent group %{mmgroup} >/dev/null || \
|
||||||
/usr/sbin/groupmod -g 41 -n %{name} %{name} 2> /dev/null || :
|
groupadd -g %{mmgroupid} %{mmgroup} >/dev/null
|
||||||
else
|
getent passwd %{mmuser} >/dev/null || \
|
||||||
/usr/sbin/groupadd -g 41 %{name} 2> /dev/null || :
|
useradd -r -u %{mmuserid} -g %{mmgroupid} -d %{_localstatedir}/lib/mailman3 -s /sbin/nologin \
|
||||||
fi
|
-c "Mailman, the mailing-list manager" %{mmuser} >/dev/null
|
||||||
if grep -q "^mailman:" /etc/passwd 2> /dev/null ; then
|
for selinuxvariant in %{selinux_variants}; do
|
||||||
/usr/sbin/usermod -s /sbin/nologin -c "GNU Mailing List Manager" -d /usr/lib/%{name} -u 41 -g 41 %{name} 2> /dev/null || :
|
%selinux_relabel_pre -s ${selinuxvariant}
|
||||||
else
|
done
|
||||||
/usr/sbin/useradd -s /sbin/nologin -c "GNU Mailing List Manager" -d /usr/lib/%{name} -u 41 -g 41 -M -r %{name} 2> /dev/null || :
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ -d /var/lock/%{name} ]; then
|
|
||||||
rm -f /var/run/%{name}-restart-after-rpm-install
|
|
||||||
/sbin/systemctl status %{name}>/dev/null 2>&1
|
|
||||||
if [ $? -eq 0 ]; then
|
|
||||||
touch /var/run/%{name}-restart-after-rpm-install
|
|
||||||
/sbin/systemctl stop %{name} >/dev/null 2>&1
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ -d %{_localstatedir}/lib/rpm-state/mailman ]; then
|
|
||||||
rm -rf %{_localstatedir}/lib/rpm-state/mailman
|
|
||||||
fi
|
|
||||||
|
|
||||||
mkdir -p %{_localstatedir}/lib/rpm-state/mailman/
|
|
||||||
if [ -L /etc/%{name}/mm_cfg.py -a ! -L /usr/lib/%{name}/Mailman/mm_cfg.py -a -d /etc/%{name} ]; then
|
|
||||||
mv /usr/lib/%{name}/Mailman/mm_cfg.py %{_localstatedir}/lib/rpm-state/mailman/mm_cfg.py
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ ! -d /etc/%{name}/templates -a -d /usr/lib/%{name}/templates ]; then
|
|
||||||
mv /usr/lib/%{name}/templates %{_localstatedir}/lib/rpm-state/mailman/
|
|
||||||
fi
|
|
||||||
|
|
||||||
exit 0
|
|
||||||
|
|
||||||
%post
|
%post
|
||||||
if [ -f /var/spool/cron/%{name} ]; then
|
%systemd_post mailman3.service mailman3-digests.timer
|
||||||
crontab -u %{name} -r
|
for selinuxvariant in %{selinux_variants}; do
|
||||||
fi
|
%selinux_modules_install -s ${selinuxvariant} %{_datadir}/selinux/${selinuxvariant}/mailman3.pp || :
|
||||||
|
done
|
||||||
if [ -e /var/run/%{name}-restart-after-rpm-install ]; then
|
|
||||||
rm /var/run/%{name}-restart-after-rpm-install
|
|
||||||
/sbin/systemctl start %{name} >/dev/null 2>&1
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ -f %{_localstatedir}/lib/rpm-state/mailman/mm_cfg.py ]; then
|
|
||||||
cp -p %{_localstatedir}/lib/rpm-state/mailman/mm_cfg.py /etc/%{name}/mm_cfg.py
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ -d %{_localstatedir}/lib/rpm-state/mailman/templates ]; then
|
|
||||||
cp -pr %{_localstatedir}/lib/rpm-state/mailman/templates/* /etc/%{name}/templates
|
|
||||||
rm -rf %{_localstatedir}/lib/rpm-state/mailman/templates/
|
|
||||||
fi
|
|
||||||
|
|
||||||
if [ -d %{_localstatedir}/lib/rpm-state/mailman ]; then
|
|
||||||
rm -rf %{_localstatedir}/lib/rpm-state/mailman
|
|
||||||
fi
|
|
||||||
|
|
||||||
%systemd_post mailman.service
|
|
||||||
exit 0
|
|
||||||
|
|
||||||
%preun
|
%preun
|
||||||
%systemd_preun mailman.service
|
%systemd_preun mailman3.service mailman3-digests.timer
|
||||||
exit 0
|
|
||||||
|
|
||||||
%postun
|
%postun
|
||||||
if [ $1 = 0 ]; then
|
%systemd_postun_with_restart mailman3.service mailman3-digests.timer
|
||||||
crontab -u %{name} -r 2>/dev/null
|
if [ $1 -eq 0 ] ; then
|
||||||
|
for selinuxvariant in %{selinux_variants}; do
|
||||||
|
%selinux_modules_uninstall -s ${selinuxvariant} %{_datadir}/selinux/${selinuxvariant}/mailman3.pp || :
|
||||||
|
done
|
||||||
fi
|
fi
|
||||||
%systemd_postun_with_restart mailman.service
|
|
||||||
exit 0
|
|
||||||
|
|
||||||
%triggerun -- mailman < 3:2.1.14-9
|
%posttrans
|
||||||
%{_bindir}/systemd-sysv-convert --save mailman >/dev/null 2>&1 ||:
|
for selinuxvariant in %{selinux_variants}; do
|
||||||
/bin/systemctl enable mailman.service >/dev/null 2>&1
|
%selinux_relabel_post -s ${selinuxvariant}
|
||||||
/sbin/chkconfig --del mailman >/dev/null 2>&1 || :
|
done
|
||||||
/bin/systemctl try-restart mailman.service >/dev/null 2>&1 || :
|
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%defattr(-,root,%{name})
|
%license COPYING
|
||||||
%dir /usr/lib/%{name}
|
%{_bindir}/mailman3
|
||||||
%dir /usr/lib/%{name}/Mailman
|
%{_libexecdir}/mailman3
|
||||||
/usr/lib/%{name}/templates
|
%{python3_sitelib}/%{pypi_name}
|
||||||
/usr/lib/%{name}/bin
|
%{python3_sitelib}/%{pypi_name}-*-py%{python3_version}.egg-info
|
||||||
%dir /usr/lib/%{name}/cgi-bin/
|
%{_unitdir}/*.service
|
||||||
%attr(2755, root, %{name}) /usr/lib/%{name}/cgi-bin/*
|
%{_unitdir}/*.timer
|
||||||
%dir /usr/lib/%{name}/cron
|
%{_prefix}/lib/tmpfiles.d/mailman3.conf
|
||||||
/usr/lib/%{name}/icons
|
%config(noreplace) %attr(640,mailman,mailman) %{_sysconfdir}/mailman.cfg
|
||||||
%dir /usr/lib/%{name}/mail
|
%dir %{_sysconfdir}/mailman3.d
|
||||||
%attr(2755, root, %{name}) /usr/lib/%{name}/mail/mailman
|
%config(noreplace) %{_sysconfdir}/logrotate.d/mailman3
|
||||||
/usr/lib/%{name}/messages
|
%dir %attr(755,mailman,mailman) %{_localstatedir}/lib/mailman3
|
||||||
/usr/lib/%{name}/pythonlib
|
%dir %attr(2775,mailman,mail) %{_localstatedir}/lib/mailman3/data
|
||||||
/usr/lib/%{name}/scripts
|
%dir %attr(755,mailman,mailman) %{_localstatedir}/spool/mailman3
|
||||||
# rpmlint will complain here about config files being in /usr
|
%dir %attr(755,mailman,mailman) %{_localstatedir}/log/mailman3
|
||||||
# but these are both data files -parts of mailman's web UI-
|
%dir %attr(755,mailman,mailman) /run/mailman3
|
||||||
# and config files - user can change them to match the design
|
%dir %attr(755,mailman,mailman) /run/lock/mailman3
|
||||||
# and/or content of their web pages
|
%doc SELinux/*
|
||||||
%config(noreplace) /etc/%{name}/templates
|
%{_datadir}/selinux/*/mailman3.pp
|
||||||
/usr/lib/%{name}/tests
|
|
||||||
%dir /var/lib/%{name}
|
|
||||||
/var/lib/%{name}/data
|
|
||||||
/var/lib/%{name}/lists
|
|
||||||
/var/lib/%{name}/spam
|
|
||||||
%dir /var/lib/%{name}/archives
|
|
||||||
/var/lib/%{name}/archives/public
|
|
||||||
# fix for security issue #459530
|
|
||||||
%attr(2770,apache,%{name}) /var/lib/%{name}/archives/private
|
|
||||||
#cron dir minus one file which is listed later
|
|
||||||
/usr/lib/%{name}/cron/bumpdigests
|
|
||||||
/usr/lib/%{name}/cron/checkdbs
|
|
||||||
/usr/lib/%{name}/cron/cull_bad_shunt
|
|
||||||
/usr/lib/%{name}/cron/disabled
|
|
||||||
/usr/lib/%{name}/cron/gate_news
|
|
||||||
/usr/lib/%{name}/cron/mailpasswds
|
|
||||||
/usr/lib/%{name}/cron/nightly_gzip
|
|
||||||
/usr/lib/%{name}/cron/paths.py
|
|
||||||
/usr/lib/%{name}/cron/paths.pyc
|
|
||||||
/usr/lib/%{name}/cron/paths.pyo
|
|
||||||
/usr/lib/%{name}/cron/senddigests
|
|
||||||
#Mailman dir minus one file which is listed later
|
|
||||||
/usr/lib/%{name}/Mailman/Archiver
|
|
||||||
/usr/lib/%{name}/Mailman/Autoresponder.py
|
|
||||||
/usr/lib/%{name}/Mailman/Autoresponder.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/Autoresponder.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Bouncer.py
|
|
||||||
/usr/lib/%{name}/Mailman/Bouncer.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/Bouncer.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Bouncers
|
|
||||||
/usr/lib/%{name}/Mailman/Cgi
|
|
||||||
/usr/lib/%{name}/Mailman/Commands
|
|
||||||
/usr/lib/%{name}/Mailman/CSRFcheck.py
|
|
||||||
/usr/lib/%{name}/Mailman/CSRFcheck.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/CSRFcheck.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Defaults.py
|
|
||||||
/usr/lib/%{name}/Mailman/Defaults.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/Defaults.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Deliverer.py
|
|
||||||
/usr/lib/%{name}/Mailman/Deliverer.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/Deliverer.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Digester.py
|
|
||||||
/usr/lib/%{name}/Mailman/Digester.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/Digester.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Errors.py
|
|
||||||
/usr/lib/%{name}/Mailman/Errors.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/Errors.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/GatewayManager.py
|
|
||||||
/usr/lib/%{name}/Mailman/GatewayManager.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/GatewayManager.pyo
|
|
||||||
#%/usr/lib/%{name}/Mailman/Generator.py
|
|
||||||
#%/usr/lib/%{name}/Mailman/Generator.pyc
|
|
||||||
#%/usr/lib/%{name}/Mailman/Generator.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Gui
|
|
||||||
/usr/lib/%{name}/Mailman/Handlers
|
|
||||||
/usr/lib/%{name}/Mailman/htmlformat.py
|
|
||||||
/usr/lib/%{name}/Mailman/htmlformat.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/htmlformat.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/HTMLFormatter.py
|
|
||||||
/usr/lib/%{name}/Mailman/HTMLFormatter.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/HTMLFormatter.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/i18n.py
|
|
||||||
/usr/lib/%{name}/Mailman/i18n.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/i18n.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/__init__.py
|
|
||||||
/usr/lib/%{name}/Mailman/__init__.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/__init__.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/ListAdmin.py
|
|
||||||
/usr/lib/%{name}/Mailman/ListAdmin.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/ListAdmin.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/LockFile.py
|
|
||||||
/usr/lib/%{name}/Mailman/LockFile.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/LockFile.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Logging
|
|
||||||
/usr/lib/%{name}/Mailman/Mailbox.py
|
|
||||||
/usr/lib/%{name}/Mailman/Mailbox.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/Mailbox.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/MailList.py
|
|
||||||
/usr/lib/%{name}/Mailman/MailList.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/MailList.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/MemberAdaptor.py
|
|
||||||
/usr/lib/%{name}/Mailman/MemberAdaptor.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/MemberAdaptor.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Message.py
|
|
||||||
/usr/lib/%{name}/Mailman/Message.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/Message.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/mm_cfg.py.dist
|
|
||||||
/usr/lib/%{name}/Mailman/MTA
|
|
||||||
/usr/lib/%{name}/Mailman/OldStyleMemberships.py
|
|
||||||
/usr/lib/%{name}/Mailman/OldStyleMemberships.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/OldStyleMemberships.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Pending.py
|
|
||||||
/usr/lib/%{name}/Mailman/Pending.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/Pending.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Post.py
|
|
||||||
/usr/lib/%{name}/Mailman/Post.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/Post.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Queue
|
|
||||||
/usr/lib/%{name}/Mailman/SafeDict.py
|
|
||||||
/usr/lib/%{name}/Mailman/SafeDict.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/SafeDict.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/SecurityManager.py
|
|
||||||
/usr/lib/%{name}/Mailman/SecurityManager.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/SecurityManager.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Site.py
|
|
||||||
/usr/lib/%{name}/Mailman/Site.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/Site.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/TopicMgr.py
|
|
||||||
/usr/lib/%{name}/Mailman/TopicMgr.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/TopicMgr.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/UserDesc.py
|
|
||||||
/usr/lib/%{name}/Mailman/UserDesc.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/UserDesc.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Utils.py
|
|
||||||
/usr/lib/%{name}/Mailman/Utils.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/Utils.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/Version.py
|
|
||||||
/usr/lib/%{name}/Mailman/Version.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/Version.pyo
|
|
||||||
/usr/lib/%{name}/Mailman/versions.py
|
|
||||||
/usr/lib/%{name}/Mailman/versions.pyc
|
|
||||||
/usr/lib/%{name}/Mailman/versions.pyo
|
|
||||||
%{_unitdir}/mailman.service
|
|
||||||
%doc %{docdir}
|
|
||||||
%dir %attr(0755,root,root) /usr/share/httpd/icons
|
|
||||||
%attr(0644,root,root) /usr/share/httpd/icons/*
|
|
||||||
%attr(0644, root, %{name}) %config(noreplace) %verify(not md5 size mtime) /etc/%{name}/mm_cfg.py
|
|
||||||
%attr(0644, root, %{name}) %config(noreplace) %verify(not md5 size mtime) /usr/lib/%{name}/Mailman/mm_cfg.py
|
|
||||||
%verify(not md5 size mtime) /usr/lib/%{name}/Mailman/mm_cfg.py?
|
|
||||||
%config(noreplace) /etc/httpd/conf.d/%{name}.conf
|
|
||||||
%config(noreplace) /etc/logrotate.d/%{name}
|
|
||||||
/etc/smrsh/%{name}
|
|
||||||
%dir %attr(755,root,%{name}) /etc/%{name}
|
|
||||||
%attr(0644, root, %{name}) %config(noreplace) %verify(not md5 size mtime) /etc/%{name}/sitelist.cfg
|
|
||||||
%attr(775,root,%{name}) /var/log/%{name}
|
|
||||||
%{_prefix}/lib/tmpfiles.d/mailman.conf
|
|
||||||
%attr(2775,root,%{name}) /var/spool/%{name}
|
|
||||||
%attr(0644,root,root) %config(noreplace) %verify(not md5 size mtime) /etc/cron.d/mailman
|
|
||||||
%attr(0644,root,%{name}) %config(noreplace) /usr/lib/%{name}/cron/crontab.in
|
|
||||||
%attr(0755,root,root) /usr/lib/%{name}/bin/mailman-update-cfg
|
|
||||||
%dir %attr(775,root,%{name}) /var/run/%{name}
|
|
||||||
%dir %attr(775,root,%{name}) /var/lock/%{name}
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Fri Dec 18 2020 leiju <leiju4@huawei.com> - 3.3.2-1
|
||||||
|
- Update to 3.3.2
|
||||||
|
|
||||||
* Fri Feb 14 2020 lihao <lihao129@huawei.com> - 2.1.29-5
|
* Fri Feb 14 2020 lihao <lihao129@huawei.com> - 2.1.29-5
|
||||||
- Package init
|
- Package init
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
version_control: git
|
version_control: pypi
|
||||||
src_repo: https://gitlab.com/mailman/mailman.gi
|
src_repo: mailman
|
||||||
tag_prefix: ""
|
tag_prefix: "^"
|
||||||
seperator: "."
|
separator: "."
|
||||||
|
|||||||
8
mailman3-digests.service
Normal file
8
mailman3-digests.service
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=Sends Mailman digests
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=oneshot
|
||||||
|
ExecStart=/usr/bin/mailman3 digests --send
|
||||||
|
User=mailman
|
||||||
|
Group=mailman
|
||||||
10
mailman3-digests.timer
Normal file
10
mailman3-digests.timer
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
[Unit]
|
||||||
|
Description=Run mailman-digests.service every day
|
||||||
|
|
||||||
|
[Timer]
|
||||||
|
OnCalendar=*-*-* 04:00:00
|
||||||
|
RandomizedDelaySec=3600
|
||||||
|
Persistent=true
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=basic.target
|
||||||
2
mailman3-tmpfiles.conf
Normal file
2
mailman3-tmpfiles.conf
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
d /var/lock/mailman3 0755 mailman mailman
|
||||||
|
d /var/run/mailman3 0755 mailman mailman
|
||||||
11
mailman3.logrotate
Normal file
11
mailman3.logrotate
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
@LOGDIR@/*.log {
|
||||||
|
missingok
|
||||||
|
sharedscripts
|
||||||
|
su mailman mailman
|
||||||
|
postrotate
|
||||||
|
/bin/kill -HUP `cat /run/mailman3/master.pid 2>/dev/null` 2>/dev/null || true
|
||||||
|
# Don't run "mailman3 reopen" with SELinux on here in the logrotate
|
||||||
|
# context, it will be blocked
|
||||||
|
#@BINDIR@/mailman3 reopen >/dev/null 2>&1 || true
|
||||||
|
endscript
|
||||||
|
}
|
||||||
22
mailman3.service
Normal file
22
mailman3.service
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
# It's not recommended to modify this file in-place, because it will be
|
||||||
|
# overwritten during package upgrades. If you want to customize, the
|
||||||
|
# best way is to create a file "/etc/systemd/system/mailman.service",
|
||||||
|
# containing
|
||||||
|
# .include /usr/lib/systemd/system/mailman.service
|
||||||
|
# ...make your changes here...
|
||||||
|
|
||||||
|
[Unit]
|
||||||
|
Description=GNU Mailing List Manager
|
||||||
|
After=syslog.target network.target
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
Type=forking
|
||||||
|
PIDFile=/run/mailman3/master.pid
|
||||||
|
User=mailman
|
||||||
|
Group=mailman
|
||||||
|
ExecStart=/usr/bin/mailman3 start --force
|
||||||
|
ExecReload=/usr/bin/mailman3 restart
|
||||||
|
ExecStop=/usr/bin/mailman3 stop
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
68
mm_cfg.py
68
mm_cfg.py
@ -1,68 +0,0 @@
|
|||||||
# -*- python -*-
|
|
||||||
|
|
||||||
# Copyright (C) 1998,1999,2000,2001,2002 by the Free Software Foundation, Inc.
|
|
||||||
#
|
|
||||||
# This program is free software; you can redistribute it and/or
|
|
||||||
# modify it under the terms of the GNU General Public License
|
|
||||||
# as published by the Free Software Foundation; either version 2
|
|
||||||
# of the License, or (at your option) any later version.
|
|
||||||
#
|
|
||||||
# This program is distributed in the hope that it will be useful,
|
|
||||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
# GNU General Public License for more details.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU General Public License
|
|
||||||
# along with this program; if not, write to the Free Software
|
|
||||||
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|
||||||
|
|
||||||
"""This module contains your site-specific settings.
|
|
||||||
|
|
||||||
From a brand new distribution it should be copied to mm_cfg.py. If you
|
|
||||||
already have an mm_cfg.py, be careful to add in only the new settings you
|
|
||||||
want. Mailman's installation procedure will never overwrite your mm_cfg.py
|
|
||||||
file.
|
|
||||||
|
|
||||||
The complete set of distributed defaults, with documentation, are in the file
|
|
||||||
Defaults.py. In mm_cfg.py, override only those you want to change, after the
|
|
||||||
|
|
||||||
from Defaults import *
|
|
||||||
|
|
||||||
line (see below).
|
|
||||||
|
|
||||||
Note that these are just default settings; many can be overridden via the
|
|
||||||
administrator and user interfaces on a per-list or per-user basis.
|
|
||||||
|
|
||||||
"""
|
|
||||||
|
|
||||||
###############################################
|
|
||||||
# Here's where we get the distributed defaults.
|
|
||||||
|
|
||||||
from Defaults import *
|
|
||||||
import pwd, grp
|
|
||||||
|
|
||||||
#NOTE: when you use SELinux, you need to restart service to
|
|
||||||
# make your changes take effect.
|
|
||||||
|
|
||||||
##############################################################
|
|
||||||
# Here's where we override shipped defaults with settings #
|
|
||||||
# suitable for the RPM package. #
|
|
||||||
MAILMAN_UID = pwd.getpwnam('mailman')[2]
|
|
||||||
MAILMAN_GID = grp.getgrnam('mailman')[2]
|
|
||||||
|
|
||||||
# Set these values according to your needs.
|
|
||||||
DEFAULT_URL_PATTERN = "http://%s/mailman/"
|
|
||||||
PRIVATE_ARCHIVE_URL = "/private"
|
|
||||||
PUBLIC_ARCHIVE_URL = "http://example.com/archives/search/%(listname)s"
|
|
||||||
MAILMAN_SITE_LIST = "mailman"
|
|
||||||
DEFAULT_URL_HOST = "mail.example.com"
|
|
||||||
DEFAULT_EMAIL_HOST = "example.com"
|
|
||||||
add_virtualhost(DEFAULT_URL_HOST, DEFAULT_EMAIL_HOST)
|
|
||||||
|
|
||||||
|
|
||||||
##############################################################
|
|
||||||
# Put YOUR site-specific configuration below, in mm_cfg.py . #
|
|
||||||
# See Defaults.py for explanations of the values. #
|
|
||||||
|
|
||||||
# Note - if you're looking for something that is imported from mm_cfg, but you
|
|
||||||
# didn't find it above, it's probably in Defaults.py.
|
|
||||||
Loading…
x
Reference in New Issue
Block a user