diff --git a/common/shlibs b/common/shlibs
index d1a431ec4b1..41030500290 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -3633,7 +3633,7 @@ libmanette-0.2.so.0 libmanette-0.2.1_1
 libfmt.so.9 fmt-9.0.0_1
 libelementary-calendar.so.0 libio.elementary.calendar-4.2.3_1
 libolm.so.3 olm-3.0.0_1
-libtls.so.29 libtls-3.9.1_1
+libtls.so.31 libtls-4.0.0_1
 libxmlb.so.2 libxmlb-0.2.1_1
 libvoikko.so.1 libvoikko-4.2_1
 libfstrcmp.so.0 libfstrcmp-0.7.D001_1
diff --git a/srcpkgs/libtls/template b/srcpkgs/libtls/template
index 70a921565cc..66b89b4c622 100644
--- a/srcpkgs/libtls/template
+++ b/srcpkgs/libtls/template
@@ -1,6 +1,6 @@
 # Template file for 'libtls'
 pkgname=libtls
-version=3.9.2
+version=4.0.0
 revision=1
 create_wrksrc=yes
 build_wrksrc="libressl-${version}"
@@ -14,7 +14,7 @@ license="OpenSSL, ISC"
 homepage="http://www.libressl.org/"
 changelog="https://raw.githubusercontent.com/libressl/portable/master/ChangeLog"
 distfiles="https://ftp.openbsd.org/pub/OpenBSD/LibreSSL/libressl-${version}.tar.gz"
-checksum=7b031dac64a59eb6ee3304f7ffb75dad33ab8c9d279c847f92c89fb846068f97
+checksum=4d841955f0acc3dfc71d0e3dd35f283af461222350e26843fea9731c0246a1e4
 replaces="libtls20>0"
 patch_args="-Np1 --directory=${build_wrksrc}"