Date: Fri, 05 Oct 2007 10:57:42 -0700 From: Julian Elischer <julian@elischer.org> To: Vinod VM <vinuvm@gmail.com> Cc: freebsd-net@freebsd.org Subject: Re: cant compile - undefined reference to `bpfattach' Message-ID: <47067B16.4020907@elischer.org> In-Reply-To: <8de278a20710050659y55cbc312le303f1b44452b605@mail.gmail.com> References: <8de278a20710050424t68cf95eap99cd34a13e8ce594@mail.gmail.com> <20071005120406.GQ971@void.codelabs.ru> <8de278a20710050659y55cbc312le303f1b44452b605@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
Vinod VM wrote: > Thanks for the reply! > > On 10/5/07, Eygene Ryabinkin <rea-fbsd@codelabs.ru> wrote: >> Fri, Oct 05, 2007 at 04:54:27PM +0530, Vinod VM wrote: >>> /var/tmp//ccphxfRO.o(.text+0x3c): In function `main': >>> : undefined reference to `bpfattach' >> If I am correct, bpfattach is the kernel-level function. And you're >> trying to write some user-space utility, aren't you? > > Yes. I am trying to write a program to capture from an interface and > inject them to another, kind of like bcrelay functionality in poptop > [http://www.poptop.org/] > >> If you're trying to capture packets, you'll probably want to >> consult the pcap(3) manual page. > > Thanks! Does it support injecting packets into an interface? hmmm have a look at netgraph at least some of the following node types may be useful to you, and writing new ones is easy. ng_async(4), ng_atm(4), ng_atmllc(4), ng_atmpif(4), ng_bluetooth(4), ng_bpf(4), ng_bridge(4), ng_bt3c(4), ng_btsocket(4), ng_cisco(4), ng_device(4), ng_echo(4), ng_eiface(4), ng_etf(4), ng_ether(4), ng_fec(4), ng_frame_relay(4), ng_gif(4), ng_gif_demux(4), ng_h4(4), ng_hci(4), ng_hole(4), ng_hub(4), ng_iface(4), ng_ip_input(4), ng_ksocket(4), ng_l2cap(4), ng_l2tp(4), ng_lmi(4), ng_mppc(4), ng_netflow(4), ng_one2many(4), ng_ppp(4), ng_pppoe(4), ng_pptpgre(4), ng_rfc1490(4), ng_socket(4), ng_split(4), ng_sppp(4), ng_sscfu(4), ng_sscop(4), ng_tee(4), ng_tty(4), ng_ubt(4), ng_UI(4), ng_uni(4), ng_vjc(4), ng_vlan(4), ngctl(8), nghook(8) > > vinod > _______________________________________________ > freebsd-net@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-net > To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org"
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?47067B16.4020907>