xfrm: Use the user specified truncation length in ESP and AH
Instead of using the hardcoded truncation for authentication algorithms, use the truncation length specified on xfrm_state. Signed-off-by: Martin Willi <martin@strongswan.org> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
committed by
David S. Miller
parent
4447bb33f0
commit
8f8a088c21
@@ -444,7 +444,7 @@ static int ah_init_state(struct xfrm_state *x)
|
||||
}
|
||||
|
||||
ahp->icv_full_len = aalg_desc->uinfo.auth.icv_fullbits/8;
|
||||
ahp->icv_trunc_len = aalg_desc->uinfo.auth.icv_truncbits/8;
|
||||
ahp->icv_trunc_len = x->aalg->alg_trunc_len/8;
|
||||
|
||||
BUG_ON(ahp->icv_trunc_len > MAX_AH_AUTH_LEN);
|
||||
|
||||
|
Reference in New Issue
Block a user