From owner-freebsd-questions Wed Jul 21 9:10:18 1999 Delivered-To: freebsd-questions@freebsd.org Received: from alicia.nttmcl.com (alicia.nttmcl.com [216.69.69.10]) by hub.freebsd.org (Postfix) with ESMTP id 089D414DB1 for ; Wed, 21 Jul 1999 09:10:12 -0700 (PDT) (envelope-from divya@nttmcl.com) Received: from localhost by alicia.nttmcl.com (8.8.5/3.5W(96/10/22)) id JAA08339; Wed, 21 Jul 1999 09:09:03 -0700 (PDT) Date: Wed, 21 Jul 1999 09:09:02 -0700 (PDT) From: Divya Mehra To: Brian Somers Cc: freebsd-questions@FreeBSD.ORG, divya@nttmcl.com Subject: Re: bpf and user PPP ( tun0 ) In-Reply-To: <199907202103.WAA41636@dev.lan.awfulhak.org> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG I invoked the BIOSETIF command before actually reading the the ppp packets. 1) For tun0 i.e user PPP it returns error "Network down". Only after PPP is up can I proceed further ( IPCP phase up). So I could not capture any PPP packets. Is my approach correct ? BIOGCGDLT returns DLT_NULL . Is that correct ? should it not be returning DLT_PPP ? 2) For ppp0 what should BIOGDLT be returning ? thanks, Divya ************************************************************************** Divyashikha Mehra NTT Multimedia Communications Laboratories Computer Systems Designer 250 Cambridge Avenue, Suite 205 650-833-3655 (Voice) Palo Alto, CA 940040, USA. mailto : divya@nttmcl.com *************************************************************************** On Tue, 20 Jul 1999, Brian Somers wrote: > > Hi, > > > > Can anyone tell me if bpf support user ppp packet ( tun 0 device) or it > > can be used only for kernel ppp ( ppp0 device ) ? > > Yes. > > > If it can support user ppp then what value should BIOSETIF be returning > > when bpf is to be used for reading ppp packets? > > >From the bpf man page: > > BIOCSETIF (struct ifreq) Sets the hardware interface associate with > the file. This command must be performed before any pack- > ets can be read. The device is indicated by name using > the ifr_name field of the ifreq structure. Additionally, > performs the actions of BIOCFLUSH. > > > Thanks, > > Divya > > > > ************************************************************************** > > Divyashikha Mehra NTT Multimedia Communications Laboratories > > Computer Systems Designer 250 Cambridge Avenue, Suite 205 > > 650-833-3655 (Voice) Palo Alto, CA 940040, USA. > > mailto : divya@nttmcl.com > > *************************************************************************** > > -- > Brian > > Don't _EVER_ lose your sense of humour ! > > > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message