IPFire currently does not have a native OpenVPN client configuration.
In this example, we have set the IPFire device to 192.168.10.1 and it will assign 192.168.10.100 - 192.168.10.150 to clients connected to it via DHCP.
Download configuration file
- First, go to our download page for configuration files.
- Enter your account number in the first field.
- Select Android from the Platform field.
- Select your desired region in the Region field (in this example, we chose Sweden).
- Click on the Download button.
Connect to IPFire IP
In your browser, connect to your IPFire IP. If this is the first time, you might be shown a page like the one below.
If so, you'll need to click on Advanced, then Add exception, and finally you'll need to enter your IPFire username and password to log in.
- Click on System and then SSH access to reach the SSH settings.
- Enable SSH access by checking the SSH Access checkbox and then click on Save.
- Click on Firewall --> Firewall Options. Next to Masquerade GREEN, choose Masquerading disabled, then click on Save.
Assign DNS server
- Click on Network and then Assign DNS-SERVER.
- Enter the DNS you wish to use. In this example, we use the Mullvad DNS (22.214.171.124) as primary.
- Click on Save.
Upload Mullvad config file
Upload the mullvad_config_xx.ovpn file to the IPFire machine with scp (or copy and paste it). You will need to replace xx in the file name with the corresponding letters of the config file you downloaded.
scp -P 222 mullvad_config_xx.ovpn email@example.com:/root/
Issue the following commands in a terminal on the IPFire machine.
cat mullvad_config_xx.ovpn | grep -v "tun-ipv6\|update-resolv-conf" | sed s'/ping-restart 60/ping-exit 30/' > mullvad_config_xx.ovpn
echo "modprobe tun" >> /etc/sysconfig/rc.local
echo "/root/mullvad.sh &" >> /etc/sysconfig/rc.local
echo "iptables -I FORWARD ! -o tun0 -m iprage --src-range 192.168.10.100-192.168.10.150 -j DROP" >> /etc/sysconfig/rc.local
echo "iptables -t nat -A POSTROUTING -s 192.168.10.0/24 -o tun0 -j MASQUERADE" >> /etc/sysconfig/rc.local
chmod 755 /root/mullvad.sh
Add mullvad.sh script to /root/.
while [ $COUNTER -lt 1 ]; do
openvpn --config /root/mullvad_config_xx.ovpn
Reboot your IPFire and it should be working!
Easily check your online privacy with Am I Mullvad
While you're connected to Mullvad, your browser could still be leaking information and therefore jeopardizing your privacy. With our Am I Mullvad online tool, you can now get a quick overview of your connection status.