]> git.sesse.net Git - greproxy/blob - tunprotocol.h
Port greproxy to all the new classes and stuff.
[greproxy] / tunprotocol.h
1 #ifndef _TUNPROTOCOL_H
2 #define _TUNPROTOCOL_H 1
3
4 #include "protocol.h"
5
6 #include <stdint.h>
7 #include <string>
8
9 class TUNProtocol : public Protocol {
10 public:
11         TUNProtocol(const char *devname);
12         virtual void send_packet(uint16_t proto, const std::string &data, int incoming_seq);
13         virtual int fd() const;
14         void read_packet(Protocol* sender);
15
16 private:
17         int tunfd;
18 };
19
20 #endif  // !defined(_TUNPROTOCOL_H)