Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 195690 - app-forensics/aide - installing cron scripts should be optional for aide
Summary: app-forensics/aide - installing cron scripts should be optional for aide
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: MATSUU Takuto (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-10-13 10:54 UTC by Benjamin Judas
Modified: 2008-01-03 19:52 UTC (History)
5 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Benjamin Judas 2007-10-13 10:54:29 UTC
--- EHNANCEMENT SUGGESTION (SO NO "EMERGE --INFO" INCLUDED/NEEDED) ---

So I was wondering why I got cron mails telling me that my aide-database doesn't exist why still getting the regular mails from aide -C's output as it should be. 

The annoying thing was, that these irregular cron-mails were bounced messages from localhost.de (and not localhost) and I still couldn't get what was wrong until I found the cron-script installed by Aide. 

This script uses /bin/mail for dispatching the messages and somehow /bin/mail expands "localhost" to "localhost.de" while using postfix directly does it right.

Anyways, my suggestion would be to make the installation of the cron-script optional, maybe via a useflag.

Reproducible: Always

Steps to Reproduce:
n/a

Actual Results:  
n/a

Expected Results:  
n/a

n/a
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2007-10-13 12:51:06 UTC
A use flag for installing one plaintext file plain sucks, we just recently got rid of USE=udev which was doing the same pointless thing. 

Why don't you configure your local mail correctly, use INSTALL_MASK or delete the cronscript if you don't want it?
Comment 2 Benjamin Judas 2007-10-13 15:13:59 UTC
(In reply to comment #1)
> Why don't you configure your local mail correctly
It is configured correctly. Unfortunately mailx seems to have the idea that mail-addresses in the form of user@host are incorrect and appends some tld to the host-part. I haven't found the origin for this expanding behaviour yet (I even straced it). As I wrote: Postfix, ping and everything else I could use resolve "localhost" correctly to 127.0.0.1 -- only mailx fails.

>, use INSTALL_MASK
Never heard of this one, I will have a look at it.

> or delete the cronscript if you don't want it?
because portage/etc-update would put it there, again leading me to the same problem once aide gets upgraded.

Comment 3 Jakub Moc (RETIRED) gentoo-dev 2007-10-13 16:02:56 UTC
(In reply to comment #2)
> (In reply to comment #1)
> It is configured correctly. Unfortunately mailx seems to have the idea that
> mail-addresses in the form of user@host are incorrect and appends some tld to
> the host-part.

File a bug about mailx. Meanwhile user@host. (the trailing dot is important) should work-around this broken behaviour.
Comment 4 Benjamin Judas 2007-10-13 17:00:53 UTC
INSTALL_MASK solved this problem. I am blocking the script now.

> File a bug about mailx. Meanwhile user@host. (the trailing dot is important)
> should work-around this broken behaviour.
Why should I configure something (i.e. the Aide-Cronjob) I do not want to use at all? ;) 

I don't care about mailx since I do not use it. Instead, aide should probably utilize a sane and more forgiving MUA instead of mailx. The well known sendmail-symlink-wrapper magic could help, although I have to admit that I do not know how the various MTAs handle it.
Comment 5 Heath Caldwell (RETIRED) gentoo-dev 2007-12-20 20:53:06 UTC
The ebuild shouldn't be installing a script for cron to execute at all.  It is fine to provide an example script and put it somewhere with the documentation or something where someone can copy it into place if they want, but it is troubling to have a daily cron job just show up when you install aide.  It is also troubling to have to install a run-time dependency (which pulls in it's own dependencies) just for a script that really shouldn't be installed by default.

I vote for installing the script into /usr/share/doc/aide-0.13.1/example or something, maybe put in an elog saying that it is there, and remove virtual/mailx from RDEPEND.
Comment 6 Paul B. Henson 2007-12-22 03:38:43 UTC
I would agree that installation of a default script is not really appropriate in this case. Filesystem integrity checking is complicated enough that a one-size-fits-all script is probably not going to do the job, particularly at large deployments. It is rather nonintuitive to install this utility and suddenly discover processes running out of cron and extraneous mail showing up,  particularly if you were using an earlier version and already had your own infrastructure in place.

I think providing an example script would be a much better approach.

Thanks...
Comment 7 MATSUU Takuto (RETIRED) gentoo-dev 2007-12-23 06:41:16 UTC
Removed /etc/cron.daily/aide in 0.13.1-r1
Comment 8 Heath Caldwell (RETIRED) gentoo-dev 2008-01-03 19:52:56 UTC
It looks like you forgot to remove virtual/mailx from RDEPEND.