Problems with Nagios config

Rasmus Plewe rplewe at hpce.nec.com
Thu Feb 27 20:53:03 CET 2003


On Thu, Feb 27, 2003 at 12:15:16PM -0600, Carroll, Jim P [Contractor] wrote:
> Rasmus Plewe wrote:
> > 
> > The fastest, perhapt not most elegant solution:
> > echo "your at email.address" > ~nagios/.forward
> > That would forward all mail for nagios at hostname to your IP address. 
> > 
> > If you really want your email address in the From: header, there are
> > lots of possibilities and even more possible problems. You could use a
> > different (non-interactive) MUA (I'd take mutt, myself) in
> > misccommands.cfg instead of /usr/bin/mail, which allows you some
> > "forging" of the sender, but you could then still run into problems
> > with the MTA on your machine. 
> 
> Interesting approach.  I can see possibly injecting a crafted Reply-To:
> header; I'm not sure that sendmail would permit a forged From: address,
> unless running as root.

This depends solely on your sendmail configuration. It's *nix: lots of
possibilities to shoot yourself. 
Actually, I do appear as name at private.mailaddress when mailing from my
home machine, even though that machine has a totally different host
name. Not too difficult with mutt and sendmail. And trivial with
things like Netscape, which bypass the local MTA alltogether. 

> Having said that, another option might be procmail on the Nagios host.  Have
> it replace 'nagios at kgibbons.com' with 'kevin at kgibbons.com' on the From:
> line.

Procmail for outgoing mail? That's a new one for my, but why not...

And my .forward solution won't work anyway if for some reason the
Nagios server is not reachable by mail from the outside (firewall). 
Of course, another idea would be to set the MX record in the DNS for
that machine... 

> It's been a while for me, but if he were to replace sendmail with postfix, I
> think doing this kind of crafting would be quite simple.

Never worked with postfix. Worked with sendmail on a somewhat deeper
level once (m4, not deeper). It's... interesting, yes. 


Rasmus


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list