Gentoo Archives: gentoo-security

From: Darren Davison <darren@×××××××××××××.org>
To: gentoo-security@l.g.o
Subject: Re: [gentoo-security] Advice about security solution
Date: Wed, 09 Nov 2005 11:47:45
Message-Id: 1131536552.24145.26.camel@garbo
In Reply to: Re: [gentoo-security] Advice about security solution by Harald Dumdey
On Wed, 2005-11-09 at 11:35 +0100, Harald Dumdey wrote:

> Is there a 'solution' for that? Or do i have to write a shellscript...
presumably a script dropped into /etc/cron.daily would do it. Along the lines of (nb: totally untested) ..? #!/bin/sh # mail address to send compressed logs to TO=your@×××××××××××.address # the hex ID of your GPG key KEY=0xaabbcc99 # which logs? *.0 will pick the most recently rotated set. You # can probably do better LOGS="/var/log/*.0" HOST=`cat /etc/conf.d/hostname` TODAY=`(date +"%y%m%d")` OUTFILE=/tmp/$HOST_$TODAY_logs.tbz2 # tar/compress tar cjf $OUTFILE # encrypt gpg -r $KEY --encrypt-files $OUTFILE # send. Not sure how you do this without mutt.. echo "Logs.." | mutt -s "$HOST logs for $TODAY" -a $OUTFILE.gpg $TO # clean up rm -f $OUTFILE $OUTFILE.gpg -- Darren Davison Public Key: 0xDD356B0D

Attachments

File name MIME type
signature.asc application/pgp-signature

Replies

Subject Author
Re: [gentoo-security] Advice about security solution Darren Davison <darren@×××××××××××××.org>
Re: [gentoo-security] Advice about security solution "Brian G. Peterson" <brian@×××××××××.com>