ip_hdr
ipr->ip_hdr = (struct ip *)((uintptr_t)eh + sizeof(*eh));
bcopy(ipq->ipq_hdr, ipr->ip_hdr, sizeof(*ipr->ip_hdr));
ipr->ip_hdr->ip_hl = sizeof(*ipr->ip_hdr) >> 2;
ipr->ip_hdr->ip_len = htons(n);
ipr->ip_hdr->ip_sum = 0;
ipr->ip_hdr->ip_sum = in_cksum(ipr->ip_hdr, sizeof(*ipr->ip_hdr));
ptr = (char *)((uintptr_t)ipr->ip_hdr + sizeof(*ipr->ip_hdr));
struct ip *ip_hdr;
struct ip ip_hdr;
m_copydata(m, 0, sizeof(ip_hdr), (char *)&ip_hdr);
hlen = ip_hdr.ip_hl << 2;
lnk = FindLinkIn(la, sm->ip_hdr->ip_src, sm->ip_hdr->ip_dst,
redir = FindOriginalAddress(la,sm->ip_hdr->ip_dst);
lnk = FindLinkIn(la, sm->ip_hdr->ip_src, sm->ip_hdr->ip_dst,
ip->ip_dst = sm->ip_hdr->ip_src;
memcpy(sm->ip_hdr, ip, ip_size);
sm->ip_hdr = pip;
g_addr = sm->ip_hdr->ip_dst;
g_addr = sm->ip_hdr->ip_src;
if (G_Addr->g_addr.s_addr != sm->ip_hdr->ip_src.s_addr) {
assoc->l_addr = sm->ip_hdr->ip_src;
if (AddSctpAssocLocal(la, assoc, sm->ip_hdr->ip_dst)) /* DB clash */
assoc->a_addr = sm->ip_hdr->ip_dst;
if (AddSctpAssocLocal(la, assoc, sm->ip_hdr->ip_src)) /* DB clash */
if (AddSctpAssocLocal(la, assoc, sm->ip_hdr->ip_src)) { /* DB clash */
assoc->l_addr = sm->ip_hdr->ip_src; // Only if not set in Init! *
DifferentialChecksum(&(msg.ip_hdr->ip_sum),
&(assoc->l_addr), &(msg.ip_hdr->ip_dst), 2);
msg.ip_hdr->ip_dst = assoc->l_addr; /* change dst address to local address*/
DifferentialChecksum(&(msg.ip_hdr->ip_sum),
&(assoc->a_addr), &(msg.ip_hdr->ip_src), 2);
msg.ip_hdr->ip_src = assoc->a_addr; /* change src to alias addr*/
if (ntohs(sm->ip_hdr->ip_len) < ip_size) { /* short packet, cannot send error cause */
ip->ip_v = sm->ip_hdr->ip_v;
ip->ip_id = sm->ip_hdr->ip_id;
ip->ip_src = (direction == SN_TO_LOCAL) ? sm->ip_hdr->ip_src : assoc->a_addr;
ip->ip_dst = (direction == SN_TO_LOCAL) ? assoc->l_addr : sm->ip_hdr->ip_dst;
ip->ip_src = sm->ip_hdr->ip_dst;
struct ip *ip_hdr; /**< pointer to ip packet header */
struct ip ip_hdr;
ip1 = &ip_hdr;
struct ip ip_hdr;
ip = &ip_hdr;
struct ip ip_hdr;
m_copydata(m, 0, sizeof(ip_hdr), (char *)&ip_hdr);
if (ipsec4_in_reject1(m, &ip_hdr, NULL) != 0) {
return (ipsec4_common_output(NULL /* XXXKIB */, m, NULL, &ip_hdr,