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

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

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


Revision 1.1 - (hide annotations) (download)
Tue Jul 3 04:19:02 2012 UTC (12 years, 4 months ago) by wellsi
Branch: MAIN
CVS Tags: e-smith-email-5_2_0-24_el5_sme, e-smith-email-5_2_0-19_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-22_el5_sme, e-smith-email-5_2_0-27_el5_sme, e-smith-email-5_2_0-23_el5_sme, e-smith-email-5_2_0-25_el5_sme, e-smith-email-5_2_0-26_el5_sme, e-smith-email-5_2_0-28_el5_sme, e-smith-email-5_2_0-18_el5_sme, HEAD
Allow blacklist of SMTP AUTH methods, replaces previous patch [SME: 7017]

1 wellsi 1.1 diff -ruN e-smith-email-5.2.0.old/root/etc/e-smith/db/configuration/migrate/20smtp-auth-proxy-Blacklist e-smith-email-5.2.0/root/etc/e-smith/db/configuration/migrate/20smtp-auth-proxy-Blacklist
2     --- e-smith-email-5.2.0.old/root/etc/e-smith/db/configuration/migrate/20smtp-auth-proxy-Blacklist 1970-01-01 01:00:00.000000000 +0100
3     +++ e-smith-email-5.2.0/root/etc/e-smith/db/configuration/migrate/20smtp-auth-proxy-Blacklist 2012-07-03 04:52:35.000000000 +0100
4     @@ -0,0 +1,8 @@
5     +{
6     + my $MD5Patch = $DB->get_prop_and_delete('smtp-auth-proxy','MD5Patch') or return;
7     +
8     + if ($MD5Patch eq 'enabled')
9     + {
10     + $DB->set_prop('smtp-auth-proxy','Blacklist', 'CRAM-MD5 DIGEST-MD5');
11     + }
12     +}
13     diff -ruN e-smith-email-5.2.0.old/root/usr/local/sbin/smtp-auth-proxy.pl e-smith-email-5.2.0/root/usr/local/sbin/smtp-auth-proxy.pl
14     --- e-smith-email-5.2.0.old/root/usr/local/sbin/smtp-auth-proxy.pl 2012-07-03 04:49:06.000000000 +0100
15     +++ e-smith-email-5.2.0/root/usr/local/sbin/smtp-auth-proxy.pl 2012-07-03 04:49:33.000000000 +0100
16     @@ -23,6 +23,7 @@
17     my $smtp_proxy_rec = $config->get('smtp-auth-proxy');
18    
19     $prop->{SMTPSmartHost} = $config->get_value('SMTPSmartHost');
20     + $prop->{Blacklist} = $smtp_proxy_rec->prop('Blacklist') || " ";
21     $prop->{Userid} = $smtp_proxy_rec->prop('Userid');
22     $prop->{Passwd} = $smtp_proxy_rec->prop('Passwd');
23     $prop->{Debug} = $smtp_proxy_rec->prop('Debug');
24     @@ -92,7 +93,10 @@
25    
26     if ($smtp->supports("AUTH"))
27     {
28     - unless ($smtp->auth($name, $pass))
29     + foreach (split (/ /, $self->get_property('Blacklist')))
30     + {${*$smtp}{'net_smtp_esmtp'}->{"AUTH"} =~ s/$_//;}
31     +
32     + unless ($smtp->auth($name, $pass))
33     {
34     print "451 Could not auth to mail server\n";
35     warn "SMTP authentication with ISP server failed\n";

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