Date: Tue, 15 Jun 2004 18:04:51 GMT From: Klaus Steden <klaus@compt.com> To: freebsd-gnats-submit@FreeBSD.org Subject: bin/67982: integer overflow in statfs structure Message-ID: <200406151804.i5FI4paE015759@www.freebsd.org> Resent-Message-ID: <200406151810.i5FIAG8G018483@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 67982 >Category: bin >Synopsis: integer overflow in statfs structure >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Tue Jun 15 18:10:16 GMT 2004 >Closed-Date: >Last-Modified: >Originator: Klaus Steden >Release: 4.9-STABLE >Organization: >Environment: FreeBSD kubrick.compt.com 4.9-STABLE FreeBSD 4.9-STABLE #0: Tue Nov 25 18:16:15 EST 2003 klaus@kubrick.compt.com:/usr/obj/usr/src/sys/Manhattan i386 >Description: One of my NFS-mounted volumes is quite large (about 1.1 TB, or 2291609600 blocks to be precise); df incorrectly reports the size as a negative value: @kubrick:~[285]$ df -h /helios Filesystem Size Used Avail Capacity Mounted on atlas:/helios -955.3G 840G 252G -88% /helios I compiled df from source with debugging symbols and ran it through gdb, and it appears that the f_blocks member in the statfs structure used by statfs() is simply not big enough to hold the value returned. >How-To-Repeat: Can be repeated by using df, and presumably also by any program that uses a statfs structure on a large filesystem. >Fix: Increase the size of the f_blocks parameter (and possibly others) to something larger. >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200406151804.i5FI4paE015759>
