summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2018-02-17 20:57:34 +0100
committerHarald Welte <laforge@gnumonks.org>2018-02-17 20:57:34 +0100
commitacbf2b701504f7f41857f6a2c529f37d6bf2a12c (patch)
tree881def58a17b525b25dc0f85f12f2bc57513dfca
parentb5222af24d2226f3878c3b91c47e562da1da17d3 (diff)
gsup: Add PDP/APN related definitionslaforge/sgsn
-rw-r--r--library/GSUP_Types.ttcn50
1 files changed, 48 insertions, 2 deletions
diff --git a/library/GSUP_Types.ttcn b/library/GSUP_Types.ttcn
index 0a21999..5e6b20a 100644
--- a/library/GSUP_Types.ttcn
+++ b/library/GSUP_Types.ttcn
@@ -105,7 +105,12 @@ type record GSUP_IE {
msisdn, tag = OSMO_GSUP_MSISDN_IE;
hlr_number, tag = OSMO_GSUP_HLR_NUMBER_IE;
cn_domain, tag = OSMO_GSUP_CN_DOMAIN_IE;
- charg_char, tag = OSMO_GSUP_CHARG_CHAR_IE)"
+ pdp_info, tag = OSMO_GSUP_PDP_INFO_IE;
+ apn, tag = OSMO_GSUP_ACCESS_POINT_NAME_IE;
+ pdp_qos, tag = OSMO_GSUP_PDP_QOS_IE;
+ pdp_type, tag = OSMO_GSUP_PDP_TYPE_IE;
+ charg_char, tag = OSMO_GSUP_CHARG_CHAR_IE;
+ )"
};
type record of GSUP_IE GSUP_IEs;
@@ -116,7 +121,6 @@ type union GSUP_IeValue {
GSUP_CancelType cancel_type,
//boolean pdp_info_compl,
//boolean freeze_ptmsi,
- GSUP_IEs pdp_info,
GSUP_IEs auth_tuple,
octetstring auts,
octetstring rand,
@@ -129,6 +133,11 @@ type union GSUP_IeValue {
GSUP_MSISDN msisdn,
octetstring hlr_number,
GSUP_CnDomain cn_domain,
+ /* PDP context + nested IEs */
+ GSUP_IEs pdp_info,
+ octetstring apn,
+ octetstring pdp_qos,
+ OCT2 pdp_type,
octetstring charg_char
};
@@ -217,6 +226,35 @@ template GSUP_IE ts_GSUP_IE_AuthTuple2G3G(octetstring rand, octetstring sres,
}
}
+template GSUP_IE ts_GSUP_IE_PdpInfo(octetstring apn, octetstring pdp_type, octetstring pdp_qos) := {
+ tag := OSMO_GSUP_PDP_INFO_IE,
+ len := 0, /* overwritten */
+ val := {
+ pdp_info := {
+ valueof(ts_GSUP_IE_APN(apn)),
+ valueof(ts_GSUP_IE_PDP_TYPE(pdp_type)),
+ valueof(ts_GSUP_IE_PDP_QOS(pdp_qos))
+ }
+ }
+}
+
+template (value) GSUP_IE ts_GSUP_IE_PDP_TYPE(OCT2 pdp_type) := {
+ tag := OSMO_GSUP_PDP_TYPE_IE,
+ len := 0,
+ val := {
+ pdp_type := pdp_type
+ }
+}
+
+template (value) GSUP_IE ts_GSUP_IE_PDP_QOS(octetstring pdp_qos) := {
+ tag := OSMO_GSUP_PDP_QOS_IE,
+ len := 0,
+ val := {
+ pdp_qos := pdp_qos
+ }
+}
+
+
template GSUP_PDU tr_GSUP(template GSUP_MessageType msgt := ?, template GSUP_IEs ies := *) := {
msg_type := msgt,
ies := ies
@@ -428,6 +466,14 @@ template (value) GSUP_IE ts_GSUP_IE_RES(octetstring res) := {
}
}
+template (value) GSUP_IE ts_GSUP_IE_APN(octetstring apn) := {
+ tag := OSMO_GSUP_ACCESS_POINT_NAME_IE,
+ len := 0, /* overwritten */
+ val := {
+ apn := apn
+ }
+}
+
} with { encode "RAW"; variant "FIELDORDER(msb)" }