Commit Graph
17989 Commits
Author SHA1 Message Date
Tobias Brunner f2420cee49 libimcv: Add Debian 11 (bullseye) to IMV database 2021-10-01 15:05:44 +02:00
Tobias Brunner 1ec01f10a2 testing: Replace arp with ip neigh
The net-tools package, which provides arp and other older utilities like
ifconfig, is not installed anymore on Debian bullseye.
2021-10-01 15:05:44 +02:00
Tobias Brunner ccac9c3047 testing: Allow DNS via TCP in net2net-dnscert scenario
New versions of Bind limit the maximum UDP message size to 1232 bytes,
which is the same that newer versions of libunbound propose as maximum via
EDNS in requests, so increasing the limit on the server wouldn't help.

Instead we allow DNS via TCP so the client can switch after receiving the
truncated UDP response.
2021-10-01 15:05:44 +02:00
Tobias Brunner 5b9c46b988 testing: Remove support for Debian jessie and FreeRADIUS 2 2021-10-01 15:05:44 +02:00
Tobias Brunner dff5a0cab8 testing: Support build with Debian bullseye base image 2021-10-01 15:05:44 +02:00
Tobias Brunner f92ad8454b openssl: Use correct key types when adopting Ed25519/448 keys
Fixes: cbf07ab5b0 ("openssl: Add support for Ed25519/Ed448")
2021-10-01 15:04:13 +02:00
Tobias Brunner c463a14483 openssl: Remove workaround for Brainpool ECDH curves for older OpenSSL versions
Using the workaround with the EVP interface, which we use to derive shared
keys since 74e02ff5e6 ("openssl: Mainly use EVP interface for ECDH"),
would actually require us to register the OIDs of these curves as NID.
Otherwise, the two EC_GROUPs used by private and public key objects
are not considered the same and the key derivation fails.

Since the curves are supported by OpenSSL since 1.0.2 it's probably rare to
find a version without them nowadays.  One exception is the old BoringSSL
version we still use on Android, which defines the NIDs but not the curve
data.  However, that version also lacks support to register OIDs as NIDs,
so the only option to support these groups there would be to got back to not
using the EVP interface, which isn't in anyone's interest.  If there really
is a need for them there, we could probably patch BoringSSL or use OpenSSL.
2021-10-01 15:04:13 +02:00
Tobias Brunner 3e148e5b76 github: Fix build on macOS due to moved OpenSSL location 2021-09-30 16:24:25 +02:00
Tobias Brunner 72e5b3b702 crl: Fix compilation with OpenSSL 3.0
Closes strongswan/strongswan#635
2021-09-30 11:57:43 +02:00
Tobias Brunner 2fbbd05ec5 github: Use OpenSSL 1.1 on macOS
The "openssl" alias now defaults to OpenSSL 3.0, which produces a lot of
deprecation warnings.  To avoid build failures due to `-Werror`, stay with
OpenSSL 1.1 until we can get rid of these issues.
2021-09-23 17:02:17 +02:00
Tobias Brunner b94236487c kernel-pfkey: Wipe request/response messages when managing SAs 2021-09-23 15:28:22 +02:00
Andreas Steffen 1b21a00fa7 Version bump to 5.9.4dr2 2021-09-21 14:18:16 +02:00
Tobias Brunner e166e6913c Change shebang for Python scripts to use python3 2021-09-21 12:51:47 +02:00
Tobias Brunner 6467f0416f testing: Fix updown script in route-based/net2net-xfrmi-ike scenario
With the update to Python 3 the encoding of the values in vici messages
changed to bytestrings (the keys are properly decoded).  And getting the
first CHILD_SA also needs a change.

The logger is now also initialized after daemonizing to avoid that opened
sockets are closed etc.
2021-09-21 12:50:12 +02:00
Andreas Steffen 3e2841572b testing: Switch to Python 3
Both swidGenerator and strongTNC were migrated to Python 3.
This allows to migrate all testing scripts to Python 3, too.
2021-09-21 09:47:43 +02:00
Tobias Brunner a5662e8f6e keymat_v2: Properly wipe DH secret during IKE_SA rekeying
While `secret` is wiped explicitly, it wasn't when concatenating with
the nonces.
2021-09-20 16:10:03 +02:00
Andreas Steffen 91896264b2 sec-updater: Use latest versions 2021-09-09 22:54:38 +02:00
Andreas Steffen d23ca7f345 os_info: Parse /etc/os-release first 2021-09-09 22:54:38 +02:00
Tobias Brunner bf91b71f1a github: Remove build on Ubuntu Xenial (16.04)
Support for it will be removed later this month.
2021-09-09 12:30:17 +02:00
Tobias Brunner a415761a8e vici: Update supported Python versions 2021-09-09 12:30:17 +02:00
Noel Kuntze fbd4930323 vici: Add DBG4 messages that print loaded shared keys and PINs
Closes strongswan/strongswan#217
2021-09-02 10:42:41 +02:00
Tobias Brunner 3c0d7ec531 ike: Initiate new IKE_SA not until all children are queued
If there are many CHILD_SAs, the time between initiating the new IKE_SA
and checking it in might be longer (depending on what else is going on
in the daemon) than the retransmission timeout and no retransmits might
be sent afterwards for this SA (it will just linger around dead).
Calling initiate() last should avoid that (we do this similarly for MBB
reauthentication).
2021-08-24 14:31:55 +02:00
Tobias Brunner 23e46ea5ab ikev2: Only request reauth during IKE_AUTH if active reauth is not possible
If we can initiate the reauthentication ourselves, there is no reason to
explicitly request the peer to do so (at basically the same time).
2021-08-24 14:31:55 +02:00
Tobias Brunner 0d373e25e0 ike-rekey: Respond with TEMPORARY_FAILURE while reauthenticating
This could lead to duplicates as the new IKE_SA can't delete the old one
once reauthentication is complete if it was replaced by a rekeying.
2021-08-24 14:31:55 +02:00
Tobias Brunner 36161febd3 ike: Don't rekey IKE_SA while reauthenticating
If we are using make-before-break reauthentication, this could lead to
duplicates as the new IKE_SA wouldn't be able to delete the previous
one if it was replaced by a rekeying.
2021-08-24 14:31:55 +02:00
Tobias Brunner 48fbe1d2d5 ike-delete: Don't call reestablish() when reauthenticating
If we initiated a make-before-break reauthentication and the peer
concurrently deletes the IKE_SA (e.g. because it uses break-before-make
reauthentication), we would create a duplicate IKE_SA (the condition forces
a recreation of all existing CHILD_SAs because reestablish() is also called
to complete a break-before-make reauthentication).
2021-08-24 14:31:55 +02:00
Tobias Brunner 57e68ab9c5 openssl: Improve compatibility to newer BoringSSL releases
Closes strongswan/strongswan#352
2021-08-24 14:20:37 +02:00
Tobias Brunner 1d64b6c462 Merge branch 'swanctl-ssh-public-keys'
Minor changes that allow loading SSH public keys via `pubkeys` in
swanctl.conf.

References strongswan/strongswan#467
2021-08-23 18:04:50 +02:00
Tobias Brunner 5821f2cc01 pubkey: Ignore X.509 flags passed to the parser 2021-08-23 17:59:39 +02:00
Tobias Brunner 4dfa31c8a0 pubkey: Don't assume blobs are only ASN.1 DER
Also forward the blob's type when parsing pubkeys.
2021-08-23 17:59:39 +02:00
Tobias Brunner de5609b297 vici: Use the more generic BUILD_BLOB to parse certificates/public keys 2021-08-23 17:59:39 +02:00
Tobias Brunner b4a34ff5ea github: Remove github.ref from cache keys
According to the documentation for actions/cache, the lookup is already
scoped to the current branch (with fallback to any base branch including
the default branch).
2021-08-23 17:53:33 +02:00
Tobias Brunner 8d422d2c83 tpm_extendpcr: Support platforms not having syslog() 2021-08-23 11:30:15 +02:00
Tobias Brunner 4aa6da69aa tpm_extendpcr: Build does not depend on tpm plugin but libtpmtss
The utility basically requires a TSS, the tpm plugin is not used at all.
2021-08-23 10:44:41 +02:00
Andreas Steffen 0eb1d6c0e6 Version bump to 5.9.4dr1 2021-08-22 10:55:37 +02:00
Tobias Brunner 5126e7c0fc libtpmtss: Initialize library from all users
Previously, only the tpm plugin initialized the library, so in order
to use a TPM 2.0 (a required TCTI library is loaded via init), it was
necessary to load it even if none of its actual features were used.
2021-08-20 17:10:11 +02:00
Tobias Brunner 6c1210dcf6 configure: Enforce tss-tss2 if tpm plugin is enabled
The plugin is useless without a TSS 2.0 and this is currently the only one.
2021-08-20 10:45:44 +02:00
Tobias Brunner 64b281723c openssl: Use a longer key to test/initialize HMAC instances
OpenSSL enforces a minimum of 14 bytes (112 bits) on the key size when
used in FIPS-mode (as required by SP 800-131A).  So by using an empty
string, instantiation always failed.  32 bytes (256 bits) should be safe
for now.

Closes strongswan/strongswan#557
2021-08-19 14:06:19 +02:00
Tobias Brunner e6a904de69 testing: Fix build of tkm and tkm-rpc 2021-08-17 19:20:45 +02:00
Tobias Brunner ce607d774b github: Use latest version of SonarScanner 2021-08-16 11:26:11 +02:00
Tobias Brunner 1c4e134f26 kernel-netlink: Initialize ifreq structs when detecting offload capability 2021-08-11 15:35:52 +02:00
Noel Kuntze 5d6e69a6e4 gitignore: Add nbproject/
As used by the NetBeans IDE.

Closes strongswan/strongswan#505.
2021-07-26 10:43:40 +02:00
Tobias Brunner 4ae9b482f2 Ignore android-* tags when using git describe 2021-07-14 10:31:52 +02:00
Tobias Brunner 1aa68a78f8 Merge branch 'android-updates'
Adds a button to install user certificates and updates the target SDK
version for Android 11 (and the related deprecation fixes), which will
be mandatory later this year.

The release also includes an older commit that changed how DNS servers
are applied to TUN devices (cd10ae2ff0 ("android: Explicitly apply DNS
servers to the TUN device")).

Also added are metadata for F-Droid.
2021-07-14 10:05:08 +02:00
Tobias Brunner 358d3d0ba1 android: New release after adding button to install PKCS#12 and SDK update
It also includes an unreleased change that affects when/how DNS servers
are applied to the TUN device.
2021-07-14 09:59:02 +02:00
Tobias Brunner a14337bcde android: Request QUERY_ALL_PACKAGES permission
This is required when targeting Android 11 (API 30) in order to see all
packages, which we use to allow selecting apps ex-/included from VPN
profiles and for the EAP-TNC use case.
2021-07-14 09:59:02 +02:00
Tobias Brunner 3eadd0fc3a android: Add Triple-T metadata for F-Droid
We currently don't use Triple-T but the metadata is also parsed by F-Droid
to provide information for included apps.
2021-07-14 09:59:02 +02:00
Tobias Brunner 2f1bf11dca android: Add a button to install user certificates
Newer Android versions don't provide this option anymore on the
selection dialog.
2021-07-14 09:59:02 +02:00
Tobias Brunner b3cdbe6693 android: Replace deprecated Switch with SwitchCompat 2021-07-14 09:59:02 +02:00
Tobias Brunner 26354d0aba android: Replace deprecated AsyncTask instances
As suggested by the Android docs, we use a global thread pool and handler
to avoid recreating them repeatedly.  Four threads should be more than
enough as we only use this to load CA certificates when the app starts
initially and to load user certs when editing a profile.
2021-07-14 09:59:02 +02:00