1 |
jpp |
1.1 |
diff -Nur --no-dereference smeserver-yum-2.6.2.old/createlinks smeserver-yum-2.6.2/createlinks |
2 |
|
|
--- smeserver-yum-2.6.2.old/createlinks 2022-07-11 11:10:46.000000000 -0400 |
3 |
|
|
+++ smeserver-yum-2.6.2/createlinks 2023-08-16 17:21:15.041000000 -0400 |
4 |
|
|
@@ -15,8 +15,6 @@ |
5 |
|
|
for ( qw(install remove update) ) |
6 |
|
|
{ |
7 |
|
|
event_link("yum-action", "yum-$_", "20"); |
8 |
|
|
- event_link("initialize-default-databases", "yum-$_", "50"); |
9 |
|
|
- event_link("navigation-conf", "yum-$_", "80"); |
10 |
|
|
} |
11 |
|
|
|
12 |
|
|
safe_symlink("restart", "root/etc/e-smith/events/yum-modify/services2adjust/yum"); |
13 |
|
|
diff -Nur --no-dereference smeserver-yum-2.6.2.old/root/usr/share/perl5/vendor_perl/esmith/FormMagick/Panel/yum.pm smeserver-yum-2.6.2/root/usr/share/perl5/vendor_perl/esmith/FormMagick/Panel/yum.pm |
14 |
|
|
--- smeserver-yum-2.6.2.old/root/usr/share/perl5/vendor_perl/esmith/FormMagick/Panel/yum.pm 2023-08-16 12:04:03.784000000 -0400 |
15 |
|
|
+++ smeserver-yum-2.6.2/root/usr/share/perl5/vendor_perl/esmith/FormMagick/Panel/yum.pm 2023-08-16 17:26:55.967000000 -0400 |
16 |
|
|
@@ -80,7 +80,7 @@ |
17 |
|
|
|
18 |
|
|
sub new { |
19 |
|
|
shift; |
20 |
|
|
- my $self = esmith::FormMagick->new(); |
21 |
|
|
+ my $self = esmith::FormMagick->new(csrfdelay=>600); |
22 |
|
|
$self->{calling_package} = (caller)[0]; |
23 |
|
|
bless $self; |
24 |
|
|
return $self; |
25 |
|
|
@@ -157,8 +157,8 @@ |
26 |
|
|
|
27 |
|
|
for ($dbs{$yumdb}->get_all_by_prop(type => $type)) |
28 |
|
|
{ |
29 |
|
|
- $options{$_->key} = $_->key . " " . $_->prop("Version") . " - " . |
30 |
|
|
- $_->prop("Repo"); |
31 |
|
|
+ $options{$_->key} = $_->key . " " . ($_->prop("Version")||"") . " - " . |
32 |
|
|
+ ($_->prop("Repo")||""); |
33 |
|
|
} |
34 |
|
|
|
35 |
|
|
return \%options; |
36 |
|
|
@@ -286,9 +286,10 @@ |
37 |
|
|
my ($fm) = @_; |
38 |
|
|
my @yum_status; |
39 |
|
|
|
40 |
|
|
- open(YUM_STATUS, "</var/run/yum.status"); |
41 |
|
|
- @yum_status = <YUM_STATUS>; |
42 |
|
|
- close(YUM_STATUS); |
43 |
|
|
+ if (open(YUM_STATUS, "</var/run/yum.status")) { |
44 |
|
|
+ @yum_status = <YUM_STATUS>; |
45 |
|
|
+ close(YUM_STATUS); |
46 |
|
|
+ } |
47 |
|
|
|
48 |
|
|
my @yum_log = $fm->format_yum_log(); |
49 |
|
|
|
50 |
|
|
@@ -400,6 +401,11 @@ |
51 |
|
|
} else { |
52 |
|
|
# effective reconfigure and reboot required |
53 |
|
|
$fm->success('HEADER_POSTUPGRADE_REQUIRED', 'YUM_PAGE_POSTUPGRADE'); |
54 |
|
|
+ if ($fm->{csrf}) { |
55 |
|
|
+ # we want to restart CSRF token timer from now |
56 |
|
|
+ $fm->{cgi}->param(-name => 'csrf_timestamp', -value => time); |
57 |
|
|
+ $fm->commit_session; |
58 |
|
|
+ } |
59 |
|
|
$fm->{cgi}->param(-name => "page", -value => 0); |
60 |
|
|
$fm->{cgi}->param(-name => "page_stack", -value => ''); |
61 |
|
|
$fm->{cgi}->param(-name => "Next", -value => 'Next'); |