<div dir="ltr">Ah ok.  That makes sense, thanks Martin.<div><br></div><div>/Ryan</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Mar 6, 2015 at 8:22 AM, Martin Willi <span dir="ltr"><<a href="mailto:martin@strongswan.org" target="_blank">martin@strongswan.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Ryan,<br>
<span class=""><br>
> The 3rd to last argument to "add_sa" is the "update" flag, but the kernel<br>
> interface specifies this as the "inbound" flag.<br>
<br>
</span>The logic is actually correct, because "inbound" SAs must be installed<br>
as "update" operation in most backends. For inbound SAs, an SPI has been<br>
previously allocated, and the Netlink and PF_KEY interfaces expect an<br>
"update" instead of an "add" operation for that SA.<br>
<br>
I agree that it makes sense to just pass the inbound flag and let the<br>
kernel backend decide what is required to do. This has been changed some<br>
time ago in the master branch with [1].<br>
<br>
Regards<br>
Martin<br>
<br>
[1]<a href="http://git.strongswan.org/?p=strongswan.git;a=commitdiff;h=698ed656" target="_blank">http://git.strongswan.org/?p=strongswan.git;a=commitdiff;h=698ed656</a><br>
<br>
</blockquote></div><br></div>