Starting over

This commit is contained in:
Ian Gulliver
2016-09-25 15:56:37 -07:00
parent a78c8461d6
commit 6da1c57c36
18 changed files with 158 additions and 1514 deletions

21
lib/tun_tap_device.h Normal file
View File

@@ -0,0 +1,21 @@
#include <string>
#include <linux/if_tun.h>
class TapTunDevice {
public:
static const auto kTunFormat = IFF_TUN;
static const auto kTapFormat = IFF_TAP;
static const auto kNoPacketInfo = IFF_NO_PI;
TapTunDevice(const std::string& name, uint64_t flags);
TapTunDevice(uint64_t flags);
const std::string& Name() {
return name_;
}
private:
std::string name_;
};