Commit Graph

65 Commits

Author SHA1 Message Date
Harald Welte 72cf09e620 Add support for reading misc. MILENAGE parameters
We now can read
* IDX, MAX_DELTA and AGE_LIMIT parameters
* whether or not SQN, age and max delta are enforced
* SEQ array
* Authentication Counter
2017-08-16 21:14:44 +02:00
Harald Welte b7ec495145 EF_OPC is actually specified in ADF_USIM, so let's select it there 2017-08-16 21:14:44 +02:00
Harald Welte dc45c05b15 Migration to python 'card' from Benoit Michau
There are quite complete python utilities already out there as part
of Benoit Micuhau's 'card' python library. They support plenty of
SIM, UICC and USIM related bits.  Let's use them rather than re-
inventing the wheel here.
2017-08-16 21:14:44 +02:00
Harald Welte 4086758393 Import slightly modified version of mitshell/card
the modifications can be found in
and I wouuld hope that once Benoit has merged this we can remove the
local copy here and simply rely on pypi pulling it from the repo.
2017-08-16 21:14:44 +02:00
Harald Welte 5666cd6818 Unconditionally print ICCID and IMSI
This can help a lot in identifying the cards and in giving context in
case a user copy+pastes the output.  Let's always read those values.
2017-08-16 21:14:44 +02:00
Harald Welte 6d5127c89a add list_to_int() utility function to convert byte-lists to integers 2017-08-16 21:14:44 +02:00
Harald Welte e786eb1310 add .gitignore file 2017-08-16 21:13:37 +02:00
Harald Welte 78b18df47c remove unused 'adm1' argument from many functions
The main program performs ADM1 authentication before using any
of the sysmo_usim_{read,write}* functions, so passing adm1 as
argument to them is just an unused argument that we can remove
2017-08-16 10:04:39 +02:00
Philipp Maier 55bb02bc62 Add ICCID reading/programming feature
sysmo-usim-tool still can't read or program the ICCID. This patch
adds enables reading and writing EF.ICCID
2017-03-21 00:30:34 +01:00
Philipp Maier 14aaab262e auth: prevent unintential card lock down
If the user submints a wrong ADM1 key with the commandline, the
authentication will fail. However, by the output of the program
it mey not be clear to the user that the reason for the failure
was a wrong ADM1 key. The user might try the same command with
the same parameters a few time and lock down the card.

This commit fixes that by failing gracefully with a very clear
error message. Furthermore, if a decreased authentication counter
is detected, no further authentication attempts will be made
until the user supplies the option -f (--force).
2017-03-17 16:43:35 +01:00
Neels Hofmeyr a73acbc8e4 cosmetic fix: sysmo_usim_show_milenage_params() was defined twice 2017-03-05 01:01:34 +01:00
Neels Hofmeyr 4d144983c3 cosmetic: typo and slash to clarify OP or OPC 2017-03-05 01:01:03 +01:00
Neels Hofmeyr 8b8ccfcba4 add cmds to read/write KI 2017-03-05 01:00:13 +01:00
Philipp Maier 2c11efcdf6 cosmetic: Fixing typo in log output 2017-02-23 15:33:34 +01:00
Philipp Maier 4f2e60436b sysmo-usim-tool: Add a tool for sysmosom specific tasks
This commit adds a tool that is intended to be used with sysmo-usim
only if some of the highly propritary parameters, which the regular
pysim can not handle, need to be configured.
2017-02-23 14:47:38 +01:00