Date: Thu, 23 Apr 2009 17:47:15 +0000 (UTC) From: Robert Watson <rwatson@FreeBSD.org> To: cvs-src-old@freebsd.org Subject: cvs commit: src/sys/net if_mib.c Message-ID: <200904231747.n3NHlXlA044149@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
rwatson 2009-04-23 17:47:15 UTC
FreeBSD src repository
Modified files: (Branch: RELENG_7)
sys/net if_mib.c
Log:
SVN rev 191434 on 2009-04-23 17:47:15Z by rwatson
In sysctl_ifdata(), query the ifnet pointer using the index only
once, rather than querying it, validating it, and then re-querying
it without validating it. This may avoid a NULL pointer
dereference and resulting kernel page fault if an interface is
being deleted while bsnmp or other tools are querying data on the
interface.
The full fix, to properly refcount the interface for the duration
of the sysctl, is in 8.x, but is considered too high-risk for
7.2, so instead will appear in 7.3 (if all goes well).
Reproted by: mdtancsa
Approved by: re (kensmith)
Revision Changes Path
1.18.2.1 +1 -3 src/sys/net/if_mib.c
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200904231747.n3NHlXlA044149>
