/[smecontribs]/rpms/smeserver-fail2ban/contribs10/smeserver-fail2ban-0.1.18-bz12008-backup.patch
ViewVC logotype

Diff of /rpms/smeserver-fail2ban/contribs10/smeserver-fail2ban-0.1.18-bz12008-backup.patch

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

Revision 1.1 by jpp, Sat Jul 30 03:04:39 2022 UTC Revision 1.3 by jpp, Sat Jul 30 03:28:47 2022 UTC
# Line 6  diff -Nur --no-dereference smeserver-fai Line 6  diff -Nur --no-dereference smeserver-fai
6   foreach my $file (qw(   foreach my $file (qw(
7                   /etc/systemd/system-preset/49-koozali.preset                   /etc/systemd/system-preset/49-koozali.preset
8  +               /etc/backup-data.d/smeserver-fail2ban.include  +               /etc/backup-data.d/smeserver-fail2ban.include
9  +               /etc/e-smith/templates/etc/dar/DailyBackup.dcf  +               /etc/dar/DailyBackup.dcf
10   ))   ))
11   {   {
12       templates2events( $file, $event );       templates2events( $file, $event );
13  diff -Nur --no-dereference smeserver-fail2ban-0.1.18.old/root/etc/e-smith/templates/etc/backup-data.d/smeserver-fail2ban.include/template-begin smeserver-fail2ban-0.1.18/root/etc/e-smith/templates/etc/backup-data.d/smeserver-fail2ban.include/template-begin  diff -Nur --no-dereference smeserver-fail2ban-0.1.18.old/root/etc/e-smith/templates/etc/backup-data.d/smeserver-fail2ban.include/template-begin smeserver-fail2ban-0.1.18/root/etc/e-smith/templates/etc/backup-data.d/smeserver-fail2ban.include/template-begin
14  --- smeserver-fail2ban-0.1.18.old/root/etc/e-smith/templates/etc/backup-data.d/smeserver-fail2ban.include/template-begin        1969-12-31 19:00:00.000000000 -0500  --- smeserver-fail2ban-0.1.18.old/root/etc/e-smith/templates/etc/backup-data.d/smeserver-fail2ban.include/template-begin        1969-12-31 19:00:00.000000000 -0500
15  +++ smeserver-fail2ban-0.1.18/root/etc/e-smith/templates/etc/backup-data.d/smeserver-fail2ban.include/template-begin    2022-07-29 22:59:07.986000000 -0400  +++ smeserver-fail2ban-0.1.18/root/etc/e-smith/templates/etc/backup-data.d/smeserver-fail2ban.include/template-begin    2022-07-29 22:59:07.986000000 -0400
 @@ -0,0 +1,20 @@  
 +#Only non rpm owned files are backupe there  
 +{  
 +use RPM2;  
 +my $rpm_db = RPM2->open_rpm_db();  
 +  
 +my @dirs = qw(/etc/fail2ban/action.d  
 +/etc/fail2ban/fail2ban.d  
 +/etc/fail2ban/filter.d  
 +/etc/fail2ban/jail.d  
 +);  
 +  
 +foreach  my $some_dir  (@dirs)  {  
 +  opendir(my $dh, $some_dir) || die "Can't open $some_dir: $!";  
 +  while ( (my $file = readdir $dh) ) {  
 +    next if $file =~ /^\.{1,2}$/;  
 +    $OUT .= "$some_dir/$file\n" unless $rpm_db->find_by_file("$some_dir/$file");  
 +  }  
 +  closedir $dh;  
 +}  
 +}  
 diff -Nur --no-dereference smeserver-fail2ban-0.1.18.old/root/etc/e-smith/templates/etc/dar/DailyBackup.dcf/41go-into-smeserver-fail2ban smeserver-fail2ban-0.1.18/root/etc/e-smith/templates/etc/dar/DailyBackup.dcf/41go-into-smeserver-fail2ban  
 --- smeserver-fail2ban-0.1.18.old/root/etc/e-smith/templates/etc/dar/DailyBackup.dcf/41go-into-smeserver-fail2ban       1969-12-31 19:00:00.000000000 -0500  
 +++ smeserver-fail2ban-0.1.18/root/etc/e-smith/templates/etc/dar/DailyBackup.dcf/41go-into-smeserver-fail2ban   2022-07-29 23:02:58.224000000 -0400  
16  @@ -0,0 +1,22 @@  @@ -0,0 +1,22 @@
17  +#Only non rpm owned files are backupe there  +#Only non rpm owned files are backupe there
18  +{  +{
19  +use RPM2;  +use RPM2;
20  +my $rpm_db = RPM2->open_rpm_db();  +my $rpm_db = RPM2->open_rpm_db();
21  +  +
22  +my @dirs = qw(/etc/fail2ban/action.d  +my @dirs = qw(
23    +/etc/fail2ban
24    +/etc/fail2ban/action.d
25  +/etc/fail2ban/fail2ban.d  +/etc/fail2ban/fail2ban.d
26  +/etc/fail2ban/filter.d  +/etc/fail2ban/filter.d
27  +/etc/fail2ban/jail.d  +/etc/fail2ban/jail.d
# Line 53  diff -Nur --no-dereference smeserver-fai Line 31  diff -Nur --no-dereference smeserver-fai
31  +  opendir(my $dh, $some_dir) || die "Can't open $some_dir: $!";  +  opendir(my $dh, $some_dir) || die "Can't open $some_dir: $!";
32  +  while ( (my $file = readdir $dh) ) {  +  while ( (my $file = readdir $dh) ) {
33  +    next if $file =~ /^\.{1,2}$/;  +    next if $file =~ /^\.{1,2}$/;
34  +    my $backdir = $some_dir =~ s/^\///;  +    $OUT .= "$some_dir/$file\n" unless $rpm_db->find_by_file("$some_dir/$file");
 +    $OUT .= "--go-into $backdir/$file\n" unless $rpm_db->find_by_file("$some_dir/$file");  
35  +  }  +  }
36  +  closedir $dh;  +  closedir $dh;
37  +}  +}
38  +}  +}
 +  


Legend:
Removed lines/characters  
Changed lines/characters
  Added lines/characters

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