Page MenuHomeFreeBSD

bpf: Fix the write filter
ClosedPublic

Authored by markj on Oct 19 2021, 4:36 PM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Oct 8, 5:34 AM
Unknown Object (File)
Sat, Oct 4, 4:13 PM
Unknown Object (File)
Thu, Sep 11, 5:36 PM
Unknown Object (File)
Thu, Sep 11, 5:20 PM
Unknown Object (File)
Thu, Sep 11, 5:05 PM
Unknown Object (File)
Thu, Sep 11, 4:27 PM
Unknown Object (File)
Sep 10 2025, 6:12 AM
Unknown Object (File)
Sep 10 2025, 6:00 AM
Subscribers

Details

Summary

A BPF descriptor only has an associated interface descriptor once it is
attached to an interface, e.g., with BIOCSETIF. Avoid dereferencing a
NULL pointer in filt_bpfwrite() if the BPF descriptor is not attached.

Fixes: ded77e0237a8 ("Allow the BPF to be select for write.")
Reported by: syzbot+ae45d5166afe15a5a21d@syzkaller.appspotmail.com

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable