/[smeserver]/rpms/e-smith-email/sme8/e-smith-email-5.2.0-blocksmtp.patch
ViewVC logotype

Annotation of /rpms/e-smith-email/sme8/e-smith-email-5.2.0-blocksmtp.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (hide annotations) (download)
Mon Mar 29 14:45:08 2010 UTC (14 years, 7 months ago) by filippocarletti
Branch: MAIN
CVS Tags: e-smith-email-5_2_0-24_el5_sme, e-smith-email-5_2_0-14_el5_sme, e-smith-email-5_2_0-16_el5_sme, e-smith-email-5_2_0-10_el5_sme, e-smith-email-5_2_0-13_el5_sme, e-smith-email-5_2_0-9_el5_sme, e-smith-email-5_2_0-15_el5_sme, e-smith-email-5_2_0-6_el5_sme, e-smith-email-5_2_0-5_el5_sme, e-smith-email-5_2_0-12_el5_sme, e-smith-email-5_2_0-22_el5_sme, e-smith-email-5_2_0-7_el5_sme, e-smith-email-5_2_0-18_el5_sme, e-smith-email-5_2_0-19_el5_sme, e-smith-email-5_2_0-17_el5_sme, e-smith-email-5_2_0-20_el5_sme, e-smith-email-5_2_0-21_el5_sme, e-smith-email-5_2_0-27_el5_sme, e-smith-email-5_2_0-26_el5_sme, e-smith-email-5_2_0-8_el5_sme, e-smith-email-5_2_0-11_el5_sme, e-smith-email-5_2_0-28_el5_sme, e-smith-email--, e-smith-email-5_2_0-23_el5_sme, e-smith-email-5_2_0-25_el5_sme, HEAD
* Thu Mar 25 2010 Federico Simoncelli <federico.simoncelli@gmail.com> 5.2.0-2.sme
- Block by default the SMTP transparent proxy [SME: 5574]

1 filippocarletti 1.1 diff -uNr e-smith-email-5.2.0/root/etc/e-smith/db/configuration/defaults/smtpd/Proxy e-smith-email-5.2.0-blocksmtp/root/etc/e-smith/db/configuration/defaults/smtpd/Proxy
2     --- e-smith-email-5.2.0/root/etc/e-smith/db/configuration/defaults/smtpd/Proxy 2005-05-05 17:17:20.000000000 +0200
3     +++ e-smith-email-5.2.0-blocksmtp/root/etc/e-smith/db/configuration/defaults/smtpd/Proxy 2010-03-25 15:16:40.692970423 +0100
4     @@ -1 +1 @@
5     -enabled
6     +blocked
7     diff -uNr e-smith-email-5.2.0/root/etc/e-smith/templates/etc/rc.d/init.d/masq/40AllowGSMTP e-smith-email-5.2.0-blocksmtp/root/etc/e-smith/templates/etc/rc.d/init.d/masq/40AllowGSMTP
8     --- e-smith-email-5.2.0/root/etc/e-smith/templates/etc/rc.d/init.d/masq/40AllowGSMTP 1970-01-01 01:00:00.000000000 +0100
9     +++ e-smith-email-5.2.0-blocksmtp/root/etc/e-smith/templates/etc/rc.d/init.d/masq/40AllowGSMTP 2010-03-25 11:01:49.459002064 +0100
10     @@ -0,0 +1,7 @@
11     +{
12     + $OUT .= "\n # Check outbound SMTP\n";
13     +
14     + $OUT .= " /sbin/iptables --new-chain SMTPProxy\n";
15     + $OUT .= " /sbin/iptables --append FORWARD \\\n";
16     + $OUT .= "\t-p tcp --dport 25 -j SMTPProxy\n";
17     +}
18     diff -uNr e-smith-email-5.2.0/root/etc/e-smith/templates/etc/rc.d/init.d/masq/90adjustSMTPProxy e-smith-email-5.2.0-blocksmtp/root/etc/e-smith/templates/etc/rc.d/init.d/masq/90adjustSMTPProxy
19     --- e-smith-email-5.2.0/root/etc/e-smith/templates/etc/rc.d/init.d/masq/90adjustSMTPProxy 2005-05-05 17:17:21.000000000 +0200
20     +++ e-smith-email-5.2.0-blocksmtp/root/etc/e-smith/templates/etc/rc.d/init.d/masq/90adjustSMTPProxy 2010-03-25 15:15:19.100617190 +0100
21     @@ -12,11 +12,21 @@
22     $rule++;
23     }
24    
25     + $OUT .= " /sbin/iptables --flush SMTPProxy\n";
26     +
27     if (${smtpd}{'Proxy'} eq 'enabled')
28     {
29     $OUT .= " /sbin/iptables --table nat --replace SMTPProxy $rule\\\n";
30     $OUT .= "\t-p TCP -j DNAT --to $LocalIP:25\n";
31     }
32     + elsif (${smtpd}{'Proxy'} eq 'blocked')
33     + {
34     + # Replace it with nothing, but keep the rule entry as a placeholder
35     + # for each re-enabling.
36     + $OUT .= " /sbin/iptables --table nat --replace SMTPProxy $rule\n";
37     + $OUT .= " /sbin/iptables --append SMTPProxy\\\n";
38     + $OUT .= "\t-p tcp --dport 25 -i \$INTERNALIF -j denylog\n";
39     + }
40     else
41     {
42     # Replace it with nothing, but keep the rule entry as a placeholder

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed