![]() |
A52HackTool 1.3.0
Turnkey & easy to use tool for cracking the GSM A5/2 cipher
|
Specification of last attack phase on A5/2: keysetup reversal. More...
#include "const_A52.h"
Go to the source code of this file.
Functions | |
int | reverseKeysetup (const byte R1[R1_BITS], const byte R2[R2_BITS], const byte R3[R3_BITS], const byte R4[R4_BITS], const byte frameId[FRAMEID_BITS], byte secretKey[SECRETKEY_BITS]) |
Performs the reversal of the keysetup, retrieving the Secret Key from the LFSRs state after keysetup. | |
int | keysetup_reverse_test () |
Autotests the reversal of the keysetup on a verified set of problem/solution. |
Specification of last attack phase on A5/2: keysetup reversal.
int keysetup_reverse_test | ( | ) |
Autotests the reversal of the keysetup on a verified set of problem/solution.
References DEBUG, DUMP_CHAR_VECTOR, FRAMEID_BITS, R1, R1_BITS, R2, R2_BITS, R3, R3_BITS, R4, R4_BITS, reverseKeysetup(), and SECRETKEY_BITS.
Referenced by main().
int reverseKeysetup | ( | const byte | R1[R1_BITS], |
const byte | R2[R2_BITS], | ||
const byte | R3[R3_BITS], | ||
const byte | R4[R4_BITS], | ||
const byte | frameId[FRAMEID_BITS], | ||
byte | secretKey[SECRETKEY_BITS] | ||
) |
Performs the reversal of the keysetup, retrieving the Secret Key from the LFSRs state after keysetup.
[in] | R1 | Status of register R1 after keysetup |
[in] | R2 | Status of register R2 after keysetup |
[in] | R3 | Status of register R3 after keysetup |
[in] | R4 | Status of register R4 after keysetup |
[in] | frameId | Publicly known Frame Id |
[out] | secretKey | Recovered secret key if the attack succeeded, all zeros otherwise |
References DEBUG, FRAMEID_BITS, keysetup_reverse_clockRegs(), R1, keysetup_reverse_LFSRSet_t::R1, R1_BITS, R2, keysetup_reverse_LFSRSet_t::R2, R2_BITS, R3, keysetup_reverse_LFSRSet_t::R3, R3_BITS, R4, keysetup_reverse_LFSRSet_t::R4, R4_BITS, REGS_BITS, SECRETKEY_BITS, and XOR_CHARARRAYS.
Referenced by attack_decipherSecretKey(), and keysetup_reverse_test().