tunsafe-clang15/wireguard_config.h

23 lines
746 B
C
Raw Normal View History

// SPDX-License-Identifier: AGPL-1.0-only
// Copyright (C) 2018 Ludvig Strigeus <info@tunsafe.com>. All Rights Reserved.
#ifndef TINYVPN_TINYVPN_H_
#define TINYVPN_TINYVPN_H_
#include <string>
class DnsResolver;
class WireguardProcessor;
class WgConfig {
public:
static bool HandleConfigurationProtocolMessage(WireguardProcessor *proc, const std::string &&message, std::string *result);
private:
static void HandleConfigurationProtocolGet(WireguardProcessor *proc, std::string *result);
};
2018-10-12 17:52:51 -05:00
bool ParseWireGuardConfigString(WireguardProcessor *wg, char *buf, size_t buf_size, DnsResolver *dns_resolver);
bool ParseWireGuardConfigFile(WireguardProcessor *wg, const char *filename, DnsResolver *dns_resolver);
#endif // TINYVPN_TINYVPN_H_