File: README

package info (click to toggle)
tun 1.1-7
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 496 kB
  • ctags: 329
  • sloc: ansic: 2,936; sh: 1,584; makefile: 341
file content (67 lines) | stat: -rw-r--r-- 2,272 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
Universal TUN/TAP device driver.
Copyright (C) 1999-2000 Maxim Krasnyansky <max_mk@yahoo.com>

  Linux, Solaris drivers 
  Copyright (C) 1999-2000 Maxim Krasnyansky <max_mk@yahoo.com>

  FreeBSD TAP driver 
  Copyright (c) 1999-2000 Maksim Yevmenkin <m_evmenkin@yahoo.com>

1. Description
  TUN/TAP provides packet reception and transmission for user space programs. 
  It can be viewed as a simple Point-to-Point or Ethernet device, which 
  instead of receiving packets from a physical media, receives them from 
  user space program and instead of sending packets via physical media 
  writes them to the user space program. 

  When a program opens /dev/tunX or /dev/tapX, driver creates and 
  registers corresponding net device tunX or tapX. After a program closed 
  above devices, driver will automatically delete tunXX or tapXX device 
  and all routes corresponding to it.

  This package(http://vtun.sourceforge.net/tun) contains two simple example 
  programs how to use tun and tap devices. Both programs work like 
  bridge between two network interfaces.
  br_select.c - bridge based on select system call.
  br_sigio.c  - bridge based on async io and SIGIO signal.
  However the best example is VTun http://vtun.sourceforge.net :))  

2. Installation
  Run './configure' to configure the driver.

  Run 'make install' to compile and install driver module and to create 
  proper device nodes.

3. Loading driver module
  Linux
     To load TUN/TAP driver module run:
	modprobe tun 

     To configure automatic loading of the 'tun' module you have to modify
     /etc/modules.conf
     Add following line if you have 2.2.x kernel:
    	alias char-major-90 tun		

     Add following line if you have 2.4.x kernel:
	alias char-major-10-200 tun

     Run:
        modprobe -a

     TUN/TAP driver will be automatically loaded when application access
     /dev/tunX, /dev/tapX or /dev/net/tun. 

     If "Kernel module loader" - module auto-loading support is not enabled 
     in your kernel then you can add 
        modprobe tun 
     to one of the startup rc files.

  Solaris
     Everything is done automatically under Solaris.

  FreeBSD
     To load TAP driver module run:
	kldload if_tap
     Add:
	kldload if_tap
     to one of the startup rc files.