Bug 1295888 - logwatch --service sshd --detail 8 does not print Kerberos summary
Summary: logwatch --service sshd --detail 8 does not print Kerberos summary
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: logwatch
Version: 7.2
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Jan Synacek
QA Contact: Martin Frodl
URL:
Whiteboard:
Depends On:
Blocks: 1289485 1313485
TreeView+ depends on / blocked
 
Reported: 2016-01-05 17:21 UTC by Martin Frodl
Modified: 2016-11-04 03:30 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of: 1295886
Environment:
Last Closed: 2016-11-04 03:30:46 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:2312 0 normal SHIPPED_LIVE logwatch bug fix update 2016-11-03 13:41:34 UTC

Description Martin Frodl 2016-01-05 17:21:09 UTC
+++ This bug was initially created as a clone of Bug #1295886 +++

Description of problem:

When called with --service sshd --detail 8, logwatch does not print out the summary of successful Kerberos authentications. This summary is printed with detail level 9, 10, but also 7. Thus the detail level of 8 may be less verbose than 7, which is clearly undesired.

The root cause of this behaviour seems to be in using the 'greater than' operator where a 'greater than or equal' should be (in /usr/share/logwatch/scripts/services/sshd):

--- sshd.orig	2016-01-05 12:09:26.153006890 -0500
+++ sshd	2016-01-05 12:12:09.610000477 -0500
@@ -576,7 +576,7 @@
    }
 }
 
-if ( ($Detail == 7 && keys %KrbRealm > 1) || ($Detail > 8 && keys %KrbRealm) ){
+if ( ($Detail == 7 && keys %KrbRealm > 1) || ($Detail >= 8 && keys %KrbRealm) ){
    print "\nSucessfull Kerberos Authentication from ",(scalar keys %KrbRealm)," realm:\n";
    foreach my $realm (keys %KrbRealm) {
       if($Detail > 9){

Version-Release number of selected component (if applicable):
logwatch-7.4.0-28.20130522svn140.el7.noarch

Comment 7 errata-xmlrpc 2016-11-04 03:30:46 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2016-2312.html


Note You need to log in before you can comment on or make changes to this bug.