Fixed net-snmp-cert tool, now it does not depend on net-snmp-devel

Resolves: #1134475
This commit is contained in:
Jan Safranek 2014-09-01 12:02:03 +02:00
parent 68adcc5ea3
commit 17435b3e52
2 changed files with 33 additions and 0 deletions

View File

@ -0,0 +1,30 @@
1134475 - dependency in perl package
Use hardcoded path to configuration directories instead of net-snmp-config.
net-snmp-config is in net-snmp-devel package and we do not want net-snmp-perl
depending on -devel.
diff -up net-snmp-5.7.2/local/net-snmp-cert.cert-path net-snmp-5.7.2/local/net-snmp-cert
--- net-snmp-5.7.2/local/net-snmp-cert.cert-path 2012-10-10 00:28:58.000000000 +0200
+++ net-snmp-5.7.2/local/net-snmp-cert 2014-09-01 12:05:10.582427036 +0200
@@ -819,8 +819,7 @@ sub set_default {
sub cfg_path {
my $path;
- $path = `$NetSNMP::Cert::CFGTOOL --snmpconfpath`;
- chomp $path;
+ $path = "/etc/snmp:/usr/share/snmp:/usr/lib64/snmp:/home/jsafrane/.snmp:/var/lib/net-snmp";
return (wantarray ? split(':', $path) : $path);
}
@@ -1414,8 +1413,8 @@ sub checkReqs {
die("$NetSNMP::Cert::OPENSSL (v$ossl_ver): must be $ossl_min_ver or later")
if ($ossl_ver cmp $ossl_min_ver) < 0;
- die("$NetSNMP::Cert::CFGTOOL not found: please install")
- if system("$NetSNMP::Cert::CFGTOOL > /dev/null 2>&1");
+# die("$NetSNMP::Cert::CFGTOOL not found: please install")
+# if system("$NetSNMP::Cert::CFGTOOL > /dev/null 2>&1");
}
sub initOpts {

View File

@ -44,6 +44,7 @@ Patch11: net-snmp-5.7-agentx-crash.patch
Patch12: net-snmp-5.5-agentx-disconnect-crash.patch Patch12: net-snmp-5.5-agentx-disconnect-crash.patch
Patch13: net-snmp-5.7.2-icmp-mib.patch Patch13: net-snmp-5.7.2-icmp-mib.patch
Patch14: net-snmp-CVE-2014-3565.patch Patch14: net-snmp-CVE-2014-3565.patch
Patch15: net-snmp-5.7.2-cert-path.patch
Requires(post): chkconfig Requires(post): chkconfig
Requires(preun): chkconfig Requires(preun): chkconfig
@ -212,6 +213,7 @@ cp %{SOURCE12} .
%patch12 -p1 -b .agentx-disconnect-crash %patch12 -p1 -b .agentx-disconnect-crash
%patch13 -p1 -b .icmp-mib %patch13 -p1 -b .icmp-mib
%patch14 -p1 -b .CVE-2014-3565 %patch14 -p1 -b .CVE-2014-3565
%patch15 -p1 -b .cert-path
%ifarch sparc64 s390 s390x %ifarch sparc64 s390 s390x
# disable failing test - see https://bugzilla.redhat.com/show_bug.cgi?id=680697 # disable failing test - see https://bugzilla.redhat.com/show_bug.cgi?id=680697
@ -515,6 +517,7 @@ rm -rf ${RPM_BUILD_ROOT}
%changelog %changelog
* Mon Sep 1 2014 Jan Safranek <jsafrane@redhat.com> - 1:5.7.2-15 * Mon Sep 1 2014 Jan Safranek <jsafrane@redhat.com> - 1:5.7.2-15
- Fixed CVE-2014-3565 - Fixed CVE-2014-3565
- Fixed net-snmp-cert tool, now it does not depend on net-snmp-devel (#1134475)
* Tue Mar 4 2014 Jan Safranek <jsafrane@redhat.com> - 1:5.7.2-14 * Tue Mar 4 2014 Jan Safranek <jsafrane@redhat.com> - 1:5.7.2-14
- Fixed buffer overflow in ICMP-MIB (#1071753) - Fixed buffer overflow in ICMP-MIB (#1071753)