#include <sys/types.h>#include <sys/param.h>#include <sys/socket.h>#include <sys/select.h>#include <sys/ioctl.h>#include <netinet/in_systm.h>#include <netinet/in.h>#include <net/if.h>#include <net/if_tun.h>#include <errno.h>#include <stdio.h>#include <stdint.h>#include <stdlib.h>#include <string.h>#include <unistd.h>#include <fcntl.h>#include "common.h"#include "util.h"#include "tunnel.h"Data Structures | |
| struct | tunnel |
Macros | |
| #define | ROUTE_DEL 0 |
| #define | ROUTE_ADD 1 |
Functions | |
| static int | tunnel_ifconfig (void) |
| static int | tunnel_route (int op, uint32_t net, uint32_t mask, uint32_t gw) |
| int | tunnel_open (uint32_t net, uint32_t mask, outputfunc_t o) |
| void | tunnel_close (void) |
| void | tunnel_input (void) |
| void | tunnel_output (char *buffer, int len) |
Variables | |
| static struct tunnel | gTunnel |
| static outputfunc_t | gOutput |
| #define ROUTE_ADD 1 |
| #define ROUTE_DEL 0 |
| void tunnel_close | ( | void | ) |
|
static |
| void tunnel_input | ( | void | ) |
| int tunnel_open | ( | uint32_t | net, |
| uint32_t | mask, | ||
| outputfunc_t | o ) |
| void tunnel_output | ( | char * | buffer, |
| int | len ) |
|
static |
|
static |
|
static |