14#ifndef OPENVPN_TUN_SERVER_TUNBASE_H
15#define OPENVPN_TUN_SERVER_TUNBASE_H
61struct Recv :
public virtual RC<thread_unsafe_refcount>
74 const std::string &reason,
75 const std::string &client_reason) = 0;
81struct Send :
public virtual RC<thread_unsafe_refcount>
97 virtual const std::string &
tun_info()
const = 0;
Reference count base class for objects tracked by RCPtr. Disallows copying and assignment.
Function< void(int fd)> PostCloseFunc
virtual Send::Ptr new_tun_obj(Recv *parent)=0
NativeHandle(const int fd_arg, const int peer_id_arg)
virtual void tun_recv(BufferAllocated &buf)=0
virtual void push_halt_restart_msg(const HaltRestart::Type type, const std::string &reason, const std::string &client_reason)=0
virtual bool tun_send_const(const Buffer &buf)=0
virtual void relay(const IP::Addr &target, const int port)=0
virtual bool tun_send(BufferAllocated &buf)=0
virtual NativeHandle tun_native_handle()=0
virtual const std::string & tun_info() const =0