From owner-freebsd-questions@FreeBSD.ORG Sun Jan 20 04:15:41 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2471F16A417 for ; Sun, 20 Jan 2008 04:15:41 +0000 (UTC) (envelope-from m.seaman@infracaninophile.co.uk) Received: from smtp.infracaninophile.co.uk (gate6.infracaninophile.co.uk [IPv6:2001:8b0:151:1::1]) by mx1.freebsd.org (Postfix) with ESMTP id 5D90413C43E for ; Sun, 20 Jan 2008 04:15:40 +0000 (UTC) (envelope-from m.seaman@infracaninophile.co.uk) Received: from happy-idiot-talk.infracaninophile.co.uk (localhost [IPv6:::1]) by smtp.infracaninophile.co.uk (8.14.2/8.14.2) with ESMTP id m0K4FUVQ072213; Sun, 20 Jan 2008 04:15:31 GMT (envelope-from m.seaman@infracaninophile.co.uk) X-DKIM: Sendmail DKIM Filter v2.4.2 smtp.infracaninophile.co.uk m0K4FUVQ072213 Authentication-Results: smtp.infracaninophile.co.uk; dkim=hardfail (SSP) header.i=unknown Message-ID: <4792CAE2.7070805@infracaninophile.co.uk> Date: Sun, 20 Jan 2008 04:15:30 +0000 From: Matthew Seaman Organization: Infracaninophile User-Agent: Thunderbird 2.0.0.9 (X11/20071122) MIME-Version: 1.0 To: Chris Whitehouse References: <47924869.2000909@onetel.com> <877ii5fsh0.fsf@chateau.d.lf> <47928A73.2040904@onetel.com> In-Reply-To: <47928A73.2040904@onetel.com> X-Enigmail-Version: 0.95.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-3.0 (smtp.infracaninophile.co.uk [IPv6:::1]); Sun, 20 Jan 2008 04:15:31 +0000 (GMT) X-Virus-Scanned: ClamAV 0.92/5499/Sun Jan 20 01:31:52 2008 on happy-idiot-talk.infracaninophile.co.uk X-Virus-Status: Clean X-Spam-Status: No, score=-2.9 required=5.0 tests=AWL,BAYES_00, NORMAL_HTTP_TO_IP,NO_RELAYS autolearn=ham version=3.2.4 X-Spam-Checker-Version: SpamAssassin 3.2.4 (2008-01-01) on happy-idiot-talk.infracaninophile.co.uk Cc: freebsd-questions@freebsd.org Subject: Re: localhost in sudoers X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Jan 2008 04:15:41 -0000 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 Chris Whitehouse wrote: > I'm not sure what you mean. This computer is on a local network behind a > nat box and doesn't have a dns entry. > > %host 192.168.1.71 > 71.1.168.192.in-addr.arpa domain name pointer eco.config. > %host localhost > localhost has address 127.0.0.1 > > I think my question really is why doesn't sudoers recognise localhost or > 127.0.0.1? Confusion between the IPv6ish ::1 rather than the IPv4ish 127.0.0.1 perhaps? You can just put the hostname of your machine in the sudoers file and sudo will query the IP addresses of its interfaces at runtime - -- or simply don't use the host based limiting stuff at all: that syntax is predicated on having the same sudoers file distributed over a number of machines, which is great for a large site with dozens of servers, but for a home user it's possibly easier to maintain an individual sudoers file on each machine you have. Cheers, Matthew - -- Dr Matthew J Seaman MA, D.Phil. 7 Priory Courtyard Flat 3 PGP: http://www.infracaninophile.co.uk/pgpkey Ramsgate Kent, CT11 9PW -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.4 (FreeBSD) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHksri8Mjk52CukIwRCPfHAJ9m98pQb76ID8leqKRhyHKrzmJnFwCfaVXA n1hIg4OKpiursIKyu12ICE8= =jGzw -----END PGP SIGNATURE-----