[Openswan dev] ip_hdr discrepancies
Paul Wouters
paul at xelerance.com
Fri Dec 19 14:11:26 EST 2008
On Fri, 19 Dec 2008, Sybille Ebert wrote:
> I have compiled OpenSwan 2.6.19 on CentOS 5.2 kernel 2.6.18-92.1.22.el5.
>
> In order to make it work, I had to comment out the following in
> ipsec_kversion.h:
>
> #if !(defined(CONFIG_SLE_VERSION) && defined(CONFIG_SLE_SP) &&
> COINFIG_SLE_VERSION == 10 && CONFIG_SLE_SP >=2)
> # define ip_hdr(skb) ((skb)->nh.iph)
> #endif
>
> (Note COINFIG instead of CONFIG. Redhat backport-avoiding #if above this
> works fine, though.)
Yeah, that was fixed and you can see it in openswan 2.6.20rc1
> The packet's destination is within rightsubnet. Eliminating any other
> causes (routing, firewalling, NAT, setups), I am suspecting that this
> could be due to conflict in ip_hdr definition. RedHat clearly uses a
> different ip_hdr:
>
> In include/linux/ip.h:
> static inline struct iphdr *ip_hdr(const struct sk_buff *skb) {
> return (struct iphdr *)skb_network_header(skb);
> }
>
> In include/linux/skbuff.h:
> static inline unsigned char *skb_network_header(const struct sk_buff *skb) {
> return skb->nh.raw;
> }
>
>
> Any advice?
Please try 2.6.20rc1 (its in openswan/testing on the ftp site)
Paul
More information about the Dev
mailing list