auth: Fix XOR algorithm

Thanks to the person on the ml that pointed this bug. Sorry I
don't remember who (it was a while ago and somehow didn't got
fixed at that time)

Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
This commit is contained in:
Sylvain Munaut 2010-09-21 19:03:09 +02:00
parent af8a010448
commit 0230b34dc5
1 changed files with 1 additions and 1 deletions

View File

@ -44,7 +44,7 @@ _use_xor(struct gsm_auth_info *ainfo, struct gsm_auth_tuple *atuple)
for (i=0; i<4; i++)
atuple->sres[i] = atuple->rand[i] ^ ainfo->a3a8_ki[i];
for (i=8; i<12; i++)
for (i=4; i<12; i++)
atuple->kc[i-4] = atuple->rand[i] ^ ainfo->a3a8_ki[i];
return 0;