/[smeserver]/rpms/e-smith-email/sme9/e-smith-email-5.4.0-webmail-only-local-network.patch
ViewVC logotype

Contents of /rpms/e-smith-email/sme9/e-smith-email-5.4.0-webmail-only-local-network.patch

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


Revision 1.1 - (show annotations) (download)
Tue Dec 10 01:40:43 2013 UTC (10 years, 10 months ago) by burnat
Branch: MAIN
CVS Tags: e-smith-email-5_4_0-6_el6_sme, e-smith-email-5_4_0-5_el6_sme
* Tue Dec 10 2013 Chris Burnat <devlist@burnat.com> 5.4.0-5.sme
- Allow webmail-only-local-network by Stephane de Labrusse [SME: 7351]

1 diff -Nur e-smith-email-5.4.0-old/root/etc/e-smith/locale/en-us/etc/e-smith/web/functions/emailsettings e-smith-email-5.4.0/root/etc/e-smith/locale/en-us/etc/e-smith/web/functions/emailsettings
2 --- e-smith-email-5.4.0-old/root/etc/e-smith/locale/en-us/etc/e-smith/web/functions/emailsettings 2013-11-26 19:01:14.391228451 +0100
3 +++ e-smith-email-5.4.0/root/etc/e-smith/locale/en-us/etc/e-smith/web/functions/emailsettings 2013-12-09 21:22:30.060593986 +0100
4 @@ -174,6 +174,10 @@
5 <trans>Allow HTTPS (secure)</trans>
6 </entry>
7 <entry>
8 + <base>ONLY_LOCAL_NETWORK_SSL</base>
9 + <trans>Allow HTTPS (secure) from local networks</trans>
10 + </entry>
11 + <entry>
12 <base>INSECURE_POP3</base>
13 <trans>Allow both POP3 and POP3S</trans>
14 </entry>
15 diff -Nur e-smith-email-5.4.0-old/root/usr/share/perl5/vendor_perl/esmith/FormMagick/Panel/emailsettings.pm e-smith-email-5.4.0/root/usr/share/perl5/vendor_perl/esmith/FormMagick/Panel/emailsettings.pm
16 --- e-smith-email-5.4.0-old/root/usr/share/perl5/vendor_perl/esmith/FormMagick/Panel/emailsettings.pm 2013-11-26 19:01:14.406227386 +0100
17 +++ e-smith-email-5.4.0/root/usr/share/perl5/vendor_perl/esmith/FormMagick/Panel/emailsettings.pm 2013-12-09 21:46:09.807126763 +0100
18 @@ -345,9 +345,20 @@
19 $db->set_prop('mysqld',"status", "enabled" );
20 $db->set_prop('imp',"status", 'enabled' );
21 $db->set_prop('horde',"status", 'enabled' );
22 + $db->set_prop('horde',"httpsaccess", 'public' );
23 $db->set_prop('imp',"access", "SSL" );
24 $db->set_prop('horde',"access", "SSL" );
25 }
26 +
27 + elsif ( $webmail eq "localnetworkSSL" ) {
28 + $db->set_prop('php',"status", "enabled" );
29 + $db->set_prop('mysqld',"status", "enabled" );
30 + $db->set_prop('imp',"status", 'enabled' );
31 + $db->set_prop('horde',"status", 'enabled' );
32 + $db->set_prop('horde',"httpsaccess", 'private' );
33 + $db->set_prop('imp',"access", "SSL" );
34 + $db->set_prop('horde',"access", "SSL" );
35 + }
36 else {
37 $db->set_prop('imp',"status", 'disabled' );
38 $db->set_prop('horde',"status", 'disabled' );
39 @@ -544,7 +555,7 @@
40
41 =head2 get_current_webmail_status
42
43 -returns "disabled", "enabled" or "enabledSSL", depending on whether
44 +returns "disabled", "localnetworkSSL" or "enabledSSL", depending on whether
45 the various components of the webmail subsystem are currently enabled
46
47 =cut
48 @@ -565,14 +576,25 @@
49
50 my $PHPStatus = $db->get_prop('php', 'status') || 'disabled';
51
52 + my $Networkaccess = $db->get_prop('horde','httpsaccess') || 'disabled';
53 +
54 # all four components must be on for webmail to be working
55 if ( ( $IMPStatus eq "enabled" )
56 && ( $HordeStatus eq "enabled" )
57 && ( $MysqlStatus eq "enabled" )
58 - && ( $PHPStatus eq "enabled" ) )
59 + && ( $PHPStatus eq "enabled" )
60 + && ( $Networkaccess eq "public" ) )
61 {
62 $WebmailStatus = ( $SSLonly eq "SSL" ) ? "enabledSSL" : "enabled";
63 }
64 + elsif ( ( $IMPStatus eq "enabled" )
65 + && ( $HordeStatus eq "enabled" )
66 + && ( $MysqlStatus eq "enabled" )
67 + && ( $PHPStatus eq "enabled" )
68 + && ( $Networkaccess eq "private" ) )
69 + {
70 + $WebmailStatus = ( $SSLonly eq "SSL" ) ? "localnetworkSSL" : "enabled";
71 + }
72
73 my $options = get_webmail_options();
74
75 @@ -737,7 +759,8 @@
76 sub get_webmail_options
77 {
78 my %options = ( disabled => 'DISABLED',
79 - enabledSSL => 'ENABLED_SECURE_ONLY' );
80 + enabledSSL => 'ENABLED_SECURE_ONLY',
81 + localnetworkSSL => 'ONLY_LOCAL_NETWORK_SSL' );
82
83 my $access = $db->get_prop('imp', 'access') || 'SSL';
84

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