Files
stvpn/tservice.hpp
T
Олег Бородин 3f261b0922 working commit
2026-05-20 17:15:26 +02:00

33 lines
672 B
C++

#ifndef TSERVICE_HPP
#define TSERVICE_HPP
#include <expected>
#include <string>
#include <vector>
#include <sockhand.hpp>
class NetworkSlot {
};
class TunService {
private:
std::string tunnelnet;
std::vector<std::string> localnets;
std::vector<NetworkSlot> netslots;
int listenport;
int sock;
public:
explicit TunService(int port, std::string tunnelnet, std::vector<std::string> localnets);
std::expected<void, std::string> Init(void);
std::expected<void, std::string> Bind(void);
std::expected<void, std::string> Listen(void);
void Handle(int sock);
~TunService();
};
#endif