| 44 | } |
| 45 | |
| 46 | bool WireGuardController::configureAdapter(const std::string &ipAddress, const std::string &dnsAddressList, |
| 47 | const std::string &dnsScriptName, const std::vector<std::string> &allowedIps) |
| 48 | { |
| 49 | if (!is_initialized_ || !adapter_.get()) |
| 50 | return false; |
| 51 | return adapter_->setIpAddress(ipAddress) |
| 52 | && adapter_->setDnsServers(dnsAddressList, dnsScriptName) |
| 53 | && adapter_->enableRouting(allowedIps); |
| 54 | } |
| 55 | |
| 56 | bool WireGuardController::configureDefaultRouteMonitor(const std::string &peerEndpoint) |
| 57 | { |
no test coverage detected