Public bug reported:

In script tests_kernel there is a test for core file status  5820. The
problem is that in lines 267 and 268 the output is an A else B type of
statement. The problem code and a proposed fixed are attached below:

267,268c267,268
<           FIND1=`cat /etc/security/limits.conf | awk '{ if ($1=="*" && 
$2=="soft" && $3=="core" && $4=="0") { print "soft core disabled" } else { 
print "soft core enabled" } }'`
<           FIND2=`cat /etc/security/limits.conf | awk '{ if ($1=="*" && 
$2=="hard" && $3=="core" && $4=="0") { print "hard core disabled" } else { 
print "hard core enabled" } }'`
---
>           FIND1=`cat /etc/security/limits.conf | awk '{ if ($1=="*" && 
> $2=="soft" && $3=="core" && $4=="0") { print "soft core disabled" } }'`
>           FIND2=`cat /etc/security/limits.conf | awk '{ if ($1=="*" && 
> $2=="hard" && $3=="core" && $4=="0") { print "hard core disabled" } }'`

Basically.. With the else {...} portion of the statement that causes
something to print out each time instead of just for the one line that
matches. The causes the output of the script to be incorrect and the
result printed in the analysis to be wrong.

ProblemType: Bug
DistroRelease: Ubuntu 13.04
Package: lynis 1.3.0-1 [modified: usr/share/lynis/include/tests_authentication 
usr/share/lynis/include/tests_banners usr/share/lynis/include/tests_kernel 
usr/share/lynis/include/tests_storage]
ProcVersionSignature: Ubuntu 3.8.0-17.27-generic 3.8.6
Uname: Linux 3.8.0-17-generic x86_64
NonfreeKernelModules: nvidia
ApportVersion: 2.9.2-0ubuntu8
Architecture: amd64
Date: Sat Apr 13 17:04:13 2013
InstallationDate: Installed on 2011-09-04 (587 days ago)
InstallationMedia: Kubuntu 11.10 "Oneiric Ocelot" - Beta amd64+mac (20110901)
MarkForUpload: True
PackageArchitecture: all
ProcEnviron:
 LANGUAGE=en_US
 TERM=xterm
 PATH=(custom, no user)
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: lynis
UpgradeStatus: Upgraded to raring on 2013-03-23 (21 days ago)

** Affects: lynis (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: amd64 apport-bug raring

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1168775

Title:
  lynis does not process security/limits.conf correctly

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/lynis/+bug/1168775/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to