[PATCH] libosmocore[master]: osmo-auc-gen: umts: use default of ind_bitlen = 5 instead of 0

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Neels Hofmeyr gerrit-no-reply at lists.osmocom.org
Sat Aug 26 21:33:10 UTC 2017


Review at  https://gerrit.osmocom.org/3699

osmo-auc-gen: umts: use default of ind_bitlen = 5 instead of 0

Most USIM out there seem to use IND-length = 5 bits, so do sysmousim-sjs1.
Currently from initialization we are using an IND length of zero in
osmo-auc-gen, which produces confusing SQN results after AUTS:

Where want SQN to be incremented to the next IND array, usually +32, an IND-len
of 0 makes for only +1.

As result, the osmo-auc-gen_test.sh produces SQN 32 instead of 24 after
receiving SQN.MS = 23 from AUTS: adjust test expectations.

Related: OS#2465
Change-Id: I9fcc11fa2b5816302dcc6b72249b1ee40d5a61f5
---
M tests/osmo-auc-gen/osmo-auc-gen_test.ok
M utils/osmo-auc-gen.c
2 files changed, 3 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/99/3699/1

diff --git a/tests/osmo-auc-gen/osmo-auc-gen_test.ok b/tests/osmo-auc-gen/osmo-auc-gen_test.ok
index 6a78886..a1d06f0 100644
--- a/tests/osmo-auc-gen/osmo-auc-gen_test.ok
+++ b/tests/osmo-auc-gen/osmo-auc-gen_test.ok
@@ -89,10 +89,10 @@
 This is FREE SOFTWARE with ABSOLUTELY NO WARRANTY
 
 RAND:	39fa2f4e3d523d8619a73b4f65c3e14d
-AUTN:	8704f5ba55eb0000d7fc4f7f19cfc180
+AUTN:	8704f5ba55d30000541dde77ea5b1d8c
 IK:	27497388b6cb044648f396aa155b95ef
 CK:	f64735036e5871319c679f4742a75ea1
 RES:	e229c19e791f2e41
 SRES:	9b36efdf
 Kc:	059a4f668f6fbe39
-SQN:	24
+SQN:	32
diff --git a/utils/osmo-auc-gen.c b/utils/osmo-auc-gen.c
index 87960ae..4e07fa7 100644
--- a/utils/osmo-auc-gen.c
+++ b/utils/osmo-auc-gen.c
@@ -138,6 +138,7 @@
 			break;
 		case '3':
 			test_aud.type = OSMO_AUTH_TYPE_UMTS;
+			test_aud.u.umts.ind_bitlen = 5;
 			break;
 		case 'a':
 			rc = osmo_auth_alg_parse(optarg);

-- 
To view, visit https://gerrit.osmocom.org/3699
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9fcc11fa2b5816302dcc6b72249b1ee40d5a61f5
Gerrit-PatchSet: 1
Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Owner: Neels Hofmeyr <nhofmeyr at sysmocom.de>



More information about the gerrit-log mailing list