aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Eversberg <jolly@eversberg.eu>2013-07-10 08:58:03 +0200
committerAndreas Eversberg <jolly@eversberg.eu>2013-07-29 12:40:00 +0200
commitc69099b3049a2c50a9085f7416a4e6aedf3da23d (patch)
tree0a27a8fc75644c05caf4428dab96bdf83fa8f443
parent4402238ab72fff8ff52efa6668f1e6beff299dd7 (diff)
Fix: Handle CM service request on already secured channel correctly
A CM service request must be acknowledged also, when encryption is already enabled. Without encryption enabled, the security status is GSM_SECURITY_NOTAVAIL, which causes a CM service acknowledge. On initial CM service request, the security status is GSM_SECURITY_SUCCEED, if encryption is enabled. This will not lead to an acknowledge, because the cyphering command implies an acknowlege. An additional CM service request requires an acknowledge, so I added a new security status: GSM_SECURITY_ALREADY
-rw-r--r--openbsc/src/libmsc/gsm_04_08.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/openbsc/src/libmsc/gsm_04_08.c b/openbsc/src/libmsc/gsm_04_08.c
index 93cbae22b..1a104fec7 100644
--- a/openbsc/src/libmsc/gsm_04_08.c
+++ b/openbsc/src/libmsc/gsm_04_08.c
@@ -304,6 +304,11 @@ static int _gsm0408_authorize_sec_cb(unsigned int hooknum, unsigned int event,
release_loc_updating_req(conn);
break;
+ case GSM_SECURITY_ALREADY:
+ LOGP(DMM, LOGL_ERROR, "We don't expect LOCATION "
+ "UPDATING after CM SERVICE REQUEST\n");
+ /* fall through */
+
case GSM_SECURITY_NOAVAIL:
case GSM_SECURITY_SUCCEEDED:
/* We're all good */