Date: Sun, 24 Oct 2004 21:27:46 +0200 From: Max Laier <max@love2party.net> To: freebsd-net@freebsd.org Cc: Gilbert Cao <hika@bsdmon.com> Subject: Re: Kernel panic with pf Message-ID: <200410242127.53782.max@love2party.net> In-Reply-To: <20041024191406.GA1022@bsdmon.com> References: <20041024144754.GA1670@bsdmon.com> <200410241848.35446.max@love2party.net> <20041024191406.GA1022@bsdmon.com>
next in thread | previous in thread | raw e-mail | index | archive | help
[-- Attachment #1 --] On Sunday 24 October 2004 21:14, Gilbert Cao wrote: > On Sun, Oct 24, 2004 at 06:48:28PM +0200, Max Laier wrote: > > Hmmm ... that's bad. Can you please test the attached patch. It is a wild > > guess as I am currently not able to test. Please tell me if it helps. > > > > -- > > /"\ Best regards, | mlaier@freebsd.org > > \ / Max Laier | ICQ #67774661 > > X http://pf4freebsd.love2party.net/ | mlaier@EFnet > > / \ ASCII Ribbon Campaign | Against HTML Mail and News > > > > Index: pf.c > > =================================================================== > > RCS file: /usr/store/mlaier/fcvs/src/sys/contrib/pf/net/pf.c,v > > retrieving revision 1.18.2.2 > > diff -u -r1.18.2.2 pf.c > > --- pf.c 3 Oct 2004 17:04:39 -0000 1.18.2.2 > > +++ pf.c 24 Oct 2004 16:45:33 -0000 > > @@ -2506,6 +2506,11 @@ > > } > > #ifdef __FreeBSD__ > > INP_LOCK(inp); > > + if ((inp->inp_socket == NULL) || (inp->inp_socket->so_cred == NULL)) { > > + INP_UNLOCK(inp); > > + INP_INFO_RUNLOCK(pi); > > + return (0); > > + } > > *uid = inp->inp_socket->so_cred->cr_uid; > > *gid = inp->inp_socket->so_cred->cr_groups[0]; > > INP_UNLOCK(inp); > > Thanks. > That works, no panic. Thanks. Going to commit it. > Should I also test with debug.mpsafenet=0, or is it useless ? You should not use user/group rules in a debug.mpsafenet=1 environment. It will cause hard lockups and the like. The fix for these lockups is non- trivial and will take some more time. -- /"\ Best regards, | mlaier@freebsd.org \ / Max Laier | ICQ #67774661 X http://pf4freebsd.love2party.net/ | mlaier@EFnet / \ ASCII Ribbon Campaign | Against HTML Mail and News [-- Attachment #2 --] -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.6 (FreeBSD) iD8DBQBBfAI5XyyEoT62BG0RAhRfAJ0WQ8tz4TByMP+KPYfU2eoRasnbQwCfYeE1 4l3LT9IlIUWztHdEH2bXW5s= =9U7p -----END PGP SIGNATURE-----
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200410242127.53782.max>
