看板FB_security
標 題Re: Request for review: Sandboxing dhclient using Capsicum.
發信站NCTU CS FreeBSD Server (Wed Jun 12 05:31:59 2013)
轉信站ptt!csnews.cs.nctu!news.cs.nctu!.cs.nctucs.nctu!!freebsdfreebsd.org!ow
--PNTmBPCT7hxwcZjr
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
On Mon, Jun 10, 2013 at 06:07:17PM -0500, Brooks Davis wrote:
> On Sun, Jun 09, 2013 at 12:33:46AM +0200, Pawel Jakub Dawidek wrote:
> > I'd appreciate any review, especially security audit of the proposed
> > changes. The new and most critical function is probably send_packet_pri=
v().
>=20
> I've looked over the diff and not found any significant issues, but have
> a few comments in order of most to least important.
>=20
> In change 229477 using a cached hostname may change behavior if the host
> is renamed as a result of dhclient operation. The new behavior might be
> more correct, at least it would be if we reliably restored the host name
> on termination. I think the change is fine, but we should be keep an
> eye out for problem reports.
Yes, I'm aware of that possibility, I just don't think this is a big deal.
The hostname could be changed right after sending discover/request and
it will take a long while before the new one is send.
> In change 229476 I noticed there is a constant 0x1fff that you've moved
> around. It was already there, but it seems like an unnecessary magic
> number.
I agree, but I was trying to avoid changes not strictly related to
sandboxing. It was very hard to resist, belive me. For example I started
removing 'ifi' global variable, which I really don't like, but decided
to leave it for now (later I only changed variable name in disassoc()
that shadowed this global variable).
> In the send_packet_* function declarations in dhcpd.h, you have included
> variable names which is inconsistent with the surrounding definitions.
Fixed.
Thanks for the review!
--=20
Pawel Jakub Dawidek
http://www.wheelsystems.com
FreeBSD committer
http://www.FreeBSD.org
Am I Evil? Yes, I Am!
http://mobter.com
--PNTmBPCT7hxwcZjr
Content-Type: application/pgp-signature
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.20 (FreeBSD)
iEYEARECAAYFAlG3ey4ACgkQForvXbEpPzTfEwCg3rlUA3Z3vFYYQR4QV/zO4N4x
rPsAnj4IhgEpEcACkBCGuJ+P8LCt5CVU
=RGeE
-----END PGP SIGNATURE-----
--PNTmBPCT7hxwcZjr--