Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 22 Feb 2002 00:12:46 -0600 (CST)
From:      Ryan Thompson <ryan@sasknow.com>
To:        Stephen Hoover <shooverfbn@442spot.com>
Cc:        FreeBSD Questions <freebsd-questions@FreeBSD.ORG>
Subject:   Re: File Versions
Message-ID:  <20020221235116.O29930-100000@catalyst.sasknow.net>
In-Reply-To: <LKEGLDFEGPHGICLNAALGEEBMCAAA.shooverfbn@442spot.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Stephen Hoover wrote to FreeBSD Questions:

> How do you determine what version of a file you have in FreeBSD?
>
> For instance, if a file was patched do to a security fix, how can I
> look at that file and tell that it is the most current version?

The obviously effective thing to do would be to just view it...
more(1), even ee(8) et al. will do the trick. You'll find the version
in the $FreeBSD$ tag near the top of the file, after the license.

If you want to be keen about it, use ident(1). See below.


> Just use the binary pw for example.

Very likely what you're talking about is the Jan 4th pw(8) security
advisory, which actually refers to the source file "pwupd.c", which is
part of the pw binary build in /usr/src/usr.sbin/pw/. I would do this:

ryan $ ident /usr/src/usr.sbin/pw/pwupd.c
/usr/src/usr.sbin/pw/pwupd.c:
     $FreeBSD: src/usr.sbin/pw/pwupd.c,v 1.12.2.4 2001/12/21 15:21:32 nectar Exp $

So, the version is immediately after the RCS filename, and is 1.12.2.4
in this case. I can also tell it was updated on December 21st, which
was the correction date mentioned in the advisory. So, my pw sources
have been updated to the fixed versions.

Don't forget to rebuild the affected parts after updating the source.

See the advisory itself for the hand-held approach to patching. :-)

Good luck,
- Ryan

-- 
  Ryan Thompson <ryan@sasknow.com>
  Network Administrator, Accounts

  SaskNow Technologies - http://www.sasknow.com
  #106-380 3120 8th St E - Saskatoon, SK - S7H 0W2

        Tel: 306-664-3600   Fax: 306-664-1161   Saskatoon
  Toll-Free: 877-727-5669     (877-SASKNOW)     North America





To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020221235116.O29930-100000>