During the attach procedure , UE sends its network capabilities (algo id) .
Algo ids sent by UE to MME in attach request message known as NULL ciphering algorithm, snow 3G and AES.
Algorithm distinguisher is a different value altogether and irrespective of "Algo ID" , these values are defined as following:
NAS-enc-algo - 0x01
NAS-int-algo - 0x02
RRC-enc-algo - 0x03
RRC-int-algo - 0x04
UE-enc-algo - 0x05
MME or UE uses key derivation function to generate KeyNASint, KeyNASenc keys.
To generate NAS integrity key KnasInt = KDF(Kasme, algo id, algo distinguisher ) is used where algo id will be the one selected by MME while algo distinguisher value will be 0x02 . Similarly Knasenc key is generated.