This paper makes a comparison firstly on the merits and the shortcomings of some typical packet filtering models , such as nit , cspf ( cmu / stanford packet filter ) and bpf ( berkeley packet filter ) etc . among them , bpf model is discussed in detail 本文首先比較了具有代表性的包過濾機(jī)制如cspf ( cmu stanfordpacketfilter )和bpf ( berkeleypacketfilter )等的優(yōu)缺點(diǎn),詳細(xì)分析了bpf模型;其次,本文在netfilter功能框架的基礎(chǔ)上以內(nèi)核模塊的方式在linux下實(shí)現(xiàn)了bpf模型,即mybpf模塊。