libosmogsm  0.10.2
Osmocom GSM library
milenage.h
Go to the documentation of this file.
1 
4 /*
5  * Copyright (c) 2006-2007 <j@w1.fi>
6  *
7  * This program is free software; you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License version 2 as
9  * published by the Free Software Foundation.
10  *
11  * Alternatively, this software may be distributed under the terms of BSD
12  * license.
13  *
14  * See README and COPYING for more details.
15  */
16 
17 #pragma once
18 
19 void milenage_generate(const u8 *opc, const u8 *amf, const u8 *k,
20  const u8 *sqn, const u8 *_rand, u8 *autn, u8 *ik,
21  u8 *ck, u8 *res, size_t *res_len);
22 int milenage_auts(const u8 *opc, const u8 *k, const u8 *_rand, const u8 *auts,
23  u8 *sqn);
24 int gsm_milenage(const u8 *opc, const u8 *k, const u8 *_rand, u8 *sres,
25  u8 *kc);
26 int milenage_check(const u8 *opc, const u8 *k, const u8 *sqn, const u8 *_rand,
27  const u8 *autn, u8 *ik, u8 *ck, u8 *res, size_t *res_len,
28  u8 *auts);
29 int milenage_f1(const u8 *opc, const u8 *k, const u8 *_rand,
30  const u8 *sqn, const u8 *amf, u8 *mac_a, u8 *mac_s);
31 int milenage_f2345(const u8 *opc, const u8 *k, const u8 *_rand,
32  u8 *res, u8 *ck, u8 *ik, u8 *ak, u8 *akstar);
33 
34 int milenage_opc_gen(u8 *opc, const u8 *k, const u8 *op);
int milenage_opc_gen(u8 *opc, const u8 *k, const u8 *op)
Definition: milenage.c:332
int milenage_f1(const u8 *opc, const u8 *k, const u8 *_rand, const u8 *sqn, const u8 *amf, u8 *mac_a, u8 *mac_s)
milenage_f1 - Milenage f1 and f1* algorithms : OPc = 128-bit value derived from OP and K : K = 128-bi...
Definition: milenage.c:43
void milenage_generate(const u8 *opc, const u8 *amf, const u8 *k, const u8 *sqn, const u8 *_rand, u8 *autn, u8 *ik, u8 *ck, u8 *res, size_t *res_len)
milenage_generate - Generate AKA AUTN,IK,CK,RES : OPc = 128-bit operator variant algorithm configurat...
Definition: milenage.c:180
uint8_t u8
Definition: common.h:18
int milenage_f2345(const u8 *opc, const u8 *k, const u8 *_rand, u8 *res, u8 *ck, u8 *ik, u8 *ak, u8 *akstar)
milenage_f2345 - Milenage f2, f3, f4, f5, f5* algorithms : OPc = 128-bit value derived from OP and K ...
Definition: milenage.c:95
int milenage_check(const u8 *opc, const u8 *k, const u8 *sqn, const u8 *_rand, const u8 *autn, u8 *ik, u8 *ck, u8 *res, size_t *res_len, u8 *auts)
milenage_generate - Generate AKA AUTN,IK,CK,RES : OPc = 128-bit operator variant algorithm configurat...
Definition: milenage.c:277
uint8_t sres[4]
Definition: gsm_04_08.h:91
int milenage_auts(const u8 *opc, const u8 *k, const u8 *_rand, const u8 *auts, u8 *sqn)
milenage_auts - Milenage AUTS validation : OPc = 128-bit operator variant algorithm configuration fie...
Definition: milenage.c:215
int gsm_milenage(const u8 *opc, const u8 *k, const u8 *_rand, u8 *sres, u8 *kc)
gsm_milenage - Generate GSM-Milenage (3GPP TS 55.205) authentication triplet : OPc = 128-bit operator...
Definition: milenage.c:242