pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-hnbgw/+/28281 )
Change subject: cosmetic: mgw_fsm: Fix typo in log
......................................................................
cosmetic: mgw_fsm: Fix typo in log
Change-Id: I80aa61a288ab37c51510af67c784498f5949fc50
---
M src/osmo-hnbgw/mgw_fsm.c
1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-hnbgw refs/changes/81/28281/1
diff --git a/src/osmo-hnbgw/mgw_fsm.c b/src/osmo-hnbgw/mgw_fsm.c
index 1974e33..5dd613f 100644
--- a/src/osmo-hnbgw/mgw_fsm.c
+++ b/src/osmo-hnbgw/mgw_fsm.c
@@ -672,7 +672,7 @@
initialized = true;
}
- /* The RTP stream negortiation usually begins with a RAB-AssignmentRequest and ends with an IU-Release, however
+ /* The RTP stream negotiation usually begins with a RAB-AssignmentRequest and ends with an IU-Release, however
* it may also be thet the MSC decides to release the RAB with a dedicated RAB-AssignmentRequest that contains
* a ReleaseList. In this case an FSM will already be present. */
if (map->mgw_fi) {
--
To view, visit https://gerrit.osmocom.org/c/osmo-hnbgw/+/28281
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-hnbgw
Gerrit-Branch: master
Gerrit-Change-Id: I80aa61a288ab37c51510af67c784498f5949fc50
Gerrit-Change-Number: 28281
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newchange
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-hnbgw/+/28282 )
Change subject: mgw_fsm: Change macro to not use local variables implicitly
......................................................................
mgw_fsm: Change macro to not use local variables implicitly
This is misleading for readers since it may access variables which may
be uninitialized or in a wrong state. Furthermore, we want to pass some
other variable name in a follow up patch.
This effectively allows the compiler to warn about uninitialized used of
a fi var in line 661.
Change-Id: Id694f51bb2918fd27da87b3f4a905727cd7f5de6
---
M src/osmo-hnbgw/mgw_fsm.c
1 file changed, 5 insertions(+), 5 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-hnbgw refs/changes/82/28282/1
diff --git a/src/osmo-hnbgw/mgw_fsm.c b/src/osmo-hnbgw/mgw_fsm.c
index 5dd613f..2b7484f 100644
--- a/src/osmo-hnbgw/mgw_fsm.c
+++ b/src/osmo-hnbgw/mgw_fsm.c
@@ -134,7 +134,7 @@
[MGW_ST_CRCX_MSC] = {.T = -1004 },
};
-#define mgw_fsm_state_chg(state) \
+#define mgw_fsm_state_chg(fi, state) \
osmo_tdef_fsm_inst_state_chg(fi, state, mgw_fsm_timeouts, mgw_fsm_T_defs, -1)
static void mgw_fsm_crcx_hnb_onenter(struct osmo_fsm_inst *fi, uint32_t prev_state)
@@ -206,7 +206,7 @@
return;
}
- mgw_fsm_state_chg(MGW_ST_ASSIGN);
+ mgw_fsm_state_chg(fi, MGW_ST_ASSIGN);
return;
default:
OSMO_ASSERT(false);
@@ -237,7 +237,7 @@
{
switch (event) {
case MGW_EV_RAB_ASS_RESP:
- mgw_fsm_state_chg(MGW_ST_MDCX_HNB);
+ mgw_fsm_state_chg(fi, MGW_ST_MDCX_HNB);
return;
default:
OSMO_ASSERT(false);
@@ -325,7 +325,7 @@
osmo_fsm_inst_state_chg(fi, MGW_ST_FAILURE, 0, 0);
return;
}
- mgw_fsm_state_chg(MGW_ST_CRCX_MSC);
+ mgw_fsm_state_chg(fi, MGW_ST_CRCX_MSC);
return;
default:
OSMO_ASSERT(false);
@@ -725,7 +725,7 @@
snprintf(fsm_name, sizeof(fsm_name), "mgw-fsm-%u-%u", map->rua_ctx_id, mgw_fsm_priv->rab_id);
fi = osmo_fsm_inst_alloc(&mgw_fsm, map, mgw_fsm_priv, LOGL_DEBUG, fsm_name);
map->mgw_fi = fi;
- mgw_fsm_state_chg(MGW_ST_CRCX_HNB);
+ mgw_fsm_state_chg(fi, MGW_ST_CRCX_HNB);
return 0;
error:
--
To view, visit https://gerrit.osmocom.org/c/osmo-hnbgw/+/28282
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-hnbgw
Gerrit-Branch: master
Gerrit-Change-Id: Id694f51bb2918fd27da87b3f4a905727cd7f5de6
Gerrit-Change-Number: 28282
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-MessageType: newchange
pespin has uploaded a new patch set (#2). ( https://gerrit.osmocom.org/c/osmo-hnbgw/+/28279 )
Change subject: mgw_fsm: Mark structs as static const
......................................................................
mgw_fsm: Mark structs as static const
Change-Id: Ie62f28587c08296429c0dabda7b6add67ffa010c
---
M src/osmo-hnbgw/mgw_fsm.c
1 file changed, 2 insertions(+), 2 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-hnbgw refs/changes/79/28279/2
--
To view, visit https://gerrit.osmocom.org/c/osmo-hnbgw/+/28279
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-hnbgw
Gerrit-Branch: master
Gerrit-Change-Id: Ie62f28587c08296429c0dabda7b6add67ffa010c
Gerrit-Change-Number: 28279
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Gerrit-CC: Jenkins Builder
Gerrit-MessageType: newpatchset
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/28277 )
Change subject: pySim-shell: set default ADM key reference
......................................................................
pySim-shell: set default ADM key reference
ETSI TS 102 221, Table 9.3 specifies 0x0A as default key reference for
ADM1. Lets make sure pySim-shell uses this key-reference if the card is
a generic UICC.
Change-Id: I8a96244269dc6619f39a5369502b15b83740ee45
---
M pySim-shell.py
1 file changed, 10 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/77/28277/1
diff --git a/pySim-shell.py b/pySim-shell.py
index f498dea..e52c4ef 100755
--- a/pySim-shell.py
+++ b/pySim-shell.py
@@ -83,16 +83,26 @@
print("Card not readable!")
return None, None
+ generic_card = False
card = card_detect("auto", scc)
if card is None:
print("Warning: Could not detect card type - assuming a generic card type...")
card = SimCard(scc)
+ generic_card = True
profile = CardProfile.pick(scc)
if profile is None:
print("Unsupported card type!")
return None, card
+ # ETSI TS 102 221, Table 9.3 specifies a default for the PIN key
+ # references, however card manufactures may still decide to pick an
+ # arbitrary key reference. In case we run on a generic card class that is
+ # detected as an UICC, we will pick the key reference that is officially
+ # specified.
+ if generic_card and isinstance(profile, CardProfileUICC):
+ card._adm_chv_num = 0x0A
+
print("Info: Card is of type: %s" % str(profile))
# FIXME: This shouln't be here, the profile should add the applications,
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/28277
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I8a96244269dc6619f39a5369502b15b83740ee45
Gerrit-Change-Number: 28277
Gerrit-PatchSet: 1
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-MessageType: newchange
dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/28278 )
Change subject: cards: populate ADM1 key reference member
......................................................................
cards: populate ADM1 key reference member
In class SimCard, we speficy the key reference for ADM1 as 0x04. in the
UsimCard class, which inherets from SimCard nothing is specified, even
though ETSI TS 102 221 specifies 0x0A as key reference. Lets set the
member in UsimCard accordingly to be closer to the spec.
Note: For the moment this is a cosmetic fix, it does not change the
behaviour since all card classes derived from UsimCard set the key
reference properly.
Change-Id: I96af395b1832f4462a6043cca3bb3812fddac612
---
M pySim/cards.py
1 file changed, 4 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/78/28278/1
diff --git a/pySim/cards.py b/pySim/cards.py
index b186044..71ddaa2 100644
--- a/pySim/cards.py
+++ b/pySim/cards.py
@@ -347,6 +347,10 @@
def __init__(self, ssc):
super(UsimCard, self).__init__(ssc)
+ print("NOW")
+
+ # See also: ETSI TS 102 221, Table 9.3
+ self._adm_chv_num = 0xA0
def read_ehplmn(self):
(res, sw) = self._scc.read_binary(EF_USIM_ADF_map['EHPLMN'])
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/28278
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I96af395b1832f4462a6043cca3bb3812fddac612
Gerrit-Change-Number: 28278
Gerrit-PatchSet: 1
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-MessageType: newchange