Commit 838eed90 authored by Masahide Nakamura's avatar Masahide Nakamura Committed by Hideaki Yoshifuji

[IPV4] XFRM: decode icmp session.

Signed-off-by: default avatarMasahide Nakamura <nakam@linux-ipv6.org>
Signed-off-by: default avatarHideaki YOSHIFUJI <yoshfuji@linux-ipv6.org>
parent 9c7e9d2d
...@@ -183,6 +183,15 @@ _decode_session4(struct sk_buff *skb, struct flowi *fl) ...@@ -183,6 +183,15 @@ _decode_session4(struct sk_buff *skb, struct flowi *fl)
} }
break; break;
case IPPROTO_ICMP:
if (pskb_may_pull(skb, xprth + 2 - skb->data)) {
u8 *icmp = xprth;
fl->fl_icmp_type = icmp[0];
fl->fl_icmp_code = icmp[1];
}
break;
case IPPROTO_ESP: case IPPROTO_ESP:
if (pskb_may_pull(skb, xprth + 4 - skb->data)) { if (pskb_may_pull(skb, xprth + 4 - skb->data)) {
u32 *ehdr = (u32 *)xprth; u32 *ehdr = (u32 *)xprth;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment