Satyajeet Seth wrote:
>
> Hi
>
> I tried the example at:
> http://www.freebsd.org/cgi/cvsweb.cgi/src/share/man/man4/ng_bpf.4
>
> When I type:
>
> tcpdump -ddd ether dest xx:xx:xx:xx:xx:xx
>
> in a telnet session the command gave the raw BPF instructions, as
> expected.
>
> However, at the system console the same command gave the message:
>
> fxp0: promiscuous mode enabled
> tcpdump: syntax error
> xp0: promiscuous mode disabled
>
> Could you suggest what could be wrong?
>
> I also tried the following:
>
> 1. reboot
> 2. ping -f <some machine in lan> &
> 3. nghook -a fxp0: lower
> Now I get identical packets.
>
> 4. ngctl mkpeer fxp0: bpf divert bhook
>
> 5. ngctl name fxp0:divert bpf0
>
> 6. ngctl msg bpf0: setprogram { thisHook="bhook" ifMatch="hook2"
> ifNotMatch="hook1" bpf_prog_len=1 bpf_prog=[ { code=6 } ] }
>
> Now all the packets are sent to hook1.
> 7. nghook -a bpf0: hook1
> gives packets differing from point 3.
how different?
>
> 8. ping to any machine on the lan does not work.
> By default the upper and lower hooks of fxp0 are effectively connected. Our setup
>also does the
> same.
>
> Could you suggest why the ping does not work?
because the incoming packets are still being diverted to the bpf node.
>
> Thanks
> Satya
>
--
__--_|\ Julian Elischer
/ \ [EMAIL PROTECTED]
( OZ ) World tour 2000-2001
---> X_.---._/
v
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-net" in the body of the message