Merge branch 'dev' of github.com:amnezia-vpn/amnezia-client into origin/feature/new-gui
This commit is contained in:
commit
dd0de7e8be
14 changed files with 22 additions and 12 deletions
|
|
@ -396,7 +396,6 @@ class VPNService : BaseVpnService(), LocalDnsService.Interface {
|
|||
fun establish(): ParcelFileDescriptor? {
|
||||
Log.v(tag, "Aman: establish....................")
|
||||
mbuilder.allowFamily(OsConstants.AF_INET)
|
||||
mbuilder.allowFamily(OsConstants.AF_INET6)
|
||||
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.Q) mbuilder.setMetered(false)
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M) setUnderlyingNetworks(null)
|
||||
|
|
|
|||
|
|
@ -119,6 +119,10 @@ QString OpenVpnConfigurator::processConfigWithLocalSettings(QString jsonConfig)
|
|||
}
|
||||
}
|
||||
|
||||
// Prevent ipv6 leak
|
||||
config.append("ifconfig-ipv6 fd15:53b6:dead::2/64 fd15:53b6:dead::1\n");
|
||||
config.append("redirect-gateway ipv6\n");
|
||||
|
||||
#if (defined Q_OS_MAC || defined(Q_OS_LINUX)) && !defined(Q_OS_ANDROID)
|
||||
config.replace("block-outside-dns", "");
|
||||
QString dnsConf = QString(
|
||||
|
|
|
|||
|
|
@ -655,6 +655,11 @@ ErrorCode ServerController::isServerPortBusy(const ServerCredentials &credential
|
|||
script = script.append("|:%1").arg(port);
|
||||
}
|
||||
script = script.append("' | grep -i %1").arg(transportProto);
|
||||
|
||||
if (transportProto == "tcp") {
|
||||
script = script.append(" | grep LISTEN");
|
||||
}
|
||||
|
||||
ErrorCode errorCode = runScript(credentials,
|
||||
replaceVars(script, genVarsForScript(credentials, container)), cbReadStdOut, cbReadStdErr);
|
||||
if (errorCode != ErrorCode::NoError) {
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
#include <fstream>
|
||||
|
||||
#ifdef Q_OS_WINDOWS
|
||||
#define S_IRWXU 0
|
||||
const uint32_t S_IRWXU = 0644;
|
||||
#endif
|
||||
|
||||
namespace libssh {
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ user nobody
|
|||
group nobody
|
||||
persist-key
|
||||
persist-tun
|
||||
crl-verify crl.pem
|
||||
crl-verify /opt/amnezia/openvpn/crl.pem
|
||||
status openvpn-status.log
|
||||
verb 1
|
||||
tls-server
|
||||
|
|
|
|||
|
|
@ -21,5 +21,6 @@ cd /opt/amnezia/openvpn && easyrsa gen-dh; \
|
|||
cd /opt/amnezia/openvpn && cp pki/dh.pem /opt/amnezia/openvpn && easyrsa build-ca nopass << EOF yes EOF && easyrsa gen-req AmneziaReq nopass << EOF2 yes EOF2;\
|
||||
cd /opt/amnezia/openvpn && easyrsa sign-req server AmneziaReq << EOF3 yes EOF3;\
|
||||
cd /opt/amnezia/openvpn && openvpn --genkey --secret ta.key << EOF4;\
|
||||
cd /opt/amnezia/openvpn && cp pki/ca.crt pki/issued/AmneziaReq.crt pki/private/AmneziaReq.key /opt/amnezia/openvpn'
|
||||
|
||||
cd /opt/amnezia/openvpn && cp pki/ca.crt pki/issued/AmneziaReq.crt pki/private/AmneziaReq.key /opt/amnezia/openvpn;\
|
||||
cd /opt/amnezia/openvpn && easyrsa gen-crl;\
|
||||
cd /opt/amnezia/openvpn && cp pki/crl.pem /opt/amnezia/openvpn/crl.pem'
|
||||
|
|
|
|||
|
|
@ -5,7 +5,6 @@ resolv-retry infinite
|
|||
nobind
|
||||
persist-key
|
||||
persist-tun
|
||||
crl-verify crl.pem
|
||||
$OPENVPN_NCP_DISABLE
|
||||
cipher $OPENVPN_CIPHER
|
||||
auth $OPENVPN_HASH
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ user nobody
|
|||
group nobody
|
||||
persist-key
|
||||
persist-tun
|
||||
crl-verify crl.pem
|
||||
crl-verify /opt/amnezia/openvpn/crl.pem
|
||||
status openvpn-status.log
|
||||
verb 1
|
||||
tls-server
|
||||
|
|
|
|||
|
|
@ -21,4 +21,6 @@ cd /opt/amnezia/openvpn && easyrsa gen-dh; \
|
|||
cd /opt/amnezia/openvpn && cp pki/dh.pem /opt/amnezia/openvpn && easyrsa build-ca nopass << EOF yes EOF && easyrsa gen-req AmneziaReq nopass << EOF2 yes EOF2;\
|
||||
cd /opt/amnezia/openvpn && easyrsa sign-req server AmneziaReq << EOF3 yes EOF3;\
|
||||
cd /opt/amnezia/openvpn && openvpn --genkey --secret ta.key << EOF4;\
|
||||
cd /opt/amnezia/openvpn && cp pki/ca.crt pki/issued/AmneziaReq.crt pki/private/AmneziaReq.key /opt/amnezia/openvpn'
|
||||
cd /opt/amnezia/openvpn && cp pki/ca.crt pki/issued/AmneziaReq.crt pki/private/AmneziaReq.key /opt/amnezia/openvpn;\
|
||||
cd /opt/amnezia/openvpn && easyrsa gen-crl;\
|
||||
cd /opt/amnezia/openvpn && cp pki/crl.pem /opt/amnezia/openvpn/crl.pem'
|
||||
|
|
|
|||
|
|
@ -5,7 +5,6 @@ resolv-retry infinite
|
|||
nobind
|
||||
persist-key
|
||||
persist-tun
|
||||
crl-verify crl.pem
|
||||
$OPENVPN_NCP_DISABLE
|
||||
cipher $OPENVPN_CIPHER
|
||||
auth $OPENVPN_HASH
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ user nobody
|
|||
group nobody
|
||||
persist-key
|
||||
persist-tun
|
||||
crl-verify crl.pem
|
||||
crl-verify /opt/amnezia/openvpn/crl.pem
|
||||
status openvpn-status.log
|
||||
verb 1
|
||||
tls-server
|
||||
|
|
|
|||
|
|
@ -21,4 +21,6 @@ cd /opt/amnezia/openvpn && easyrsa gen-dh; \
|
|||
cd /opt/amnezia/openvpn && cp pki/dh.pem /opt/amnezia/openvpn && easyrsa build-ca nopass << EOF yes EOF && easyrsa gen-req AmneziaReq nopass << EOF2 yes EOF2;\
|
||||
cd /opt/amnezia/openvpn && easyrsa sign-req server AmneziaReq << EOF3 yes EOF3;\
|
||||
cd /opt/amnezia/openvpn && openvpn --genkey --secret ta.key << EOF4;\
|
||||
cd /opt/amnezia/openvpn && cp pki/ca.crt pki/issued/AmneziaReq.crt pki/private/AmneziaReq.key /opt/amnezia/openvpn'
|
||||
cd /opt/amnezia/openvpn && cp pki/ca.crt pki/issued/AmneziaReq.crt pki/private/AmneziaReq.key /opt/amnezia/openvpn;\
|
||||
cd /opt/amnezia/openvpn && easyrsa gen-crl;\
|
||||
cd /opt/amnezia/openvpn && cp pki/crl.pem /opt/amnezia/openvpn/crl.pem'
|
||||
|
|
|
|||
|
|
@ -5,7 +5,6 @@ resolv-retry infinite
|
|||
nobind
|
||||
persist-key
|
||||
persist-tun
|
||||
crl-verify crl.pem
|
||||
$OPENVPN_NCP_DISABLE
|
||||
cipher $OPENVPN_CIPHER
|
||||
auth $OPENVPN_HASH
|
||||
|
|
|
|||
Binary file not shown.
Loading…
Add table
Add a link
Reference in a new issue