Merge branch 'dev' of github.com:amnezia-vpn/amnezia-client into feature/linux-ipsec
This commit is contained in:
commit
afd2542a11
158 changed files with 6069 additions and 3480 deletions
|
|
@ -9,6 +9,7 @@
|
|||
#include "logger.h"
|
||||
#include "router.h"
|
||||
|
||||
#include "../core/networkUtilities.h"
|
||||
#include "../client/protocols/protocols_defs.h"
|
||||
#ifdef Q_OS_WIN
|
||||
#include "../client/platforms/windows/daemon/windowsdaemon.h"
|
||||
|
|
@ -211,7 +212,7 @@ bool IpcServer::enableKillSwitch(const QJsonObject &configStr, int vpnAdapterInd
|
|||
if (splitTunnelType == 0) {
|
||||
blockAll = true;
|
||||
allowNets = true;
|
||||
allownets.append(configStr.value(amnezia::config_key::hostName).toString());
|
||||
allownets.append(configStr.value("vpnServer").toString());
|
||||
} else if (splitTunnelType == 1) {
|
||||
blockNets = true;
|
||||
for (auto v : splitTunnelSites) {
|
||||
|
|
@ -220,7 +221,7 @@ bool IpcServer::enableKillSwitch(const QJsonObject &configStr, int vpnAdapterInd
|
|||
} else if (splitTunnelType == 2) {
|
||||
blockAll = true;
|
||||
allowNets = true;
|
||||
allownets.append(configStr.value(amnezia::config_key::hostName).toString());
|
||||
allownets.append(configStr.value("vpnServer").toString());
|
||||
for (auto v : splitTunnelSites) {
|
||||
allownets.append(v.toString());
|
||||
}
|
||||
|
|
@ -520,7 +521,7 @@ bool IpcServer::enablePeerTraffic(const QJsonObject &configStr)
|
|||
}
|
||||
}
|
||||
|
||||
config.m_excludedAddresses.append(configStr.value(amnezia::config_key::hostName).toString());
|
||||
config.m_excludedAddresses.append(configStr.value("vpnServer").toString());
|
||||
if (splitTunnelType == 2) {
|
||||
for (auto v : splitTunnelSites) {
|
||||
QString ipRange = v.toString();
|
||||
|
|
@ -542,7 +543,6 @@ bool IpcServer::enablePeerTraffic(const QJsonObject &configStr)
|
|||
|
||||
WindowsDaemon::instance()->prepareActivation(config, inetAdapterIndex);
|
||||
WindowsDaemon::instance()->activateSplitTunnel(config, vpnAdapterIndex);
|
||||
return true;
|
||||
#endif
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue