A memory leak in the tls-crypt-v2 client key extraction in OpenVPN 2.5.0 through 2.6.20 and 2.7_alpha1 through 2.7.4 allows remote attackers to cause a denial of service…
OpenVPN version 2.1.0 through 2.6.20 and 2.7_alpha1 through 2.7.4 allows attackers via an off-by-one buffer write in the NTLM proxy authentication to potentially cause a…
A use-after-free in OpenVPN 2.6.0 through 2.6.20 and 2.7_alpha1 through 2.7.4 allows remote authenticated peers to potentially cause a denial of service or leak memory v…
An incomplete guard in OpenVPN 2.6.0 through 2.6.20 and 2.7_alpha1 through 2.7.4 allows remote authenticated peers to trigger a use-after-free during TLS session promoti…
The Windows interactive service in OpenVPN 2.7_alpha1 through 2.7.4 allows remote attackers to cause persistent DNS state pollution or a service crash via a crafted sear…
security/openvpn: bugfix update to 2.7.6
This is not security-relevant on FreeBSD, one security fix affects
Windows, the other one only affects builds against mbedTLS (which is not
currently supported by the port), and a third one (second bullet point)
turned out to not be exploitable.
Note that the --dev option defaults to "tun" (if not specified).
Note that --ping and --keepalive settings are now capped at 24 h.
TCP-based configurations now always enable TCP_NODELAY.
Changelog: https://github.com/OpenVPN/openvpn/releases/tag/v2.7.6
MFH: 2026Q3
Pull Request: https://github.com/freebsd/freebsd-ports/pull/584
*/*: Use C.UTF-8 locale
Ports 02f27a83b44d fixed the ports tree to the C locale so it would work
correctly in environments where users use a locale that isn't compatible
with the C locale, e.g. xx_YY.UTF-8 where [A-Z] includes more than just
upper case letters. USE_LOCALE was introduced to let ports use another
locale if they needed it. The C.UTF-8 locale was created later on to be
mostly compatible with the C locale.
Switch the ports tree locale to C.UTF-8 and remove USE_LOCALE. The
world has moved to Unicode so all ports either require it or know how to
build correctly in a Unicode environment.
PR: 295945
Exp-run by: antoine
all: drop support for FreeBSD 13, mips and risc64sf
Reviewed by: many (*)
Differential Revision: https://reviews.freebsd.org/D55624
Differential Revision: https://reviews.freebsd.org/D55642 (merged in from bofh)
many (*)
acm arrowd brooks cmt dch decke dinoex eduardo fluffy fuz gahr garga
jbeich joerg jrm kai kenrap martymac matthew mfechner michaelo mizhka
nobutaka pkubaj se tagattie thj
Anton Saietskii
GenericRikka
Gert Doering
Jan Bramkamp
Oleh Hushchenkov
Oleksandr Kryvulia
Ralf van der Enden
Yamagi
desktop kde python tcltk office
security/openvpn: Update to 2.7.1
This changes installed scripts, openvpn-client.up and .down scripts
are no longer installed into libexec/, but instead a dns-updown script
is placed into libexec/openvpn/ (all under $PREFIX).
Based on a patch provided by Marek Zarychta.
Changelog: https://github.com/OpenVPN/openvpn/releases/tag/v2.7.1
PR: 293138, 286263
security/openvpn: Fix detection of native inotify on FreeBSD 15
This fixes build when ASYNC_PUSH option is enabled
Fixed upstream in commit 38243844f225517fa1d288517db9a34a33c5ad13
Reference:
https://github.com/OpenVPN/openvpn/commit/38243844f225517fa1d288517db9a34a33c5ad13
PR: 293176
Reported by: Ivo Karabojkov
Approved by: mandree@ (via Matrix)
security/openvpn: update to v2.6.19 (bugfixes)
ChangeLog: https://github.com/OpenVPN/openvpn/blob/v2.6.19/Changes.rst#overview-of-changes-in-2619
MFH: 2026Q1 (after a few days)
security/openvpn: update to v2.6.15
ChangeLog: https://github.com/OpenVPN/openvpn/blob/v2.6.15/Changes.rst#overview-of-changes-in-2615
FreeBSD relevant changes:
(note the DCO float notifications had previously been backported
for the FreeBSD port already in 2.6.14_3, and we're not currently
building with mbedTLS support for 2.6.x)
New features / User visible changes
-----------------------------------
- Apply more checks to incoming TLS handshake packets before creating
new state - namely, verify message ID / acked ID for "valid range for
an initial packet". This fixes a problem with clients that float
very early but send control channel packet from the pre-float IP
(Github: OpenVPN/openvpn#704), backported from 2.7_beta1.
- update GPL license text to latest version from FSF
Code maintenance
----------------
- remove a few extra newline characters at the end of rarely-seen log lines
- replace assert() calls in the code with OpenVPN ASSERT() calls
(not subject to -DNDEBUG, plus better logging on the actual cause)
- remove "dh dh2048.pem" from all sample configurations, remove "dh2048.pem"
file from source tree - OpenSSL 3.5 Seclevel=3 considers this "not
secure enough" and OpenVPN has not needed an explit DH file in a long while.
Documentation Updates
---------------------
- improve ``--tmp-dir`` documentation
security/openvpn: assert()->ASSERT() cleanup
This reverts my prior assert -> if...return(false) change
to Ralf Lici's backport, and replaces all assert() by ASSERT().
Gert Doering writes:
| OpenVPN's ASSERT() macro will do a bit more than the standard-libc
| assert() call, namely print out which function and what expression
| failed, before calling _exit(1). Also, it can not be accidentially
| compiled-away (-DNDEBUG).
|
| Use of ASSERT() generally only advised in cases of "this must not happen,
| but if it does, it's a programming or state corruption error that we
| must know about". Use of assert() is lacking the extra debug info, and as
| such, not advised at all.
This is a backport of OpenVPN master changes...
Obtained from: Gert Doering <gert@greenie.muc.de>
Obtained from: <https://gerrit.openvpn.net/c/openvpn/+/1171>
PR: 289303
MFH: 2025Q3 (suggestion after 10 days)
security/openvpn: support DCO float notifications
The FreeBSD kernel added "if_ovpn: support floating clients"
on main on 2025-07-28, and merged it to 14/stable on 2025-08-13.
https://reviews.freebsd.org/D51468
https://cgit.freebsd.org/src/commit/?id=9c52600a5a150117b4396df3b868cf2516e1674c&h=main
https://cgit.freebsd.org/src/commit/?h=stable/14&id=fc387ed68f3c7b0b8da9bab13492b7bbafecb5bf
This adds a new notification from the kernel module to user space
named OVPN_NOTIF_FLOAT, which OpenVPN 2.6.14 does not support.
Backport support into OpenVPN 2.6.
Reported by: Marek Zarychta <zarychtam@plan-b.pwste.edu.pl>
Obtained from: Kristof Provost <kp@FreeBSD.org>
Obtained from: Ralf Lici <ralf@mandelbit.com>
- modified to avoid assert() in nvlist_to_sockaddr()
in src/openvpn/dco_freebsd.c
Obtained from: Gert Doering <gert@greenie.muc.de>
Tested by: Marek Zarychta <zarychtam@plan-b.pwste.edu.pl>
PR: 289303
MFH: 2025Q3 (suggestion after 10 days)
security/openvpn: remove 2048-bit legacy Diffie Hellman
I received a fallout complaint from i386 FreeBSD 15-PRERELEASE
builders that, as of now, has no other explanation than a tightened
(if intermediately) SECLEVEL on that machine, and that's due to
Diffie-Hellman 2048 bit parameters, and self-tests are failing
with stereotypical "ee key too small" and "dh key too small".
While it's not clear what the exact cause of the failure is and
if we had a glitch in the OpenSSL 3.5.1 import (Enji updated
the main branch to 3.5.2 shortly after), let's modernize the
setup a bit.
Fallout and Builder logs (I take it the 2nd URL states
that the FreeBSD src branch was at commit c6778f3a442):
https://pkg-status.freebsd.org/beefy17/data/main-i386-default/p98b748365fe6_sc6778f3a442/logs/openvpn-2.6.14.log
https://pkg-status.freebsd.org/beefy17/build.html?mastername=main-i386-default&build=p98b748365fe6_sc6778f3a442
2025-08-20 11:46:39 OpenVPN 2.6.14 i386-portbld-freebsd15.0 [SSL (OpenSSL)] [LZO] [LZ4] [PKCS11] [MH/RECVDA] [AEAD] [DCO]
2025-08-20 11:46:39 Note: dev-type not tun, disabling data channel offload.
2025-08-20 11:46:39 library versions: OpenSSL 3.5.1 1 Jul 2025, LZO 2.10
2025-08-20 11:46:39 OpenVPN 2.6.14 i386-portbld-freebsd15.0 [SSL (OpenSSL)] [LZO] [LZ4] [PKCS11] [MH/RECVDA] [AEAD] [DCO]
2025-08-20 11:46:39 DCO version: FreeBSD 15.0-PRERELEASE 1500061
2025-08-20 11:46:39 library versions: OpenSSL 3.5.1 1 Jul 2025, LZO 2.10
2025-08-20 11:46:39 DCO version: FreeBSD 15.0-PRERELEASE 1500061
2025-08-20 11:46:39 NOTE: the current --script-security setting may allow this configuration to call user-defined scripts
2025-08-20 11:46:39 GDG: problem writing to routing socket: Invalid argument (errno=22)
2025-08-20 11:46:39 NOTE: the current --script-security setting may allow this configuration to call user-defined scripts
2025-08-20 11:46:39 OpenSSL: error:030000A8:digital envelope routines::unknown security bits:
2025-08-20 11:46:39 OpenSSL: error:0A00018A:SSL routines::dh key too small:
2025-08-20 11:46:39 SSL_CTX_set0_tmp_dh_pkey
2025-08-20 11:46:39 Exiting due to fatal error
2025-08-20 11:46:39 OpenSSL: error:030000A8:digital envelope routines::unknown security bits:
2025-08-20 11:46:39 OpenSSL: error:0A00018F:SSL routines::ee key too small:
2025-08-20 11:46:39 Cannot load inline certificate file
2025-08-20 11:46:39 Exiting due to fatal error
FAIL: t_cltsrv.sh
That prompted upstream to file a bug and the suggestion to strip
dh2048.pem from installing the demo file and sample configuration should
not affect existing setups, however, if someone would have used
the shipped dh2048.pem file, that would have to be regenerated with
openssl dhparam -out dh2048.pem 2048.
https://github.com/OpenVPN/openvpn/issues/819
https://gerrit.openvpn.net/c/openvpn/+/1145
Upstream changelog, as of v3 of the latter:
| Remove use of 'dh dh2048.pem' from sample configs, remove 'dh2048.pem' file
|
| Since commit bd9aa06feb41 (Jan 2015) OpenVPN has allowed to use
| '--dh none' to disable traditional Diffie Hellman, since more secure
| ECDH algorithms are available that do not use explicit DH parameters.
|
| If configured with a suffiently high securelevel (3+), or if running in
| FIPS mode, OpenSSL 3.5 will refuse 2048 bit DH files, making our tests
| fail.
|
| Thus, remove all the DH2048 stuff from our sample configs.
Obtained from: Gert Doering
While here, delete files/patch-src_plugins_auth-pam_auth-pam.c
because upstream (namely Antonio Quartulli) had fixed that omission
in v2.6-beta1 already (in 2022, as of OpenVPN's commit 0fed64a91d894b46).
Nobody has been able yet to reproduce the test failure other than by
forcing SECLEVEL=3, so let's just push this and see if we receive
pkg-fallout again next time i386 gets its ports built. Upstream
considers the patch necessary anyways, so let's not waste too much
time on testing on a dying system.
security/openvpn: security update to 2.6.14
"Fix possible ASSERT() on OpenVPN servers using --tls-crypt-v2
Security scope: OpenVPN servers between 2.6.1 and 2.6.13 using
--tls-crypt-v2 can be made to abort with an ASSERT() message by sending
a particular combination of authenticated and malformed packets.
To trigger the bug, a valid tls-crypt-v2 client key is needed, or
network observation of a handshake with a valid tls-crypt-v2 client key
No crypto integrity is violated, no data is leaked, and no remote code
execution is possible.
This bug does not affect OpenVPN clients."
ChangeLog: https://github.com/OpenVPN/openvpn/blob/v2.6.14/Changes.rst#overview-of-changes-in-2614
Security: 2cad4541-0f5b-11f0-89f8-411aefea0df9
Security: CVE-2025-2704
MFH: 2025Q2
security/openvpn: critical update to 2.6.13
ChangeLog: https://github.com/OpenVPN/openvpn/blob/v2.6.13/Changes.rst#overview-of-changes-in-2613
Notably: Security fixes
improve server-side handling of clients sending usernames or
passwords longer than USER_PASS_LEN - this would not result in a crash,
buffer overflow or other security issues, but the server would then
misparse incoming IV_* variables and produce misleading error messages.
Security: 47bc292a-d472-11ef-aaab-7d43732cb6f5
MFH: 2025Q1
security/openvpn: update to bugfix release 2.6.10
Changelog: https://github.com/OpenVPN/openvpn/blob/v2.6.10/Changes.rst#overview-of-changes-in-2610
Note that the security-related fixes only pertain to the Windows
operating system.
*/*: Sunset 12.4-RELEASE/12-STABLE from ports tree
- Remove all references to defunct ARCH arm
- Remove all references to defunct ARCH sparc64
- Remove x11-drivers/xf86-video-sunffb which requires defunct sparc64
ARCH
- Remove sysutils/afbinit requires defunct sparc64 ARCH
- Remove all references to bktr driver
- Remove all references to defunct FreeBSD_12
- Remove all references to OSVERSION/OSREL corresponding to 12
- Remove conditionals in Mk/Uses/cabal.mk
- Remove sparc reference from Mk/Uses/qt-dist.mk
- Remove BROKEN_sparc64/NOT_FOR_ARCH=sparc64
- Remove BROKEN_FreeBSD_12* from:
- Remove OpenSSL patches from:
- Remove conditional flags for OSVERSION >= 1300000 to fixed flags.
Also move conditional flags for non sparc64/arm ARCH to fixed flags.
Reviewed by: brooks, jbeich, rene, salvadore
Differential Revision: https://reviews.freebsd.org/D42068
security/openvpn: add missing 2.6.x documentation,
...for instance, README.dco.md but also others.
Update DCO help text to refer to this .md file.
Found while debugging
PR: 275206
MFH: 2023Q4
security/openvpn: fix regressions and some documentation bits
Add two patches cherry-picked from upstream Git repository:
OpenVPN 2.6.7 regressed and experienced crashes in some situations,
https://github.com/OpenVPN/openvpn/issues/449
Reported by: Vladimir Druzenko (vvd@)
Reported by: Patrick Cable (upstream)
Obtained from: https://github.com/openvpn/openvpn/commit/b90ec6dabfb151dd93ef00081bbc3f55e7d3450f
Also, some typos in the documentation are fixed,
Obtained from: https://github.com/OpenVPN/openvpn/commit/457f468a76f324a14b1236988cc5f5a95f14abf5
Bump PORTREVISION.
PR: 275055
MFH: 2023Q4
security/openvpn: bugfix update to v2.6.3
I separately verified the OpenVPN signature and ran more tests,
which the PR did not announce if it did.
Changelog: https://github.com/OpenVPN/openvpn/blob/release/2.6/Changes.rst#overview-of-changes-in-263
PR: 270831
MFH: 2023Q2
security/openvpn: update to new upstream release 2.6.2
Changes:
https://github.com/OpenVPN/openvpn/blob/release/2.6/Changes.rst#overview-of-changes-in-262
Note that --inactive does not yet work on FreeBSD.
security/openvpn: remove header file that now ships with 2.6.1 tarball
Since this is identical to what's in the tarball, no PORTREVISION
bump is required.
security/openvpn: default-enable DCO
(on FreeBSD but not 12 and 13, because the relevant if_ovpn module
is to appear in FreeBSD 14.)
Reported by: Kristof Provost (kp@)
security/openvpn*: update to 2.6.0, keep openvpn25
- copy openvpn to openvpn25, mark as deprecated and to expire March 31
- update openvpn to openvpn 2.6.0, highlights from Frank Lichtenheld's
release announcement e-mail, slightly edited:
* Data Channel Offload (DCO) kernel acceleration support for Windows,
Linux, and FreeBSD [14].
* OpenSSL 3 support
* Improved handling of tunnel MTU, including support for pushable MTU.
* Outdated cryptographic algorithms disabled by default, but there are
options to override if necessary.
* Reworked TLS handshake, making OpenVPN immune to replay-packet state
exhaustion attacks.
* Added --peer-fingerprint mode for a more simplistic certificate setup
and verification.
* Improved protocol negotiation, leading to faster connection setup.
ChangeLog: https://github.com/OpenVPN/openvpn/blob/v2.6.0/Changes.rst
Remove WWW entries moved into port Makefiles
Commit b7f05445c00f has added WWW entries to port Makefiles based on
WWW: lines in pkg-descr files.
This commit removes the WWW: lines of moved-over URLs from these
pkg-descr files.
Approved by: portmgr (tcberner)
Add WWW entries to port Makefiles
It has been common practice to have one or more URLs at the end of the
ports' pkg-descr files, one per line and prefixed with "WWW:". These
URLs should point at a project website or other relevant resources.
Access to these URLs required processing of the pkg-descr files, and
they have often become stale over time. If more than one such URL was
present in a pkg-descr file, only the first one was tarnsfered into
the port INDEX, but for many ports only the last line did contain the
port specific URL to further information.
There have been several proposals to make a project URL available as
a macro in the ports' Makefiles, over time.
This commit implements such a proposal and moves one of the WWW: entries
of each pkg-descr file into the respective port's Makefile. A heuristic
attempts to identify the most relevant URL in case there is more than
one WWW: entry in some pkg-descr file. URLs that are not moved into the
Makefile are prefixed with "See also:" instead of "WWW:" in the pkg-descr
files in order to preserve them.
There are 1256 ports that had no WWW: entries in pkg-descr files. These
ports will not be touched in this commit.
The portlint port has been adjusted to expect a WWW entry in each port
Makefile, and to flag any remaining "WWW:" lines in pkg-descr files as
deprecated.
Approved by: portmgr (tcberner)
security/openvpn: Bump PORTREVISION to be newer than on quarterly.
This is to make sure that with 2022Q3 branching off of this
version, the package will look newer and flush out the old
package, with MBEDTLS and TUNNELBLICK options now removed.
security/openvpn: update to v2.5.7
FreeBSD-related changes from Changes.rst:
- Limited OpenSSL 3.0 support
OpenSSL 3.0 support has been added. OpenSSL 3.0 support in 2.5 relies
on the compatiblity layer and full OpenSSL 3.0 support is coming with
OpenVPN 2.6. Only features that impact usage directly have been
backported:
``--tls-cert-profile insecure`` has been added to allow selecting the
lowest OpenSSL security level (not recommended, use only if you must).
OpenSSL 3.0 no longer supports the Blowfish (and other deprecated)
algorithm by default and the new option ``--providers`` allows loading
the legacy provider to renable these algorithms. Most notably,
reading of many PKCS#12 files encrypted with the RC2 algorithm fails
unless ``--providers legacy default`` is configured.
The OpenSSL engine feature ``--engine`` is not enabled by default
anymore if OpenSSL 3.0 is detected.
- print OpenSSL error stack if decoding PKCS12 file fails
- fix PATH_MAX build failure in auth-pam.c
- fix t_net.sh self-test leaving around stale "ovpn-dummy0" interface
detailed changes: https://github.com/OpenVPN/openvpn/releases/tag/v2.5.7
security/openvpn: drop man source patch
There has been a report of sporadic man-page rebuilds on OpenZFS.
While the patch order is correct, we do not intend to rebuild the
manpage (after a nobody -> openvpn change, for instance), and
we also patch the output files. So just remove the source patch.
This should go without any functional changes, so ships without
bumping PORTREVISION.
There is an upstream ticket reporting a missing source file
in the tarball. https://community.openvpn.net/openvpn/ticket/1461
Reported by: Jan Martin Mikkelsen
PR: 263116