From owner-freebsd-questions@FreeBSD.ORG Thu Sep 18 07:49:01 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 F0BB9106567F for ; Thu, 18 Sep 2008 07:49:00 +0000 (UTC) (envelope-from rock_on_the_web@comcen.com.au) Received: from angel.comcen.com.au (angel.comcen.com.au [203.23.236.69]) by mx1.freebsd.org (Postfix) with ESMTP id A0E538FC19 for ; Thu, 18 Sep 2008 07:49:00 +0000 (UTC) (envelope-from rock_on_the_web@comcen.com.au) Received: from [192.168.0.185] (202-172-126-254.cpe.qld-1.comcen.com.au [202.172.126.254] (may be forged)) by angel.comcen.com.au (8.13.4/8.12.9) with ESMTP id m8I7mvIO091301 for ; Thu, 18 Sep 2008 17:48:58 +1000 (EST) From: Da Rock To: freebsd-questions@freebsd.org In-Reply-To: <48D20333.6090100@infracaninophile.co.uk> References: <1221698808.29382.23.camel@laptop1> <48D20333.6090100@infracaninophile.co.uk> Content-Type: text/plain Date: Thu, 18 Sep 2008 17:48:52 +1000 Message-Id: <1221724132.29382.29.camel@laptop1> Mime-Version: 1.0 X-Mailer: Evolution 2.12.3 (2.12.3-5.fc8) Content-Transfer-Encoding: 7bit Subject: Re: NTP authentication using kerberos 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: Thu, 18 Sep 2008 07:49:01 -0000 On Thu, 2008-09-18 at 08:28 +0100, Matthew Seaman wrote: > Da Rock wrote: > > This may be a stupid question, and/or a chicken and egg conundrum: > > > > Is it possible to use kerberos in authentication with an ntp server? > > > > Here is my reasoning for this (and please correct any wrong assumptions > > I have here): In the handbook regarding kerberos (and nearly every other > > reliable source) kerberos is all or nothing- every service needs to be > > included or it is not as secure as it should be. On the other hand, > > there are problems with using kerberos if the time is not synchronised, > > so use ntp. > > > > And so far I have only found simple key authentication similar to dhcp > > and dns to authenticate ntp with. But if kerberos provides keys then > > this could be simpler, yes? > > > > Once I have worked through this, I'd like to multicast ntp, but I think > > I've got that sewn up already, unless anybody has some advice on this? > > I'll probably be using the 239 subnet rather than 224 if that is not an > > issue. > > > > One more thing- if ntp uses the same sort of authentication as dhcp and > > dns, is there a way to extend this kerberos setup (if it is possible > > with ntp) to dhcp and dns on my local network? Or am I just getting too > > ambitious with everything here? :) > > NTP doesn't support Kerberos style authentication. It has it's own > cryptographically secured authentication mechanisms. See ntp-keygen(8) > However, doing the full-blown crypto security thing is generally over the > top for securing simple clients. It's good for NTP servers, especially > if you have your own heirarchy of Stratum 1 and perhaps Stratum 2 servers > and accurate timing really is critical for you. Remember you need at least > three independent time sources -- preferably four to give you some > resilience -- in order to be able to detect if the clock has gone wonky on > any one of your servers. > > For supplying a time signal by multicast or broadcast, you have to enable > key based authentication on all the servers and clients. The basic method > just uses what is effectively an 8 character random string as a password. > This is usually sufficient if all your client machines are on protected back end networks and taking a time signal from NTP servers entirely in > your control. You need to protect the ntp-keys file from exposure -- I > like to create a root-only directory to hold it: > > mkdir /etc/ntp > mv ntp.keys /etc/ntp/ > chown -R root:wheel /etc/ntp > chmod -R go-rwx /etc/ntp > > For dhcp and DNS security -- there are all sorts of mechanisms for > authenticating and securing transactions between such servers. In the > case of DNS, I suggest you read up on 'Tsig' (Transaction Signatures) > and DNSSEC -- this is a good resource: > > http://www.dnssec.net/why-deploy-dnssec > > Cheers, > > Matthew > Well thats good to know. I'm already using those methods on the dns and dhcp server, seems isc have their own methods in security so I'll just have to stick with those for ntp too. For reference, how does this affect the whole kerberos setup if these services are not in the kerberos system? Does it introduce a security flaw? Any experts out there that can clarify this point? Or should I just run these particular services outside the kerberos system (ie on a separate machine not kerberos secured)?