MCPcopy Create free account
hub / github.com/Windscribe/Desktop-App / configureAdapter

Method configureAdapter

src/helper/linux/wireguard/wireguardcontroller.cpp:107–120  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

105
106
107bool WireGuardController::configureAdapter(const std::string &ipAddress, const std::string &dnsAddressList, const std::string &dnsScriptName,
108 const std::vector<std::string> &allowedIps, uint32_t fwmark)
109{
110 UNUSED(dnsScriptName);
111 UNUSED(dnsAddressList);
112
113 spdlog::debug("DNS: \"{}\"", dnsAddressList);
114
115 if (!is_initialized_ || !adapter_.get())
116 return false;
117 return adapter_->setIpAddress(ipAddress)
118 && adapter_->setDnsServers(dnsAddressList, dnsScriptName)
119 && adapter_->enableRouting(allowedIps, fwmark);
120}
121
122std::string WireGuardController::getAdapterName() const
123{

Callers 1

configureWireGuardFunction · 0.45

Calls 4

getMethod · 0.45
setIpAddressMethod · 0.45
setDnsServersMethod · 0.45
enableRoutingMethod · 0.45

Tested by

no test coverage detected