From owner-doc-jp-work@jp.FreeBSD.org Thu Mar 28 17:42:01 2002
Received: (from daemon@localhost)
	by castle.jp.FreeBSD.org (8.11.6+3.4W/8.11.3) id g2S8g1G52538;
	Thu, 28 Mar 2002 17:42:01 +0900 (JST)
	(envelope-from owner-doc-jp-work@jp.FreeBSD.org)
Received: from eos.ocn.ne.jp (eos.ocn.ne.jp [210.190.142.171])
	by castle.jp.FreeBSD.org (8.11.6+3.4W/8.11.3) with ESMTP/inet id g2S8g0c52533
	for <doc-jp-work@jp.FreeBSD.org>; Thu, 28 Mar 2002 17:42:00 +0900 (JST)
	(envelope-from hrs@eos.ocn.ne.jp)
Received: from mail.hrslab.yi.org (p12087-adsao04hon-acca.tokyo.ocn.ne.jp [61.199.17.87])
	by eos.ocn.ne.jp (OCN) with ESMTP id RAA16636
	for <doc-jp-work@jp.FreeBSD.org>; Thu, 28 Mar 2002 17:41:59 +0900 (JST)
Received: from localhost (alph.hrslab.yi.org [192.168.0.10])
	by mail.hrslab.yi.org (8.9.3/3.7W/DomainMaster) with ESMTP id RAA72490
	for <doc-jp-work@jp.FreeBSD.org>; Thu, 28 Mar 2002 17:39:47 +0900 (JST)
	(envelope-from hrs@eos.ocn.ne.jp)
Date: Thu, 28 Mar 2002 17:30:32 +0900 (JST)
Message-Id: <20020328.173032.74740058.hrs@eos.ocn.ne.jp>
To: doc-jp-work@jp.FreeBSD.org
From: Hiroki Sato <hrs@eos.ocn.ne.jp>
In-Reply-To: <200203261936.g2QJabt50188@freefall.freebsd.org>
References: <200203261936.g2QJabt50188@freefall.freebsd.org>
X-Mailer: Mew version 2.1 on Emacs 20.7 / Mule 4.0 (HANANOEN)
Mime-Version: 1.0
Content-Type: Multipart/Mixed;
 boundary="--Next_Part(Thu_Mar_28_17:30:32_2002_920)--"
Content-Transfer-Encoding: 7bit
Reply-To: doc-jp-work@jp.FreeBSD.org
Precedence: list
X-Distribute: distribute version 2.1 (Alpha) patchlevel 24e+020328
X-Sequence: doc-jp-work 314
Subject: [doc-jp-work 314] Re: ANNOUNCE: FreeBSD Ports Security Advisory
 FreeBSD-SA-02:19.squid
Errors-To: owner-doc-jp-work@jp.FreeBSD.org
Sender: owner-doc-jp-work@jp.FreeBSD.org
X-Originator: hrs@eos.ocn.ne.jp

----Next_Part(Thu_Mar_28_17:30:32_2002_920)--
Content-Type: Text/Plain; charset=iso-2022-jp
Content-Transfer-Encoding: 7bit

$B:4F#!wEl5~M}2JBg3X$G$9!#(B

 02:19 $B$G$9!#(B

--
| $B:4F#(B $B9-@8!wEl5~M}2JBg3X(B <hrs@eos.ocn.ne.jp>
|                         <hrs@FreeBSD.org> (FreeBSD Project)

----Next_Part(Thu_Mar_28_17:30:32_2002_920)--
Content-Type: Text/Plain; charset=iso-2022-jp
Content-Disposition: inline; filename="02:19"
Content-Transfer-Encoding: 7bit


FreeBSD $B%;%-%e%j%F%#4+9p(B $BF|K\8lHG(B
=============================================================================
FreeBSD-SA-02:19 (2002-03-26)
 * squid heap buffer overflow in DNS handling
=============================================================================

 $B$3$N%a!<%k$O(B, announce-jp $B$KN.$l$?(B

  Subject: ANNOUNCE: FreeBSD Ports Security Advisory FreeBSD-SA-02:19.squid
  From: FreeBSD Security Advisories <security-advisories@FreeBSD.org>
  Date: Tue, 26 Mar 2002 11:36:37 -0800 (PST)
  Message-Id: <200203261936.g2QJabt50188@freefall.freebsd.org>
  X-Sequence: announce-jp 957

 $B$rF|K\8lLu$7$?$b$N$G$9!#(B

 $B86J8$O(B PGP $B=pL>$5$l$F$$$^$9$,!"$3$NF|K\8lLu$O(B PGP $B=pL>$5$l$F$$$^$;$s!#(B
 $B=$@5%Q%C%AEy$NFbMF$,2~$6$s$5$l$F$$$J$$$3$H$r3NG'$9$k$?$a$K(B PGP $B=pL>$N(B
 $B%A%'%C%/$r9T$J$&$K$O!"86J8$r;2>H$7$F$/$@$5$$!#(B

 $BF|K\8lLu$*$h$S!"%_%i!<%5%$%HMxMQ$N>\:Y$K$D$$$F$O!"J8Kv$N!V(BA. FreeBSD
 $B%;%-%e%j%F%#4+9p(B $BF|K\8lHG$K$D$$$F!W$r$4Mw$/$@$5$$!#(B


                                     [$BK]Lu<T(B: $B:4F#(B $B9-@8(B <hrs@jp.FreeBSD.org>]
--($B$3$3$+$i(B)
=============================================================================
FreeBSD-SA-02:19                                            Security Advisory
                                                                FreeBSD, Inc.

$B%H%T%C%/(B:	squid $B$N(B DNS $B=hM}$K$*$1$k%R!<%W$N%P%C%U%!%*!<%P%U%m!<LdBj(B
                (squid heap buffer overflow in DNS handling)

$BJ,N`(B:		ports
$B%b%8%e!<%k(B:	squid24
$B9pCNF|(B:		2002-03-26
$B%/%l%8%C%H(B:	zen-parse <zen-parse@gmx.net>
$B1F6AHO0O(B:	$B%P!<%8%g%s(B 2.4_9 $B$h$jA0$N(B squid port
$B=$@5F|(B:		2002-03-22 00:19:55 UTC
FreeBSD $B$K8GM-$+(B:	NO


I.   $BGX7J(B - Background

The Squid Internet Object Cache is a web proxy/cache.
Squid Internet Object Cache $B$O!"%&%'%V%W%m%-%7(B/$B%-%c%C%7%eMQ$N(B
$B%=%U%H%&%'%"$G$9(B.


II.  $BLdBj$N>\:Y(B - Problem Description

Incorrect handling of compressed DNS responses could result in a
heap buffer overflow.

squid $B$N05=L(B DNS $B1~Ez$N=hM}$K$O!"%R!<%W$N%P%C%U%!%*!<%P%U%m!<$r(B
$B0z$-5/$3$92DG=@-$N$"$k8m$j$,B8:_$7$^$9!#(B

The squid port is not installed by default, nor is it "part of
FreeBSD" as such: it is part of the FreeBSD ports collection, which
contains thousands of third- party applications in a ready-to-install
format. The ports collection shipped with FreeBSD 4.5 contains this
problem since it was discovered after the release.

squid $B$N(B port $B$O%G%U%)%k%H$G%$%s%9%H!<%k$5$l$k$b$N$G$O$J$/!"(B
$B!V(BFreeBSD $B%7%9%F%`$N0lIt!W$r9=@.$9$k$b$N$G$b$"$j$^$;$s!#(B
$B$=$l$i$O?t@i8D$K$*$h$V%5!<%I%Q!<%F%#@=%"%W%j%1!<%7%g%s$,$9$0$K(B
$B%$%s%9%H!<%k$G$-$k7A$G<}$a$i$l$F$$$k(B FreeBSD Ports Collection $B$N0lIt$G$9!#(B
$B$3$N%;%-%e%j%F%#>e$N<eE@$O(B FreeBSD 4.5 $B$N%j%j!<%98e$KH=L@$7$?$b$N$G!"(B
FreeBSD 4.5 $B$K<}O?$5$l$?(B Ports Collection $B$K$b!"$3$NLdBj$,4^$^$l$F$$$^$9(B.

FreeBSD makes no claim about the security of these third-party
applications, although an effort is underway to provide a security
audit of the most security-critical ports.

FreeBSD $B$G$O!"$3$N$h$&$J%5!<%I%Q!<%F%#@=%"%W%j%1!<%7%g%s$N%;%-%e%j%F%#(B
$BLdBj$KBP$7$F!"$$$+$J$kJ]>Z$b$7$F$$$^$;$s(B ($BLuCm(B: Ports Collection $B$K(B
$BF~$C$F$$$k$+$i$H$$$C$F(B FreeBSD $B$N3+H/<T$?$A$,$=$N%"%W%j%1!<%7%g%s$,(B
$B0BA4$G$"$k$HI>2A$7$?$o$1$G$O$"$j$^$;$s(B)$B!#$?$@$7!"%;%-%e%j%F%#LdBj$KBP$7$F(B
$BBg$-$J1F6A$r;}$D$h$&$J(B ports $B$KBP$9$k%;%-%e%j%F%#4F::$rDs6!$9$Y$/!"(B
$B8=:_EXNOCf$G$9!#(B


III. $B1F6AHO0O(B - Impact

A malicious DNS server (or an attacker spoofing a DNS server) could
respond to DNS requests from squid with a specially crafted answer
that would trigger the heap buffer overflow bug.  This could crash the
squid process.  This bug is not known to be exploitable.

$B0-0U$r;}$C$?(B DNS $B%5!<%P(B ($B$"$k$$$O(B DNS $B%5!<%P$rAu$C$?967b<T(B) $B$O!"(B
squid $B$+$i$N(B DNS $BMW5a$KBP$7$FFCJL$K:Y9)$5$l$?1~Ez$rJV$9$3$H$G!"(B
$B%R!<%W$N%P%C%U%!%*!<%P%U%m!<$r0z$-5/$3$9$3$H$,$G$-$k2DG=@-$,$"$j$^$9!#(B
$B$3$l$O(B squid $B%W%m%;%9$r%/%i%C%7%e$5$;$^$9!#$3$N%P%0$,0-MQ2DG=$+$I$&$+$O(B
$BITL@$G$9!#(B


IV.  $B2sHrJ}K!(B - Workaround

1) Deinstall the squid port/package if you have it installed.
1) squid $B$N(B port/package $B$,%$%s%9%H!<%k$5$l$F$$$k>l9g$O!"(B
   $B$=$l$r%7%9%F%`$+$i:o=|$7$^$9!#(B


V.   $B2r7h:v(B - Solution

$B<!$N$$$:$l$+$K=>$C$F$/$@$5$$!#(B

1) Upgrade your entire ports collection and rebuild the port.
1) Ports Collection $BA4BN$r%"%C%W%0%l!<%I$7(B squid $B$N(B port $B$r:F9=C[$9$k!#(B

2) Deinstall the old package and install a new package dated after the
correction date, obtained from the following directories:
2) $B8E$$(B ($BLuCm(B: squid $B$N(B) package $B$r%7%9%F%`$+$i:o=|$7!"(B
   $B=$@5F|0J9_$K:n@.$5$l$??7$7$$(B package $B$r0J2<$N>l=j$+$i(B
   $B<hF@$7$F%$%s%9%H!<%k$9$k!#(B

[i386]
ftp://ftp.FreeBSD.org/pub/FreeBSD/ports/i386/packages-4-stable/www/
ftp://ftp.FreeBSD.org/pub/FreeBSD/ports/i386/packages-5-current/www/

[alpha]
Packages are not automatically generated for the alpha architecture at
this time due to lack of build resources.
$B8=;~E@$G$O(B alpha $B%"!<%-%F%/%A%cMQ$N(B package $B$O<+F0@8@.$5$l$F$$$^$;$s!#(B
$B$3$l$O!"9=C[$N$?$a$N%^%7%s%j%=!<%9$,ITB-$7$F$$$k$?$a$G$9!#(B

NOTE: It may be several days before updated packages are available.
$BCm0U(B: $B99?7$5$l$?(B package $B$,Ds6!$5$l$k$^$G!"?tF|$+$+$k2DG=@-$,$"$j$^$9!#(B

3) Download a new port skeleton for the squid port from:
3) squid $B$N?7$7$$(B port $B%9%1%k%H%s$r0J2<$N>l=j$+$i%@%&%s%m!<%I$7!"(B
   $B$=$l$r;H$C$F(B port $B$r:F9=C[$9$k!#(B

http://www.freebsd.org/ports/

and use it to rebuild the port.

4) Use the portcheckout utility to automate option (3) above. The
portcheckout port is available in /usr/ports/devel/portcheckout or the
package can be obtained from:
4) $B>e5-(B (3) $B$NA`:n$r<+F0E*$K9T$J$&(B portcheckout $B%f!<%F%#%j%F%#$r;H$&!#(B
   portcheckout $B$N(B port $B$O(B /usr/ports/devel/portcheckout $B$K$"$j$^$9!#(B
   $B$^$?!"(Bportcheckout $B$N(B package $B$,0J2<$N>l=j$+$iF~<j2DG=$G$9!#(B

ftp://ftp.FreeBSD.org/pub/FreeBSD/ports/i386/packages-4-stable/Latest/portcheckout.tgz
ftp://ftp.FreeBSD.org/pub/FreeBSD/ports/i386/packages-5-current/Latest/portcheckout.tgz


VI.  $B=$@5$N>\:Y(B - Correction details

The following list contains the revision numbers of each file that was
corrected in the FreeBSD ports collection.
$B<!$NI=$O(B FreeBSD Ports Collection $B$K4^$^$l$k!"(B
$B:#2s=$@5$5$l$?%U%!%$%k$N(B $FreeBSD$ $B%j%S%8%g%sHV9f$G$9!#(B

Path                                                             Revision
$B%Q%9L>(B                                                       $B%j%S%8%g%sHV9f(B
- -------------------------------------------------------------------------
ports/www/squid24/Makefile                                           1.89
ports/www/squid24/distinfo                                           1.64
- -------------------------------------------------------------------------


VII. $B;29M;qNA(B - References

<URL:http://www.squid-cache.org/Advisories/SQUID-2002_2.txt>
<URL:http://www.squid-cache.org/cgi-bin/cvsweb.cgi/squid/lib/rfc1035.c#rev1.24>
<URL:http://www.squid-cache.org/cgi-bin/cvsweb.cgi/squid/lib/rfc1035.c#rev1.23>


A.   FreeBSD $B%;%-%e%j%F%#4+9p(B $BF|K\8lHG$K$D$$$F(B

$BF|K\8lLu$O(B FreeBSD $BF|K\8l%I%-%e%a%s%F!<%7%g%s%W%m%8%'%/%H(B (doc-jp) $B$,(B
$B;29M$N$?$a$KDs6!$9$k$b$N$G$9!#2a5n$NF|K\8lHG%;%-%e%j%F%#4+9p$O(B

 http://www.FreeBSD.org/ja/security/

$B$K$^$H$a$i$l$F$$$^$9!#(B

$B$?$@$7K]Lu<T$*$h$S(B doc-jp $B$O!"$=$NFbMF$K$D$$$F$$$+$J$kJ]>Z$b(B
$B$$$?$7$^$;$s$N$G$4Cm0U$/$@$5$$!#F|K\8lLu$K$D$$$F$N$40U8+!"$4MWK>!"(B
$B$*Ld$$9g$o$;Ey$O(B doc-jp@jp.FreeBSD.org $B$^$G$*4j$$$7$^$9!#(B

$B$3$N4+9p$NCf$G>R2p$5$l$F$$$k(B WWW $B%5%$%H(B http://www.FreeBSD.org/ $B$*$h$S(B
FTP $B%5%$%H(B ftp://ftp.FreeBSD.org/ $B$K$O(B, $BF|K\$N%_%i!<%5%$%H$,B8:_$7$^$9!#(B
$B%M%C%H%o!<%/$N:.;($r4KOB$9$k$?$a!"$^$:$O%_%i!<%5%$%H$NMxMQ$r(B
$B9MN8$9$k$h$&$*4j$$$7$^$9!#(B

$BF|K\$N%_%i!<%5%$%H$rMxMQ$9$k$K$O!"(B
http://www.FreeBSD.org/ $B$r(B http://www.jp.FreeBSD.org/www.freebsd.org/ $B$K!"(B
ftp://ftp.FreeBSD.org/ $B$r(B ftp://ftp.jp.FreeBSD.org/ $B$K!"(B
$B$=$l$>$lCV$-49$($F$/$@$5$$!#(B

$BB>$NCO0h$r4^$`%_%i!<%5%$%H$K4X$9$k>\:Y$O(B

 http://www.FreeBSD.org/handbook/mirror.html ($B1QJ8(B)
 http://www.FreeBSD.org/ja/handbook/mirror.html ($BF|K\8lLu(B)

$B$K$^$H$a$i$l$F$$$^$9!#(B

$hrs: announce-jp/FreeBSD-SA/02:19,v 1.3 2002/03/28 08:29:25 hrs Exp $

----Next_Part(Thu_Mar_28_17:30:32_2002_920)----
