]> err.no Git - linux-2.6/commitdiff
[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 aed537fa2c88507440c68daf87076c6a56332cb6..e16d8b42b953bfd93de8be94b787353dfcc9f192 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 09590f3560866758e0db00ff43580ca7b9ab798d..bf88c620a954466de0e579505ed19e1a8f69b070 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 84963749ab77abdba516b879470b829e96f3bd7a..2b55b9a97aea5703b3e575e82e019a80b590da53 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 7b5b94f13902cbf4ec2ad8ce229ff838ba7fbe0a..aa7f100dab35e74a828531359458b5ec2eaf29b9 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));