/[smeserver]/rpms/e-smith-base/sme7/e-smith-base-4.18.0-remoteaccess.pmfm2self.patch
ViewVC logotype

Contents of /rpms/e-smith-base/sme7/e-smith-base-4.18.0-remoteaccess.pmfm2self.patch

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


Revision 1.2 - (show annotations) (download)
Wed Mar 26 17:01:38 2008 UTC (16 years, 2 months ago) by slords
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +0 -0 lines
FILE REMOVED
* Wed Mar 26 2008 Shad L. Lords <slords@mail.com> 4.18.1-2
- Fix gettext strings returned by password checks [SME: 4104]

1 diff -Nur -x '*.orig' -x '*.rej' e-smith-base-4.18.0/root/usr/lib/perl5/site_perl/esmith/FormMagick/Panel/remoteaccess.pm mezzanine_patched_e-smith-base-4.18.0/root/usr/lib/perl5/site_perl/esmith/FormMagick/Panel/remoteaccess.pm
2 --- e-smith-base-4.18.0/root/usr/lib/perl5/site_perl/esmith/FormMagick/Panel/remoteaccess.pm 2007-01-19 14:33:22.000000000 -0700
3 +++ mezzanine_patched_e-smith-base-4.18.0/root/usr/lib/perl5/site_perl/esmith/FormMagick/Panel/remoteaccess.pm 2007-04-14 05:14:39.000000000 -0600
4 @@ -19,9 +19,6 @@
5 # You should have received a copy of the GNU General Public License
6 # along with this program; if not, write to the Free Software
7 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
8 -#
9 -# Technical support for this program is available from Mitel Networks
10 -# Please visit our web site www.mitel.com/sme/ for details.
11 #----------------------------------------------------------------------
12
13 package esmith::FormMagick::Panel::remoteaccess;
14 @@ -109,7 +106,7 @@
15 =cut
16
17 sub get_prop {
18 - my ($fm, $item, $prop) = @_;
19 + my ($self, $item, $prop) = @_;
20 warn "You must specify a record key" unless $item;
21 warn "You must specify a property name" unless $prop;
22 my $record = $db->get($item) or warn "Couldn't get record for $item";
23 @@ -123,7 +120,7 @@
24 =cut
25
26 sub get_value {
27 - my $fm = shift;
28 + my $self = shift;
29 my $item = shift;
30 return ($db->get($item)->value());
31 }
32 @@ -252,17 +249,17 @@
33
34 sub show_telnet_section
35 {
36 - my $fm = shift;
37 - my $q = $fm->cgi;
38 + my $self = shift;
39 + my $q = $self->cgi;
40 my $mode = get_telnet_mode();
41
42 # Don't show telnet setting if it is off
43 return '' if $mode eq 'off';
44
45 my %options = (
46 - public => $fm->localise('PUBLIC'),
47 - private => $fm->localise('PRIVATE'),
48 - off => $fm->localise('NO_ACCESS'),
49 + public => $self->localise('PUBLIC'),
50 + private => $self->localise('PRIVATE'),
51 + off => $self->localise('NO_ACCESS'),
52 );
53
54 print $q->Tr(
55 @@ -272,10 +269,10 @@
56 $q->Tr(
57 $q->td({-colspan => 2},
58 $q->span({-class => "error-noborders"},
59 - $fm->localise('DESC_TELNET_ACCESS')))),
60 + $self->localise('DESC_TELNET_ACCESS')))),
61 $q->Tr(
62 $q->td({-class => "sme-noborders-label"},
63 - $fm->localise('LABEL_TELNET_ACCESS')),
64 + $self->localise('LABEL_TELNET_ACCESS')),
65 $q->td({-class => "sme-noborders-content"},
66 $q->popup_menu(-name => 'TelnetAccess',
67 -values => [ keys %options ],
68 @@ -291,21 +288,21 @@
69
70 sub show_ftp_section
71 {
72 - my $fm = shift;
73 - my $q = $fm->{cgi};
74 + my $self = shift;
75 + my $q = $self->{cgi};
76
77 # Don't show ftp setting unless the property exists
78 return '' unless $db->get('ftp');
79
80 my %options = (
81 - normal => $fm->localise('PUBLIC'),
82 - private => $fm->localise('PRIVATE'),
83 - off => $fm->localise('NO_ACCESS'),
84 + normal => $self->localise('PUBLIC'),
85 + private => $self->localise('PRIVATE'),
86 + off => $self->localise('NO_ACCESS'),
87 );
88
89 my %loginOptions = (
90 - private => $fm->localise('PASSWORD_LOGIN_PRIVATE'),
91 - public => $fm->localise('PASSWORD_LOGIN_PUBLIC'),
92 + private => $self->localise('PASSWORD_LOGIN_PRIVATE'),
93 + public => $self->localise('PASSWORD_LOGIN_PUBLIC'),
94 );
95
96 print $q->Tr(
97 @@ -315,10 +312,10 @@
98 $q->Tr(
99 $q->td({-colspan => 2},
100 $q->span({-class => "sme-noborders"},
101 - $fm->localise('DESC_FTP_ACCESS')))),
102 + $self->localise('DESC_FTP_ACCESS')))),
103 $q->Tr(
104 $q->td({-class => "sme-noborders-label"},
105 - $fm->localise('LABEL_FTP_ACCESS')),
106 + $self->localise('LABEL_FTP_ACCESS')),
107 $q->td({-class => "sme-noborders-content"},
108 $q->popup_menu(-name => 'FTPAccess',
109 -values => [ keys %options ],
110 @@ -327,10 +324,10 @@
111 $q->Tr(
112 $q->td({-colspan => 2},
113 $q->span({-class => "sme-noborders"},
114 - $fm->localise('DESC_FTP_LOGIN')))),
115 + $self->localise('DESC_FTP_LOGIN')))),
116 $q->Tr(
117 $q->td({-class => "sme-noborders-label"},
118 - $fm->localise('LABEL_FTP_LOGIN')),
119 + $self->localise('LABEL_FTP_LOGIN')),
120 $q->td({-class => "sme-noborders-content"},
121 $q->popup_menu(-name => 'FTPPasswordLogin',
122 -values => [ keys %loginOptions ],
123 @@ -595,15 +592,15 @@
124
125
126 sub change_settings {
127 - my ($fm) = @_;
128 + my ($self) = @_;
129
130 my %conf;
131
132 - my $q = $fm->{'cgi'};
133 + my $q = $self->{'cgi'};
134
135 # Don't process the form unless we clicked the Save button. The event is
136 # called even if we chose the Remove link or the Add link.
137 - return unless($q->param('Next') eq $fm->localise('SAVE'));
138 + return unless($q->param('Next') eq $self->localise('SAVE'));
139
140 my $access = ($q->param ('TelnetAccess') || 'off');
141 my $sshaccess = ($q->param ('sshAccess') || 'off');
142 @@ -690,14 +687,14 @@
143 # $rec->set_prop('Device', $serialConsole);
144 # }
145
146 - $fm->cgi->param(-name=>'wherenext', -value=>'First');
147 + $self->cgi->param(-name=>'wherenext', -value=>'First');
148
149 - unless ($fm->add_new_valid_from)
150 + unless ($self->add_new_valid_from)
151 {
152 return '';
153 }
154
155 - unless ($fm->remove_valid_from)
156 + unless ($self->remove_valid_from)
157 {
158 return '';
159 }
160 @@ -708,15 +705,15 @@
161 or die "Error occurred while resetting ipsec certificates.\n";
162 $q->param(-name=>'ipsecrwReset', -value=>'');
163 }
164 - $fm->set_ipsecrw_sessions;
165 + $self->set_ipsecrw_sessions;
166
167 unless ( system( "/sbin/e-smith/signal-event", "remoteaccess-update" ) == 0 )
168 {
169 - $fm->error('ERROR_UPDATING');
170 + $self->error('ERROR_UPDATING');
171 return undef;
172 }
173
174 - $fm->success('SUCCESS');
175 + $self->success('SUCCESS');
176 }
177
178 sub get_ipsecrw_sessions
179 @@ -732,8 +729,8 @@
180
181 sub show_ipsecrw_section
182 {
183 - my $fm = shift;
184 - my $q = $fm->cgi;
185 + my $self = shift;
186 + my $q = $self->cgi;
187
188 # Don't show ipsecrw setting unless the status property exists
189 return '' unless ($db->get('ipsec')
190 @@ -745,20 +742,20 @@
191 $q->table(
192 $q->Tr(
193 $q->td({-colspan => 2, -class => "sme-noborders"},
194 - $fm->localise('DESC_IPSECRW'))),
195 + $self->localise('DESC_IPSECRW'))),
196 $q->Tr(
197 $q->td({-class => "sme-noborders-label"},
198 - $fm->localise('LABEL_IPSECRW_SESS')),
199 + $self->localise('LABEL_IPSECRW_SESS')),
200 $q->td({-class => "sme-noborders-content"},
201 $q->textfield(-name => 'ipsecrwSessions',
202 -value => get_ipsecrw_sessions(),
203 -size => '3'))),
204 $q->Tr(
205 $q->td({-colspan => 2, -class => "sme-noborders"},
206 - $fm->localise('DESC_IPSECRW_RESET'))),
207 + $self->localise('DESC_IPSECRW_RESET'))),
208 $q->Tr(
209 $q->td({-class => "sme-noborders-label"},
210 - $fm->localise('LABEL_IPSECRW_RESET')),
211 + $self->localise('LABEL_IPSECRW_RESET')),
212 $q->td({-class => "sme-noborders-content"},
213 $q->checkbox(-name => 'ipsecrwReset', -label => ''))),
214 )
215 @@ -771,8 +768,8 @@
216
217 sub set_ipsecrw_sessions
218 {
219 - my $fm = shift;
220 - my $q = $fm->cgi;
221 + my $self = shift;
222 + my $q = $self->cgi;
223 my $sessions = $q->param('ipsecrwSessions');
224 if (defined $sessions)
225 {

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