[IPSEC]: Sync series - fast path
authorJamal Hadi Salim <hadi@cyberus.ca>
Tue, 21 Mar 2006 03:15:29 +0000 (19:15 -0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 21 Mar 2006 03:15:29 +0000 (19:15 -0800)
Fast path sequence updates that will generate ipsec async
events

Signed-off-by: Jamal Hadi Salim <hadi@cyberus.ca>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/ah4.c
net/ipv4/esp4.c
net/ipv6/ah6.c
net/ipv6/esp6.c

index aed537f..e16d8b4 100644 (file)
@@ -97,6 +97,7 @@ static int ah_output(struct xfrm_state *x, struct sk_buff *skb)
        ah->reserved = 0;
        ah->spi = x->id.spi;
        ah->seq_no = htonl(++x->replay.oseq);
+       xfrm_aevent_doreplay(x);
        ahp->icv(ahp, skb, ah->auth_data);
 
        top_iph->tos = iph->tos;
index 09590f3..bf88c62 100644 (file)
@@ -90,6 +90,7 @@ static int esp_output(struct xfrm_state *x, struct sk_buff *skb)
 
        esph->spi = x->id.spi;
        esph->seq_no = htonl(++x->replay.oseq);
+       xfrm_aevent_doreplay(x);
 
        if (esp->conf.ivlen)
                crypto_cipher_set_iv(tfm, esp->conf.ivec, crypto_tfm_alg_ivsize(tfm));
index 8496374..2b55b9a 100644 (file)
@@ -213,6 +213,7 @@ static int ah6_output(struct xfrm_state *x, struct sk_buff *skb)
        ah->reserved = 0;
        ah->spi = x->id.spi;
        ah->seq_no = htonl(++x->replay.oseq);
+       xfrm_aevent_doreplay(x);
        ahp->icv(ahp, skb, ah->auth_data);
 
        err = 0;
index 7b5b94f..aa7f100 100644 (file)
@@ -94,6 +94,7 @@ static int esp6_output(struct xfrm_state *x, struct sk_buff *skb)
 
        esph->spi = x->id.spi;
        esph->seq_no = htonl(++x->replay.oseq);
+       xfrm_aevent_doreplay(x);
 
        if (esp->conf.ivlen)
                crypto_cipher_set_iv(tfm, esp->conf.ivec, crypto_tfm_alg_ivsize(tfm));