09/06/2019 6:55 PM
post119882
|
I am trying to create a UDPv6 connection using ipsec. Is there more infrastructure I need to start up for ipsec other
then the network stack (io-pkt-v6-hc)? Do I need to add any specific options to startup of the stack?
I am getting errno 22 from the setsocketopt() call with the following code
const char* outPolicyText = "out ipsec esp/transport//require";
ipsec_policy_t outPolicy = ipsec_set_policy(outPolicyText, strlen(outPolicyText));
if (setsockopt(mySocketHandle, IPPROTO_IP, IP_IPSEC_POLICY, outPolicy, ipsec_get_policylen(outPolicy))) {
zError("setsockopt Error for outPolicy %d %s", errno, ipsec_strerror());
} else {
zError("setsockopt Success for outPolicy");
}
free(outPolicy);
I get errno 247 from the socket() call with the following call
int pfSocket = socket(PF_KEY, SOCK_RAW, PF_KEY_V2);
I am running io-pkt-v6-hc on 6.5.0SP1. I can switch to 6.6 or 7.0 if that makes a difference.
Thanks
|
|
|