OPENFORTIVPN(1)
openfortivpn(1) β the manual, but make it cute β¨
okay bestie, this is the General Commands Manual page for openfortivpn, and it's a whole vibe. let's get into it π
β¨ NAME β¨
openfortivpn β Client for PPP+TLS VPN tunnel services π«Ά
πΈ SYNOPSIS πΈ
openfortivpn [<host>[:<port>]] [-u <user>] [-p <pass>]
[--cookie=<cookie>] [--cookie-on-stdin] [--saml-login[=<port>]]
[--pinentry=<name>] [--otp=<otp>] [--otp-prompt=<prompt>]
[--otp-delay=<delay>] [--no-ftm-push] [--realm=<realm>]
[--ifname=<interface>] [--set-routes=<bool>] [--no-routes]
[--set-dns=<bool>] [--no-dns] [--half-internet-routes=<bool>]
[--ca-file=<file>] [--user-cert=<file>] [--user-cert=pkcs11:]
[--user-key=<file>] [--use-syslog] [--trusted-cert=<digest>]
[--insecure-ssl] [--cipher-list=<ciphers>] [--min-tls=<version>]
[--seclevel-1] [--pppd-use-peerdns=<bool>] [--pppd-no-peerdns]
[--pppd-log=<file>] [--pppd-plugin=<file>] [--pppd-ipparam=<string>]
[--pppd-ifname=<string>] [--pppd-call=<name>]
[--pppd-accept-remote=<bool>] [--ppp-system=<string>]
[--use-resolvconf=<bool>] [--persistent=<interval>] [-c <file>] [-v|-q]
openfortivpn --help
openfortivpn --version
π DESCRIPTION π
okay so here's the tea: openfortivpn connects to a VPN by setting up a tunnel to the gateway sitting at <host>:<port>. that's it, that's the whole gig. iconic honestly. π
π OPTIONS π
--helpβ shows you the help message and then dips. bye bestie π«Ά--versionβ shows the version and exits. short and sweet fr fr.-c <file>,--config=<file>β point it at a custom config file. the default is/etc/openfortivpn/config, in case you were wondering.-u <user>,--username=<user>β your VPN account username, obviously π-p <pass>,--password=<pass>β your VPN account password, in plain text (yeah, i know π). for something more secure, use pinentry, or just letopenfortivpnprompt you for the password instead.--cookie=<cookie>β a valid cookie (SVPNCOOKIE) to use instead of a username and password. sneaky, but valid β¨--cookie-on-stdinβ reads the cookie (SVPNCOOKIE) from standard input. pipe it in, no cap.--saml-login[=<port>]β spins up a temporary web server to catch a local SAML redirect. to log in with SAML you literally just have to open<your-vpn-domain>/remote/saml/start?redirect=1and follow the login steps. when the login process finishes, the page gets redirected tohttp://127.0.0.1:8020/?id=<session-id>. and the actual URL you should use for the login β including the optional realm β gets printed to the terminal when the web server is started. slay. πΈ--pinentry=<name>β which pinentry program to use. lets you hand over the password in a secure way. for example:pinentry-gnome3on Linux, orpinentry-macon macOS. secure AND cute π-o <otp>,--otp=<otp>β the One-Time-Password.--otp-prompt=<prompt>β searches for the OTP password prompt, starting with the string<prompt>.--otp-delay=<delay>β how long to wait before sending the One-Time-Password. the delay has to be in seconds, and0means no wait at all (which, btw, is the default).--no-ftm-pushβ don't use FTM push, even if the server offers it. the server might be configured to allow two factor auth through a push notification to the mobile app; if you pass this option, authentication based on OTP gets used instead.--realm=<realm>β connect to the specified authentication realm. defaults to empty, which is usually exactly what you want. no notes.--ifname=<interface>β bind the connection to the specified network interface.--set-routes=<bool>,--no-routesβ decides whetheropenfortivpnshould try to configure IP routes through the VPN when the tunnel is up. if you use it multiple times, the last one wins, periodt.
--no-routes is literally the same as --set-routes=0.
--half-internet-routes=<bool>β decides whetheropenfortivpnshould add two routes,0.0.0.0/1and128.0.0.0/1, with higher priority, instead of replacing the default route. sneaky little trick, love that for us.--set-dns=<bool>,--no-dnsβ decides whetheropenfortivpnshould add DNS name servers into/etc/resolv.confwhen the tunnel is up. also, a dns-suffix may come through from the peer and get added to/etc/resolv.confat the same time as the name servers are added. ifresolvconfis installed and--use-resolvconfis activated,resolvconfis the one instructed to update theresolv.conffile; otherwiseopenfortivpnprepends its changes to whatever is already in theresolv.conffile. heads up though β there may be other mechanisms out there that update/etc/resolv.conf, like--pppd-use-peerdnstogether with an ip-up-script, and those might require you to callopenfortivpnwith--no-dns.--no-dnsis the same as--set-dns=0. β¨--use-resolvconf=<bool>β decides whetheropenfortivpnshould useresolvconfto add DNS name servers into/etc/resolv.conf. if you set it to false, the builtin fallback mechanism gets used instead β even ifresolvconfis actually available.--ca-file=<file>β use the specified PEM-encoded certificate bundle instead of the system-wide store, to verify the gateway certificate.--user-cert=<file>β use the specified PEM-encoded certificate if the server requires authentication with a certificate.--user-cert=pkcs11:β use at least the stringpkcs11:when you're using a smartcard π. it takes the full or a partial PKCS11-URI (seep11tool --list-token-urls).
--user-cert = pkcs11:
--user-cert = pkcs11:token=someuser
--user-cert = pkcs11:model=PKCS%2315%20emulated;manufacturer=piv_II;serial=012345678;token=someuser
this feature requires the OpenSSL PKCS engine!
--user-key=<file>β use the specified PEM-encoded key if the server requires authentication with a certificate.--pem-passphrase=<pass>β the pass phrase for the PEM-encoded key. π--use-syslogβ log to syslog instead of the terminal.--trusted-cert=<digest>β trust a given gateway. if classical TLS certificate validation fails, the gateway certificate gets matched against this value.<digest>is the X509 certificate's sha256 sum, and the certificate has to be encoded in DER form. you can use this option multiple times to trust several certificates. π--insecure-sslβ do not disable insecure TLS protocols/ciphers. if your server needs a specific cipher, consider using--cipher-listinstead. (lowkey risky, bestie, be careful π«£)--cipher-list=<ciphers>β the OpenSSL ciphers to use. if the default doesn't work, you can try alternatives likeHIGH:!MD5:!RC4, or whatever theCipher:line suggests in the output ofopenssl(1)(e.g.AES256-GCM-SHA384):
$ openssl s_client -connect <host:port>
the default is HIGH:!aNULL:!kRSA:!PSK:!SRP:!MD5:!RC4.
this applies to TLS v1.2 or lower only β do not use it with TLS v1.3 ciphers, fr fr.
--min-tls=<version>β use a minimum TLS version instead of the system default. valid values are1.0,1.1,1.2,1.3.--seclevel-1β if--cipher-listisn't specified, add@SECLEVEL=1to the list of ciphers. this lowers the limits on dh key.
applies to TLS v1.2 or lower only.
--pppd-use-peerdns=<bool>,--pppd-no-peerdnsβ whether to ask the peer ppp server for DNS server addresses and letpppdrewrite/etc/resolv.conf. ngl, there's no mechanism to tell the dns-suffix topppd. and if the DNS server addresses are requested, also--set-dns=1may race with the mechanisms insidepppdπ.
--pppd-no-peerdns is the same as --pppd-use-peerdns=0.
--pppd-log=<file>β setspppdinto debug mode and saves its logs into<file>.--pppd-plugin=<file>β use the specifiedpppdplugin instead of configuring the resolver and routes directly.--pppd-ipparam=<string>β gives an extra parameter to theip-up,ip-pre-upandip-downscripts. seeman pppd(8)for further details.--pppd-ifname=<string>β set the ppp interface name. only ifpppdsupports it. patched versions ofpppdimplement this option, but they might not be available on your platform. π--pppd-call=<name>β drops the usual arguments from thepppdcommand line and addscall <name>instead. this is useful on Debian and Ubuntu, where unprivileged users in thedipgroup can invokepppd call <name>to makepppdread and apply options from/etc/ppp/peers/<name>(including privileged ones π).--pppd-accept-remote=<bool>β whether to invokepppdwithipcp-accept-remote. enabling this option breakspppd < 2.5.0, but newerpppdversions require it. pick your fighter.--ppp-system=<string>β only available if compiled for a ppp user space client (e.g. on FreeBSD). connect to the specified system as defined in/etc/ppp/ppp.conf.--persistent=<interval>β run the VPN persistently in an endless loop and try to reconnect forever π. the reconnect interval may be specified in seconds, where0means no reconnect is done (that's the default).-vβ increase verbosity. can be used multiple times to be even more verbose.-qβ decrease verbosity. can be used multiple times to be even less verbose. shhh π€«
π¦ ENVIRONMENT and proxy support π¦
openfortivpn can be run behind an HTTP proxy that supports the HTTP connect command. it checks whether one of the environment variables https_proxy, HTTPS_PROXY, all_proxy, ALL_PROXY is set β those are supposed to contain a string in the format
http://[host]:[port]
where [host] is the ip or the fully qualified host name of the proxy server, and [port] is the TCP port number where the proxy is listening for incoming connections. if one of these variables is defined, openfortivpn tries to first establish a TCP connection to this proxy (plain HTTP, not encrypted), and then makes a request to connect to the VPN host as given on the command line or in the configuration file. the proxy is supposed to forward any subsequent packets transparently to the VPN host, so that the TLS layer of the connection is effectively established between the client and the VPN host β the proxy is just acting as a forwarding instance on the lower level of the TCP connection. π
the following environment variables are set by openfortivpn, and pppd(8) or its scripts can obtain information this way:
VPN_GATEWAYβ the ip of the gateway host
and for each route, three variables get set up, where an integer number is appended to the variable names, denoting the number of the current route:
VPN_ROUTE_DEST_...β the destination network of the routeVPN_ROUTE_MASK_...β the network mask for this routeVPN_ROUTE_GATEWAY_...β the gateway for the current route entry
if not compiled for pppd, the pppd options and the features that rely on them are not available. on FreeBSD, --ppp-system is available instead. π
<div style="display:none">more parts incoming, don't go anywhere π</div>
π CONFIGURATION π
okay so bestie, you can also pull all your options from a config file instead of typing them every single time. π Options can be taken from a configuration file. But lowkey, if you pass an option on the command line, it overrides whatever the config file says, though. π
The default configuration file is /etc/openfortivpn/config, but you can set a different one with the -c option. An empty template for the configuration file is installed to /usr/share/openfortivpn/config.template. β¨
A configuration file looks like:
# this is a comment
host = vpn-gateway
port = 443
username = foo
# Password in plain text.
# For a secure alternative, use pinentry or let openfortivpn
prompt for the password.
# password = bar
# The pinentry program to use. Allows supplying the password in a
secure manner.
# pinentry = pinentry-mac
# realm = some-realm
# useful for a gui that passes a configuration file to
openfortivpn
# otp = 123456
# otp-delay = 0
# otp-prompt = Please
# This would disable FTM push notification support, and use OTP
instead
# no-ftm-push = 1
user-cert = /etc/openfortivpn/user-cert.pem
# user-cert = pkcs1: # use smartcard as client certificate
user-key = /etc/openfortivpn/user-key.pem
pem-passphrase = baz
# the sha256 digest of the trusted host certs obtained by
# openssl dgst -sha256 server-cert.crt:
trusted-cert = certificatedigest4daa8c5fe6c...
trusted-cert = othercertificatedigest6631bf...
# This would specify a ca bundle instead of system-wide store
# ca-file = /etc/openfortivpn/ca-bundle.pem
set-dns = 0
use-resolvconf = 1
set-routes = 1
half-internet-routes = 0
pppd-use-peerdns = 1
# alternatively, use a specific pppd plugin instead
# pppd-plugin = /usr/lib/pppd/default/some-plugin.so
# for debugging pppd write logs here
# pppd-log = /var/log/pppd.log
# pass ppp interface name to pppd (if supported by a patched
pppd)
# pppd-ifname = ppp1
# pass an ipparam string to pppd, e.g. the device name (a similar
use case)
# pppd-ipparam = 'device=$DEVICE'
# instruct pppd to call a script instead of passing arguments (if
pppd supports it)
# pppd-call = script
# use-syslog = 0
insecure-ssl = 0
cipher-list = HIGH:!aNULL:!kRSA:!PSK:!SRP:!MD5:!RC4
persistent = 0
seclevel-1 = 0
π SEE ALSO π
If you want the full lore, the openfortivpn home page (https://github.com/adrienverge/openfortivpn) provides a short introduction in the README file and additional information under the Wiki tab. π¦
That's the whole vibe, bestie! This was the OPENFORTIVPN(1) manual page, dated May 4, 2020. Stay encrypted and slay. πβ¨
π¦ where this page comes from
- arch rolling: openfortivpn 1.24.1-1 Β· GPL-3.0-only
- debian trixie: openfortivpn 1.23.1-1 Β· GPL-3.0-or-later
- epel 10: openfortivpn 1.23.1-2.el10_1 Β· GPL-3.0-or-later
- fedora 43: openfortivpn 1.23.1-2.fc43 Β· GPL-3.0-or-later
- fedora 44: openfortivpn 1.23.1-3.fc44 Β· GPL-3.0-or-later
- ubuntu questing: openfortivpn 1.23.1-1
- ubuntu resolute: openfortivpn 1.24.0-2 Β· GPL-3.0-or-later
- ubuntu stonking: openfortivpn 1.24.1-1build1 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms