LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices

Reply
 
LinkBack Search this Thread
Old 01-08-2007, 02:10 AM   #1
Peter John
LQ Newbie
 
Registered: Jan 2007
Posts: 29

Rep: Reputation: 15
Capturing Layer 3 Traffic


We have our own Bluetooth STack functional on Linux. We want to implement "IP Over Bluetooth" functionality. How can we make the kernel to route TCP/IP traffic to our BT stack ??
 
Old 01-08-2007, 03:28 AM   #2
raskin
Senior Member
 
Registered: Sep 2005
Location: Russia
Distribution: NixOS (http://nixos.org)
Posts: 1,893

Rep: Reputation: 68
Try enabling tap/tun network interface. You can then make kernel route everything needed through this interface - by standard routing configuration means, like 'ip route' or 'route' - and simply put program that translates packets to your BT stack and back on the other end of tun/tap. See documentation in kernel source.
 
Old 01-08-2007, 04:33 AM   #3
Peter John
LQ Newbie
 
Registered: Jan 2007
Posts: 29

Original Poster
Rep: Reputation: 15
Capturing Layer 3 Traffic

Any idea as to when the kernel will write into the tunX interface ??? every IP packet ?

Any good example program available?
 
Old 01-08-2007, 04:48 AM   #4
raskin
Senior Member
 
Registered: Sep 2005
Location: Russia
Distribution: NixOS (http://nixos.org)
Posts: 1,893

Rep: Reputation: 68
You will configure this interface - as usual - to have some IP and you will set up routing so that some packets will have to be routed through it. So everything that is routed through tun interface will be caught on tun device.
 
Old 01-08-2007, 04:53 AM   #5
Peter John
LQ Newbie
 
Registered: Jan 2007
Posts: 29

Original Poster
Rep: Reputation: 15
Like ifconfig /dev/tun0 192.168.0.1. Ping 192.168.0.2 will be captured on dev/tun0 ??
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
how to create layer break on dual layer dvd 5matyb5 Linux - General 2 02-28-2011 07:29 PM
DVD Drives - Dual Layer or double layer? Groundhog1248 Linux - Hardware 2 09-23-2009 09:30 PM
Capturing Layer 3 Traffic Peter John Linux - Networking 12 01-08-2007 04:21 AM
Need help with Squid and capturing url traffic? atl02wrx Linux - Software 5 06-25-2005 05:36 PM
Dual Layer ISO onto 2 Single Layer Medias iammike Suse/Novell 3 05-11-2005 05:15 PM


All times are GMT -5. The time now is 09:04 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration