| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| |
|
|
|
|
| |
for IKEv2 anyway
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
This allows us to properly delete the incomplete SA with the correct protocol
should negotiation fail.
|
| |
|
| |
|
|
|
|
|
|
|
| |
When we have a "keep" unique policy in place, we have to be less strict in
rejecting Main/Aggressive Modes to enforce it. If the host/port equals to
that of an existing ISAKMP SA, we assume it is a reauthentication attempt
and accept the new SA (to replace the old).
|
|
|
|
|
|
|
|
|
| |
Sending a DELETE for the replaced SA immediately is problematic during
reauthentication, as the peer might have associated the Quick Modes to the
old SA, and also delete them.
With this change the delete for the old ISAKMP SA is usually omitted, as it
is gets implicitly deleted by the reauth.
|
|
|
|
|
|
|
|
|
|
|
| |
This is especially useful on Android where we are able to send messages
even if we don't know the correct local address (this is possible
because we don't set source addresses in outbound messages). This way
we may learn the correct local address if it e.g. changed right before
reestablishing an SA.
Updating the local address later is tricky without MOBIKE as the
responder might not update the associated IPsec SAs properly.
|
| |
|
|
|
|
| |
Fixes #411.
|
|
|
|
|
|
|
|
|
|
| |
If PFS is configured for a CHILD_SA first try to create a list of
proposals with using DH group negotiated during phase 1. If the
resulting list is empty (i.e. the DH group(s) configured for PFS differ
from the one(s) configured for the IKE_SA), fall back to the first
configured DH group from the CHILD_SA.
This modificiation is due to the fact that it is likely that the peer
supports the same DH group for PFS it did already for the IKE_SA.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
The configuration string is appended to the XAuth backend name, separated by
a colon. The configuration string is passed untouched to the backend, where
it can change the behavior of the XAuth module.
|
|
|
|
| |
The old code resulted in too few fragments in some cases.
|
|
|
|
|
| |
This is same same logic used by sender and might apply in some cases (e.g.
when initiating to port 4500).
|
|
|
|
|
|
| |
closeaction=restart|hold
This regression was introduced with c949a4d5.
|
|
|
|
|
|
|
| |
handling IKE_SA_INIT
We want to avoid this allocation if the initial message is invalid (e.g.
if the message ID is != 0).
|
|
|
|
|
|
|
| |
Especially Windows 7 has problems if the peer does not send ID payloads
for host-to-host connections (tunnel and transport mode).
Fixes #319.
|
|
|
|
| |
Partially based on an old patch by Adrian-Ken Rueegsegger.
|
| |
|
|
|
|
|
|
| |
a3854d83 changed cleanup order. But we should remove CHILD_SAs first, as routes
for CHILD_SAs might get deleted while removing virtual IPs, resulting in
an error when a CHILD_SA tries to uninstall its route.
|
|
|
|
|
| |
We call ike_sa_t.reestablish() so the IKE_SA is only recreated if any
CHILD_SA requires it.
|
| |
|
|
|
|
|
|
| |
When a CHILD_SA is closed in IKEv1, if it is not being rekeyed and
closeaction has been set, we can now perform a restart or hold as is
currently done for IKEv2.
|
| |
|
|
|
|
| |
Saves up to another 0.5KB of memory per CHILD_SA.
|
|
|
|
|
| |
Not directly returning a linked list allows us to change the internals of
the CHILD_SA transparently.
|
|
|
|
| |
Eliminates another three lists, 0.5KB per IKE_SA.
|
|
|
|
| |
This saves about 1.5KB of memory per IKE_SA.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
If the responder not correctly send the correct protocol or SPI in the delete
response, we should remove the CHILD_SA regardless.
|
| |
|
|
|
|
| |
Depending on the failure, the protocol might not yet be set on the CHILD_SA.
|
| |
|
| |
|
|
|
|
|
|
|
| |
When we have a trap installed, but a CHILD_SA gets established for the same
config from the peer, we should reuse the same reqid. Otherwise we would have
two identical policies using different reqids, what we can't handle in our
kernel backend.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This new flag gives the kernel-interface a hint how it should priorize the
use of newly installed SAs during rekeying.
Consider the following rekey procedure in IKEv2:
Initiator --- Responder
I1 -------CREATE-------> R1
I2 <------CREATE--------
-------DELETE-------> R2
I3 <------DELETE--------
SAs are always handled as pairs, the following happens at the SA level:
* Initiator starts the exchange at I1
* Responder installs new SA pair at R1
* Initiator installs new SA pair at I2
* Responder removes old SA pair at R2
* Initiator removes old SA pair at I3
This makes sure SAs get installed/removed overlapping during rekeying. However,
to avoid any packet loss, it is crucial that the new outbound SA gets
activated at the correct position:
* as exchange initiator, in I2
* as exchange responder, in R2
This should guarantee that we don't use the new outbound SA before the peer
could install its corresponding inbound SA.
The new parameter allows the kernel backend to install the new SA with
appropriate priorities, i.e. it should:
* as exchange inititator, have the new outbound SA installed with higher
priority than the old SA
* as exchange responder, have the new outbound SA installed with lower
priority than the old SA
While we could split up the SA installation at the responder, this approach
has another advantage: it allows the kernel backend to switch SAs based on
other criteria, for example when receiving traffic on the new inbound SA.
|