vifctl.c File Reference
Vifctl - Virtual Interface Control.
More...
#include <errno.h>
#include <stdarg.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <syslog.h>
#include <unistd.h>
#include "vif.h"
#include "vifctl_print.h"
Go to the source code of this file.
|
Functions |
void | vifctl_usage (int rtrn) |
int | ignore_debug (const char *text,...) |
int | print_debug (const char *format,...) |
void | ignore_debug_args (const char *format, va_list arg) |
void | print_debug_args (const char *format, va_list arg) |
int | vifctl_error (const char *format,...) |
void | vifctl_log (const char *format,...) |
ssize_t | vifctl_parse_args (int argc, char *argv[]) |
int | main (int argc, char *argv[]) |
Variables |
char * | exec_name = NULL |
char | vifctl_version [] = "0.3.0 (beta)\0" |
int | vifctl_dbg = 0 |
int | create_vif = 0 |
int | delete_vif = 0 |
int | list_vif = 0 |
int | notify_id = -1 |
const char * | arg_name = NULL |
int(* | vifctl_debug )(const char *format,...) |
void(* | vifctl_debug_args )(const char *format, va_list args) |
Detailed Description
Vifctl - Virtual Interface Control.
Usage: vifctl [-cdhlr] DEVICENAME Manage virtual wireless interfaces vifctl -c VIFNAME Create virtual wireless interface -r VIFNAME Remove virtual wireless interface -l List virtual wireless interfaces -d Enable verbose output -h Print this help
Manage virtual wireless interfaces. These consist of a real Ethernet device via TUN/TAP driver and a seperate wireless configuration. This one is consistent with an unconfigured Atheros WLAN device.
To set and get the wireless configuration you have to use a patched version of the wireless-tools package.
The devices will be automatically created at program start and deleted again at program exit.
Definition in file vifctl.c.
Function Documentation
int ignore_debug |
( |
const char * |
text, |
|
|
|
... | |
|
) |
| | |
Empty function to match printf signature
Definition at line 79 of file vifctl.c.
void ignore_debug_args |
( |
const char * |
format, |
|
|
va_list |
arg | |
|
) |
| | |
Empty function to match print_debug_args signature
Definition at line 101 of file vifctl.c.
int main |
( |
int |
argc, |
|
|
char * |
argv[] | |
|
) |
| | |
int print_debug |
( |
const char * |
format, |
|
|
|
... | |
|
) |
| | |
Print debug message with variable argument list
Definition at line 87 of file vifctl.c.
void print_debug_args |
( |
const char * |
format, |
|
|
va_list |
arg | |
|
) |
| | |
Print debug message with given argument list
Definition at line 108 of file vifctl.c.
int vifctl_error |
( |
const char * |
, |
|
|
|
... | |
|
) |
| | |
Print error message to stderr
Definition at line 118 of file vifctl.c.
void vifctl_log |
( |
const char * |
, |
|
|
|
... | |
|
) |
| | |
Send message to syslog and print to debug output
Definition at line 137 of file vifctl.c.
ssize_t vifctl_parse_args |
( |
int |
argc, |
|
|
char * |
argv[] | |
|
) |
| | |
Check parameter validity and return interface names and number
Definition at line 161 of file vifctl.c.
void vifctl_usage |
( |
int |
rtrn |
) |
|
Print program usage to stdout
Definition at line 64 of file vifctl.c.
Variable Documentation
Device name argument pointer
Definition at line 54 of file vifctl.c.
Create virtual interface
Definition at line 50 of file vifctl.c.
Delete virtual interface
Definition at line 51 of file vifctl.c.
Program name
Definition at line 47 of file vifctl.c.
List virtual interfaces
Definition at line 52 of file vifctl.c.
Virtual interface notification ID
Definition at line 53 of file vifctl.c.
Debug mode
Definition at line 49 of file vifctl.c.
Program version
Definition at line 48 of file vifctl.c.