Commit Graph

17010 Commits

Author SHA1 Message Date
Andreas Steffen d99e73548e libtpmtss: Fixed inclusion of tcti-tabrmd.h header file 2018-10-19 10:46:08 +02:00
Tobias Brunner f18945dfea libvici: Wrap header in extern "C" to include it from C++
Fixes #2795.
2018-10-18 15:14:23 +02:00
Tobias Brunner 537764ea55 android: New release after fixing DNS leak and some bugs 2018-10-17 12:08:47 +02:00
Tobias Brunner 5442e8a161 android: Force the two line button to be focusable
On newer Android versions (8+) this does not seem to be necessary (adding
the onClick handler also sets "clickable" and that in turn seems to make
it focusable), however, for older releases it is (tested with 7.1.1
keyboard navigation just skips over the button).  This was seen on a
Fire TV stick.
2018-10-17 11:56:30 +02:00
Tobias Brunner 84ee9577e1 android: Avoid DNS leak due to blocking TUN device without DNS servers
It looks like Android 9 incorrectly continues to use the regular DNS
servers after the blocking TUN device is replaced with the actual
interface.  Setting DNS servers prevents that (since all traffic is
blocked, which ones doesn't really matter but local/loopback addresses
are rejected).
Interestingly, if the VPN server later does not assign any DNS servers, there
is no fallback to the non-VPN DNS servers for some reason (that's definitely
not as documented).  This could potentially be a problem as we don't
offer an option to configure DNS servers in the VPN profile.

Neither issue is seen on older Android versions (only tested on 7.1.1).
2018-10-17 11:56:30 +02:00
Tobias Brunner e89cfe4854 android: Update Gradle plugin 2018-10-17 11:56:30 +02:00
Tobias Brunner 9fb00bf89f android: Make sure we actually have a tile when updating it
Not sure when this happens exactly, in particular because the reported
stack traces look like this

java.lang.NullPointerException:
  at org.strongswan.android.ui.VpnTileService.updateTile (VpnTileService.java:220)
  at org.strongswan.android.ui.VpnTileService.onStartListening (VpnTileService.java:97)
  at android.service.quicksettings.TileService$H.handleMessage (TileService.java:407)

which violates the API documentation for getQsTile(), which states:

  This tile is only valid for updates between onStartListening() and
  onStopListening().

But apparently that's not always the case. There have been two reports
of such a crash, both on Android 8.0 and on Xiaomi Mi 5/6 devices, so
maybe it's a bug in that particular image.
2018-10-17 11:56:30 +02:00
Tobias Brunner 4bd4750131 android: Fix profile selection/edit when the device is rotated
The previous code lost track of the selected profile IDs, but the
widgets maintained their state (i.e. the list item was still selected and the
edit button still enabled).  Clicking the edit button then caused a crash when
trying to get the first item in the set.
2018-10-17 11:56:30 +02:00
Thomas Egerer a160f100fb ikev1: Log traffic selectors for missing child configs
Signed-off-by: Thomas Egerer <thomas.egerer@secunet.com>
2018-10-17 11:55:16 +02:00
Thomas Egerer 8c732b8e21 task-manager-v1: Clear retransmit alert on request retransmit
The task manager for IKEv1 issues a retransmit send alert in the
retransmit_packet() function. The corresponding retransmit cleared alert
however is only issued for exchanges we initiated after processing the
response in process_response().

For quick mode exchanges we may retransmit the second packet if the peer
(the initiator) does not send the third message in a timely manner. In
this case the retransmit send alert may never be cleared.

With this patch the retransmit cleared alert is issued for packets that
were retransmitted also when we are the responding party when we receive
the outstanding response.

Signed-off-by: Thomas Egerer <thomas.egerer@secunet.com>
2018-10-17 11:55:16 +02:00
Andreas Steffen 2d3e20a839 sec-updater.sh: Support of Debian 9.0 and Ubuntu 18.04 2018-10-07 10:14:20 +02:00
Tobias Brunner d4068a1dd8 travis: Don't build botan twice if installing dependencies is retried 2018-10-02 16:14:20 +02:00
Tobias Brunner 6e55856830 fuzzing: Add -lm to LDFLAGS if the coverage sanitizer is used
libFuzzer apparently uses math functions (e.g. ceilf) for that sanitizer.
2018-10-02 10:58:40 +02:00
Tobias Brunner 4a33dcfefc travis: Only build sonarcloud target if the token is available
That's not the case for pull requests that don't have access to
encrypted tokens/environment variables.
2018-10-02 09:38:00 +02:00
Matt Selsky b98db90763 swanctl: Fix typos in usage for swanctl rekey/terminate commands
Closes strongswan/strongswan#113.
2018-10-02 09:30:03 +02:00
Andreas Steffen 04ef28b4df Version bump to 5.7.1 2018-10-01 17:46:17 +02:00
Tobias Brunner 291c1acd4b NEWS: Add info about CVE-2018-17540 2018-10-01 10:26:08 +02:00
Tobias Brunner 129ab919a8 gmp: Fix buffer overflow with very small RSA keys
Because `keylen` is unsigned the subtraction results in an integer
underflow if the key length is < 11 bytes.

This is only a problem when verifying signatures with a public key (for
private keys the plugin enforces a minimum modulus length) and to do so
we usually only use trusted keys.  However, the x509 plugin actually
calls issued_by() on a parsed certificate to check if it is self-signed,
which is the reason this issue was found by OSS-Fuzz in the first place.
So, unfortunately, this can be triggered by sending an invalid client
cert to a peer.

Fixes: 5955db5b12 ("gmp: Don't parse PKCS1 v1.5 RSA signatures to verify them")
Fixes: CVE-2018-17540
2018-09-26 10:10:48 +02:00
Tobias Brunner 8932d6070f travis: Don't build tags separately
Travis treats tags just like branches (which sonarcloud does too) and the
tagged commit is built anyway.
2018-09-24 14:22:42 +02:00
Andreas Steffen 2a327d438c Version bump to 5.7.0 2018-09-24 11:10:12 +02:00
Tobias Brunner 86c188515e NEWS: Add info about CVE-2018-16151/52 2018-09-21 18:51:58 +02:00
Tobias Brunner 5955db5b12 gmp: Don't parse PKCS1 v1.5 RSA signatures to verify them
Instead we generate the expected signature encoding and compare it to the
decrypted value.

Due to the lenient nature of the previous parsing code (minimum padding
length was not enforced, the algorithmIdentifier/OID parser accepts arbitrary
data after OIDs and in the parameters field etc.) it was susceptible to
Daniel Bleichenbacher's low-exponent attack (from 2006!), which allowed
forging signatures for keys that use low public exponents (i.e. e=3).

Since the public exponent is usually set to 0x10001 (65537) since quite a
while, the flaws in the previous code should not have had that much of a
practical impact in recent years.

Fixes: CVE-2018-16151, CVE-2018-16152
2018-09-21 18:51:58 +02:00
Tobias Brunner 64d88efac5 travis: Run long-running tests first to reduce overall build time
Moving the manual matrix inclusions further up would be even better but
that doesn't seem possible.
2018-09-21 11:03:47 +02:00
Tobias Brunner 231c087e3c android: Disable capabilities in the android app
capset/capget are not in the NDK headers anymore, but we didn't use them
in the app anyway.
2018-09-21 11:01:26 +02:00
Tobias Brunner 7a6426082a android: Fix implementation of change_state() method in Android IMC
The signature was changed with 731e043c8e ("libimcv: Reset of IMC state for
new measurement cycle").
2018-09-21 10:55:34 +02:00
Andreas Steffen 1dd382b888 Version bump to 5.7.0rc2 2018-09-18 16:03:23 +02:00
Tobias Brunner b01327b5e1 swanctl: Document PPKs 2018-09-18 10:12:45 +02:00
Tobias Brunner 784d96e031 Fixed some typos, courtesy of codespell 2018-09-17 18:51:44 +02:00
Tobias Brunner 432e2a72b2 settings: Clarify that a key/value-pair can only occur once 2018-09-17 18:51:43 +02:00
Tobias Brunner d601058a26 settings-test: Remove unused variable in printf() call 2018-09-17 18:51:43 +02:00
Tobias Brunner c07dde4b7d vici: Fix syntax error in Ruby bindings
I guess nobody uses these.

Fixes: 2c7cfe7630 ("vici:  flush-certs command flushes certificate cache")
2018-09-17 18:51:43 +02:00
Tobias Brunner f1889ca34a imv-attestation: Don't use comma to separate statements 2018-09-17 18:51:43 +02:00
Tobias Brunner f0d34f32a7 imv-agent: Don't use comma to separate statements 2018-09-17 18:51:43 +02:00
Tobias Brunner 52b6506a23 xauth-pam: Don't use comma to separate statements 2018-09-17 18:51:42 +02:00
Tobias Brunner 2c41fb6349 tnc-pdp: Don't use comma to separate statements 2018-09-17 18:51:42 +02:00
Tobias Brunner bea10205b0 receiver: Don't use commas to separate statements
Maybe was in the INIT statement at some point.
2018-09-17 18:51:42 +02:00
Tobias Brunner 3552bba63a manager: Restore direct return if database URI is not defined
There was an exit anyway because storage_create() returns NULL if the
database can't be created.
2018-09-17 18:51:42 +02:00
Tobias Brunner 1295558ab3 imv-os-agent: Remove useless assignment
`eval` will never be TNC_IMV_EVALUATION_RESULT_DONT_KNOW so we can
remove the if statement too.
2018-09-17 18:51:42 +02:00
Tobias Brunner ddc797686f pts: Remove commented call of inexistent function 2018-09-17 18:51:42 +02:00
Tobias Brunner 0b8d00adaf counters: Fix exit status in error case 2018-09-17 18:51:42 +02:00
Tobias Brunner 66aca84eba signcrl: Remove useless assignment 2018-09-17 18:51:41 +02:00
Tobias Brunner 020045f416 asn1: Remove useless assignment 2018-09-17 18:51:41 +02:00
Tobias Brunner 3ea33d15a2 mode-config: Remove useless assignment 2018-09-17 18:51:41 +02:00
Tobias Brunner c503eec92e keymat_v1: Remove useless assignment 2018-09-17 18:51:41 +02:00
Tobias Brunner 0af96ad5e7 kernel-netlink: Check return value of both halfs when installing default route in main table 2018-09-17 18:51:41 +02:00
Tobias Brunner d51a28bd5c botan: Fix leak if hasher initialization fails 2018-09-17 18:51:41 +02:00
Tobias Brunner dc09570a12 botan: Share code to generate RSA EMSA PSS signature identifier strings 2018-09-17 18:51:40 +02:00
Tobias Brunner 2788529827 botan: Remove unnecessary nested blocks and simplify keyid allocation 2018-09-17 16:41:19 +02:00
Tobias Brunner 7855ad4c9e daemon: Remove redundant assignment to time_format 2018-09-17 16:41:18 +02:00
Andreas Steffen 11b4a87050 Version bump to 5.7.0rc1 2018-09-16 09:30:18 +02:00