Skip to content

Commit b8b549e

Browse files
committed
xfrm: Fix ESN sequence number handling for IPsec GSO packets.
When IPsec offloading was introduced, we accidentally incremented the sequence number counter on the xfrm_state by one packet too much in the ESN case. This leads to a sequence number gap of one packet after each GSO packet. Fix this by setting the sequence number to the correct value. Fixes: d7dbefc ("xfrm: Add xfrm_replay_overflow functions for offloading") Signed-off-by: Steffen Klassert <[email protected]>
1 parent 013cb81 commit b8b549e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

net/xfrm/xfrm_replay.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -660,7 +660,7 @@ static int xfrm_replay_overflow_offload_esn(struct xfrm_state *x, struct sk_buff
660660
} else {
661661
XFRM_SKB_CB(skb)->seq.output.low = oseq + 1;
662662
XFRM_SKB_CB(skb)->seq.output.hi = oseq_hi;
663-
xo->seq.low = oseq = oseq + 1;
663+
xo->seq.low = oseq + 1;
664664
xo->seq.hi = oseq_hi;
665665
oseq += skb_shinfo(skb)->gso_segs;
666666
}

0 commit comments

Comments
 (0)