Hacker News new | ask | show | jobs
by nokun7 323 days ago
Basic question: Is PF related to ebpf by any chance?
2 comments

no, but b in bpf stands for Berkeley, so the interface originated from bsd.

bpf is a virtual machine to process network packets in kernel space. So it is sort of like the low level assembly language of network processing. It is entirely possible to build a high-level packet filtering language that compiles down to bpf, But I don't think PF does this. PF appears to use it's own specific network processing interface.

https://man.openbsd.org/pf

Note the pf specific ioctls used to inject rules into the kernel.

PF stands for packet filter in both cases