35
votes
Accepted
getting Checkpoint VPN SSL Network Extender working in the command line
SNX build 800007075 from 2012, used to support the CheckPoint VPN from the Linux command line. So I tested it, and lo and behold, it still works with the latest distributions and kernel(s) 4.x/5.x.
So ...
24
votes
Failed to request VPN secrets #3
In my case (In Debian 9 by Gnome 3.2) selecting the password option "Store the password for all users" in the VPN settings got it working. All other options produce the mentioned error.
19
votes
WSL - DNS not working when connected to VPN
Resolved.
Ubuntu subsystem (WSL) could not resolve corporate and non corporate domains while on or off vpn.
Fixed.
Must create /etc/wsl.conf file and add an entry to kill the resolv.conf file from ...
18
votes
How can I use openconnect in the background
To connect:
sudo openconnect --background <...>
To disconnect:
sudo killall -SIGINT openconnect
Using SIGINT gives the background process time to clean up the DNS configuration and exit ...
16
votes
Accepted
Route everything through VPN except SSH on Port 22
You need to add routing to your server so ssh packets get routed via the server's public ip not the vpn. Failing to do that means the ssh return packet gets routed via openvpn. This is why you get ...
15
votes
Import VPN config files to NetworkManager from command line
I'm using nmcli version 1.2.6 and I can use it to import openvpn configs.
nmcli connection import type openvpn file ~/myconfig.ovpn
From now on even in NetworkManager UI my vpn is visible.
To ...
13
votes
Use ssh with a specific network interface
I don't know when it was introduced but the OpenSSH client on RHEL7 has this in its manpage:
-b bind_address
Use bind_address on the local machine as the source address of the connection. ...
12
votes
IPSec over L2TP: received NO_PROPOSAL_CHOSEN error notify
When connecting as a Meraki Client VPN, it only supports protocols that have been removed from the Strongswan default protocol negotiation list (because the SWEET32 birthday attack is possible against ...
12
votes
getting Checkpoint VPN SSL Network Extender working in the command line
When working to install the Firefox official SSL VPN Extender interface in the question VPN SSL Network Extender in Firefox, I found out and solved some more pieces of the puzzle of this question.
...
11
votes
Accepted
PPTP VPN error: LCP terminated by peer
I found the answer, I had to enable Point-to-Point encryption(MPPE) in the Advanced Settings dialog. Now it works.
11
votes
Feed all traffic through OpenVPN for a specific network namespace only
You can start the OpenVPN link inside a namespace and then run every command you want to use that OpenVPN link inside the namespace. Details on how to do it are presented in Running an OpenVPN tunnel ...
10
votes
Starting openvpn client as daemon - in debian
Use the Debian-supplied mechanism
Don't roll your own service units. Debian comes with a mechanism for scanning your OpenVPN configuration and making systemd services to match it. Use that.
Make a ...
10
votes
Accepted
How can I use openconnect in the background
According to the Openconnect documentation, the option you would want to try would be:
-b,--background
Continue in background after startup
10
votes
Accepted
How to setup DNS manually on Linux?
DNS Config Under Linux
DNS usage on linux is done over a set of routines in the C library that provide access to the Internet Domain Name System (DNS). The resolver configuration file (resolv.conf) ...
9
votes
Accepted
Feed all traffic through OpenVPN for a specific network namespace only
It turns out that you can put a tunnel interface into a network namespace. My entire problem was down to a mistake in bringing up the interface:
ip addr add dev $tun_tundv \
local $...
9
votes
Accepted
How to automatically fetch new name server on VPN connect
The OpenVPN package has a script for this in /etc/openvpn/update-resolv-conf. You need to configure it with:
script-security 2
up /etc/openvpn/update-resolv-conf
down /etc/openvpn/update-resolv-conf
...
9
votes
Accepted
Use nmcli to modify VPN password?
Yes, you can modify the value of any property with nmcli. In this case, you would use:
nmcli con modify "myvpn" vpn.secrets "password=myverysecretpassword"
9
votes
Accepted
Is there a command line program to check IP location (for VPN)?
You can use ipinfo.io or ipstack.com services through curl:
curl --silent "https://ipinfo.io/ip"
similarly change ip to country to get your geographical location.
8
votes
Accepted
strongSwan - gives error "no known IPsec stack detected, ignoring!"
That legacy check looks for /proc/net/pfkey. If not found, the code tries to load the af_key module via modprobe and then checks again. However, the PF_KEYv2 interface provided by the af_key module is ...
8
votes
NetworkManager fails with "Could not find source connection"
I got this bug even weirder.
$ nmcli c up VPN
Error: Connection activation failed: Could not find source connection.
$ nm-applet # click icon, VPN, VPN
WORKS!
I learned that Network manager first ...
8
votes
How can I use openconnect in the background
Yes. -b is the option. But that just leads to the next issue: A clean disconnect then is not possible anymore. I mean, the only way to exit openconnect when it is in background is to kill the process. ...
7
votes
Accepted
Initialization Sequence Completed, but terminal wont give a prompt
Try starting the client with the --daemon option:
openvpn --daemon
From openvpn's man page:
--daemon [progname]
Become a daemon after all initialization functions are completed
To interact with ...
7
votes
Accepted
Understanding tun0 addresses
Hardware network links can be either point to point or point to multipoint. ppp links are point to point, ethernet is point to multipoint. tun can act as either, in your case it is acting as a point ...
7
votes
NetworkManager fails with "Could not find source connection"
I had a long fight for this but this how I managed to find a workaround the issue in Ubuntu 18 using network-manager and GUI:
Download GUI packages
$ sudo apt-get install network-manager-openvpn ...
7
votes
Accepted
VPN SSL Network Extender in Firefox
Ultimately, I decided to settle on authenticating with Firefox+Java (and then later on, changed my mind, see the related link at the bottom). The VM itself does not run Java nor a graphical interface, ...
7
votes
Accepted
Wireguard not routing traffic from client to other servers on the network
After so many try and fail and brainstorming with wireguard IRC chanel guys, apparently I forgot to add a static route for 10.7.0.0/24 for each server behind wireguard. Ping goes to the server, but ...
7
votes
WSL - DNS not working when connected to VPN
See here a workaround based on a conflict observed with IPv6 DNS Servers:
https://github.com/microsoft/WSL/issues/1350#issuecomment-742454940
Please note an important fact, and workaround:
The DNS ...
6
votes
Import VPN config files to NetworkManager from command line
A workaround I use to get past the lack of functionality that comes with nmcli on debian-based systems is to use commands to copy an existing VPN config file in the /etc/NetworkManager/system-settings ...
6
votes
OpenVPN - Socket bind failed on local address [AF_INET] IP:1194: Cannot assign requested address
Removing the "local" directive from the openvpn configuration file is not a proper solution. What if you require the openvpn daemon to bind to just one network interface, which is the whole point of ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
vpn × 832networking × 213
openvpn × 203
linux × 146
routing × 92
iptables × 84
ubuntu × 79
ssh × 65
debian × 63
networkmanager × 61
ipsec × 46
centos × 43
pptp × 41
dns × 39
strongswan × 32
raspberry-pi × 23
ip × 23
route × 23
ssh-tunneling × 22
wireguard × 21
network-interface × 20
fedora × 19
openconnect × 19
arch-linux × 17
firewall × 17