/***************************************************************************** * pce * *****************************************************************************/ /***************************************************************************** * File name: src/lib/tun.h * * Created: 2004-12-15 by Hampa Hug * * Copyright: (C) 2004-2012 Hampa Hug * *****************************************************************************/ /***************************************************************************** * This program is free software. You can redistribute it and / or modify it * * under the terms of the GNU General Public License version 2 as published * * by the Free Software Foundation. * * * * This program is distributed in the hope that it will be useful, but * * WITHOUT ANY WARRANTY, without even the implied warranty of * * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General * * Public License for more details. * *****************************************************************************/ #ifndef PCE_LIB_TUN_H #define PCE_LIB_TUN_H 1 int tun_open (const char *name); int tap_open (const char *name); void tun_close (int fd); int tun_set_packet (int fd, const void *buf, unsigned cnt); int tun_get_packet (int fd, void *buf, unsigned *cnt); int tun_check_packet (int fd); #endif