Tobias Brunner [Thu, 7 Mar 2013 12:50:29 +0000 (13:50 +0100)]
android: Add support for combined certificate and EAP authentication
This uses RFC 4739 multiple authentication rounds to first
authenticate the client with a certificate followed by an
EAP authentication round with username and password.
Martin Willi [Thu, 7 Mar 2013 08:50:43 +0000 (09:50 +0100)]
As Quick Mode initiator, select a subset of the proposed and the returned TS
Cisco 5505 firewalls don't return the port if we send a specific one, letting
the is_contained_in() checks fail. Using get_subset() selection builds the
Quick Mode correctly with the common subset of selectors.
Tobias Brunner [Fri, 1 Mar 2013 16:01:21 +0000 (17:01 +0100)]
android: Mitigate race condition on reauthentication
If the TUN device gets recreated while another thread in handle_plain()
has not yet called select(2) but already stored the file descriptor of the
old TUN device in its FD set, select() will fail with EBADF.
Martin Willi [Fri, 1 Mar 2013 10:36:41 +0000 (11:36 +0100)]
Merge branch 'multi-eap'
Fixes the use of EAP methods in the non-first authentication round if the
initiator demands mutual EAP. Also mutual EAP can now be enforced when the
initiator sets rightauth=eap, not only with rightauth=any.
Martin Willi [Fri, 1 Mar 2013 10:33:47 +0000 (11:33 +0100)]
Merge branch 'systime'
Add a systime-fix plugin allowing an embedded system to validate certificates
if the system time has not been synchronized after boot. Certificates of
established tunnels can be re-validated after the system time gets valid.
Martin Willi [Fri, 1 Mar 2013 10:30:13 +0000 (11:30 +0100)]
Merge branch 'vip-shunts'
Installs bypass policies for the physical address if a virtual address is
assigned, and installs a proper source route to actually use the physical
address for bypassed destinations.
Martin Willi [Fri, 1 Mar 2013 10:24:42 +0000 (11:24 +0100)]
Merge branch 'ikev1-mm-retransmits'
Fixes retransmit of the last Main Mode or IKE_AUTH message, and correctly
queues Main Mode messages when processing of the last message is still in
progress.
Tobias Brunner [Mon, 18 Feb 2013 16:23:04 +0000 (17:23 +0100)]
Fix auth_cfg_t.clone() for single-valued auth rules
By using the default list enumerator and adding the rules with the public
add() method, clones of auth_cfg_t objects would return the values for
single-valued auth rules in the wrong order (i.e. the oldest instead of the
newest value was returned). Using the internal enumerator (which the comment
already suggested) fixes this, but the clone will not be a full clone as
it does not contain any old values for single-valued auth rules. Since
these will never be used anyway, this should be fine.
Tobias Brunner [Tue, 26 Feb 2013 10:07:28 +0000 (11:07 +0100)]
Use SIGUSR2 for SIG_CANCEL on Android
SIGRTMIN is defined as 32 while sigset_t is defined as
unsigned long (i.e. holds 32 signals). Hence, the signal
could never be blocked. Sending the signal still canceled
threads, but sometimes in situations where they shouldn't
have been canceled (e.g. while holding a lock).
Martin Willi [Wed, 20 Feb 2013 15:17:31 +0000 (16:17 +0100)]
Install a route for shunt policies
If we install a virtual IP, its source route would render the shunt policy
useless, as locally generated traffic wouldn't match. Having a route for each
shunt policy with higher priority chooses the correct source address for
bypassed destinations.
Martin Willi [Wed, 20 Feb 2013 08:16:00 +0000 (09:16 +0100)]
After IKEv1 reauthentication, reinstall VIP routes after migrating CHILD_SAs
During IKEv1 reauthentication, the virtual IP gets removed, then reinstalled.
The CHILD_SAs get migrated, but any associated route gets removed from the
kernel. Reinstall routes after adding the virtual IP again.
Martin Willi [Tue, 19 Feb 2013 14:38:28 +0000 (15:38 +0100)]
systime-fix disables certificate lifetime validation if system time not synced
The system time can be periodically checked. If it gets valid, certificates get
rechecked with the current lifetime. If certificates are invalid, associated
IKE_SAs can be closed or reauthenticated.