forked from acouzens/open5gs
Introduce Cancel Location and Insert Subscriber Data features to HSS. (#1744)
* Introduce Cancel Location and Insert Subscriber Data features to HSS. * HSS database will keep track of last known MME and Update Time * Purged UE flag is established in HSS for future PUR handling * HSS Thread will connect to database and watch change stream mongoDB must be configured with a Replica Set to use this * HSS will send IDR if subscription data changes * HSS will send CLR to old MME if MME host or realm changes * Function created to allow ULA and IDR to generate Subscription-Data AVP * MME Hostname and Realm shown in WebUI * Resolve freeDiameter errors During a ULR, if database does not contain a last known MME, a CLR is being sent to a Null destination. This will ensure that a destination is available in the database before sending the CLR. * Removed change streams. Added PUR handling. * newline needed at end of file. * Removed temp variable. * * Change WebUI to 2x2 display * Including UE Purged indicator * Using pointers in ogs_subscription_data_t * better memory mangement with pointers * Tweak to Destination used by hss_s6a_send_idr to use last known MME * Check for null mme_host and mme_realms Do this before trying to compare the strings.
This commit is contained in:
parent
53d75e74cb
commit
775520d7a8
|
@ -189,6 +189,51 @@ int ogs_dbi_update_imeisv(char *supi, char *imeisv)
|
|||
return rv;
|
||||
}
|
||||
|
||||
int ogs_dbi_update_mme(char *supi, char *mme_host, char *mme_realm,
|
||||
bool mme_ispurged)
|
||||
{
|
||||
int rv = OGS_OK;
|
||||
bson_t *query = NULL;
|
||||
bson_t *update = NULL;
|
||||
bson_error_t error;
|
||||
|
||||
char *supi_type = NULL;
|
||||
char *supi_id = NULL;
|
||||
|
||||
ogs_assert(supi);
|
||||
|
||||
supi_type = ogs_id_get_type(supi);
|
||||
ogs_assert(supi_type);
|
||||
supi_id = ogs_id_get_value(supi);
|
||||
ogs_assert(supi_id);
|
||||
|
||||
ogs_debug("SUPI type: %s, SUPI id: %s, mme_host: %s, mme_realm: %s",
|
||||
supi_type, supi_id, mme_host, mme_realm);
|
||||
|
||||
query = BCON_NEW(supi_type, BCON_UTF8(supi_id));
|
||||
update = BCON_NEW("$set",
|
||||
"{",
|
||||
"mme_host", BCON_UTF8(mme_host),
|
||||
"mme_realm", BCON_UTF8(mme_realm),
|
||||
"mme_timestamp", BCON_INT64(ogs_time_now()),
|
||||
"mme_ispurged", BCON_BOOL(mme_ispurged),
|
||||
"}");
|
||||
if (!mongoc_collection_update(ogs_mongoc()->collection.subscriber,
|
||||
MONGOC_UPDATE_UPSERT, query, update, NULL, &error)) {
|
||||
ogs_error("mongoc_collection_update() failure: %s", error.message);
|
||||
|
||||
rv = OGS_ERROR;
|
||||
}
|
||||
|
||||
if (query) bson_destroy(query);
|
||||
if (update) bson_destroy(update);
|
||||
|
||||
ogs_free(supi_type);
|
||||
ogs_free(supi_id);
|
||||
|
||||
return rv;
|
||||
}
|
||||
|
||||
int ogs_dbi_increment_sqn(char *supi)
|
||||
{
|
||||
int rv = OGS_OK;
|
||||
|
@ -329,6 +374,14 @@ int ogs_dbi_subscription_data(char *supi,
|
|||
}
|
||||
subscription_data->num_of_msisdn = msisdn_index;
|
||||
|
||||
} else if (!strcmp(key, "imsi") &&
|
||||
BSON_ITER_HOLDS_UTF8(&iter)) {
|
||||
utf8 = bson_iter_utf8(&iter, &length);
|
||||
subscription_data->imsi = ogs_calloc(1, ogs_min(length,
|
||||
OGS_MAX_IMSI_BCD_LEN)+1);
|
||||
ogs_assert(subscription_data->imsi);
|
||||
ogs_cpystrn((char*)subscription_data->imsi,
|
||||
utf8, ogs_min(length, OGS_MAX_IMSI_BCD_LEN)+1);
|
||||
} else if (!strcmp(key, "access_restriction_data") &&
|
||||
BSON_ITER_HOLDS_INT32(&iter)) {
|
||||
subscription_data->access_restriction_data =
|
||||
|
@ -649,6 +702,25 @@ int ogs_dbi_subscription_data(char *supi,
|
|||
}
|
||||
subscription_data->num_of_slice++;
|
||||
}
|
||||
} else if (!strcmp(key, "mme_host") &&
|
||||
BSON_ITER_HOLDS_UTF8(&iter)) {
|
||||
utf8 = bson_iter_utf8(&iter, &length);
|
||||
subscription_data->mme_host = ogs_calloc(1, ogs_min(length,
|
||||
OGS_MAX_FQDN_LEN)+1);
|
||||
ogs_assert(subscription_data->mme_host);
|
||||
ogs_cpystrn((char*)subscription_data->mme_host,
|
||||
utf8, ogs_min(length, OGS_MAX_FQDN_LEN)+1);
|
||||
} else if (!strcmp(key, "mme_realm") &&
|
||||
BSON_ITER_HOLDS_UTF8(&iter)) {
|
||||
utf8 = bson_iter_utf8(&iter, &length);
|
||||
subscription_data->mme_realm = ogs_calloc(1, ogs_min(length,
|
||||
OGS_MAX_FQDN_LEN)+1);
|
||||
ogs_assert(subscription_data->mme_realm);
|
||||
ogs_cpystrn((char*)subscription_data->mme_realm,
|
||||
utf8, ogs_min(length, OGS_MAX_FQDN_LEN)+1);
|
||||
} else if (!strcmp(key, "mme_ispurged") &&
|
||||
BSON_ITER_HOLDS_BOOL(&iter)) {
|
||||
subscription_data->mme_ispurged = bson_iter_bool(&iter);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -42,6 +42,8 @@ int ogs_dbi_auth_info(char *supi, ogs_dbi_auth_info_t *auth_info);
|
|||
int ogs_dbi_update_sqn(char *supi, uint64_t sqn);
|
||||
int ogs_dbi_increment_sqn(char *supi);
|
||||
int ogs_dbi_update_imeisv(char *supi, char *imeisv);
|
||||
int ogs_dbi_update_mme(char *supi, char *mme_host, char *mme_realm,
|
||||
bool mme_ispurged);
|
||||
|
||||
int ogs_dbi_subscription_data(char *supi,
|
||||
ogs_subscription_data_t *subscription_data);
|
||||
|
|
|
@ -37,6 +37,7 @@ struct dict_object *ogs_diam_s6a_cmd_ida = NULL;
|
|||
|
||||
struct dict_object *ogs_diam_s6a_ulr_flags = NULL;
|
||||
struct dict_object *ogs_diam_s6a_ula_flags = NULL;
|
||||
struct dict_object *ogs_diam_s6a_pua_flags = NULL;
|
||||
struct dict_object *ogs_diam_s6a_clr_flags = NULL;
|
||||
struct dict_object *ogs_diam_s6a_idr_flags = NULL;
|
||||
struct dict_object *ogs_diam_s6a_cancellation_type = NULL;
|
||||
|
@ -110,6 +111,7 @@ int ogs_diam_s6a_init(void)
|
|||
|
||||
CHECK_dict_search(DICT_AVP, AVP_BY_NAME_ALL_VENDORS, "ULR-Flags", &ogs_diam_s6a_ulr_flags);
|
||||
CHECK_dict_search(DICT_AVP, AVP_BY_NAME_ALL_VENDORS, "ULA-Flags", &ogs_diam_s6a_ula_flags);
|
||||
CHECK_dict_search(DICT_AVP, AVP_BY_NAME_ALL_VENDORS, "PUA-Flags", &ogs_diam_s6a_pua_flags);
|
||||
CHECK_dict_search(DICT_AVP, AVP_BY_NAME_ALL_VENDORS, "CLR-Flags", &ogs_diam_s6a_clr_flags);
|
||||
CHECK_dict_search(DICT_AVP, AVP_BY_NAME_ALL_VENDORS, "IDR-Flags", &ogs_diam_s6a_idr_flags);
|
||||
CHECK_dict_search(DICT_AVP, AVP_BY_NAME_ALL_VENDORS, "Cancellation-Type", &ogs_diam_s6a_cancellation_type);
|
||||
|
|
|
@ -59,6 +59,9 @@ extern "C" {
|
|||
#define OGS_DIAM_S6A_ULR_INITIAL_ATTACH_IND (1 << 5)
|
||||
#define OGS_DIAM_S6A_ULR_PS_LCS_SUPPORTED_BY_UE (1 << 6)
|
||||
|
||||
#define OGS_DIAM_S6A_PUA_FLAGS_FREEZE_MTMSI (1)
|
||||
#define OGS_DIAM_S6A_PUA_FLAGS_FREEZE_PTMSI (1 << 1)
|
||||
|
||||
#define OGS_DIAM_S6A_UE_SRVCC_NOT_SUPPORTED (0)
|
||||
#define OGS_DIAM_S6A_UE_SRVCC_SUPPORTED (1)
|
||||
|
||||
|
@ -68,6 +71,12 @@ extern "C" {
|
|||
#define OGS_DIAM_S6A_VPLMN_DYNAMIC_ADDRESS_NOTALLOWED (0)
|
||||
#define OGS_DIAM_S6A_VPLMN_DYNAMIC_ADDRESS_ALLOWED (1)
|
||||
|
||||
#define OGS_DIAM_S6A_CT_MME_UPDATE_PROCEDURE (0)
|
||||
#define OGS_DIAM_S6A_CT_SGSN_UPDATE_PROCEDURE (1)
|
||||
#define OGS_DIAM_S6A_CT_SUBSCRIPTION_WITHDRAWL (2)
|
||||
#define OGS_DIAM_S6A_CT_UPDATE_PROCEDURE_IWF (3)
|
||||
#define OGS_DIAM_S6A_CT_INITIAL_ATTACH_PROCEDURE (4)
|
||||
|
||||
extern struct dict_object *ogs_diam_s6a_application;
|
||||
|
||||
extern struct dict_object *ogs_diam_s6a_cmd_air;
|
||||
|
@ -83,6 +92,7 @@ extern struct dict_object *ogs_diam_s6a_cmd_ida;
|
|||
|
||||
extern struct dict_object *ogs_diam_s6a_ulr_flags;
|
||||
extern struct dict_object *ogs_diam_s6a_ula_flags;
|
||||
extern struct dict_object *ogs_diam_s6a_pua_flags;
|
||||
extern struct dict_object *ogs_diam_s6a_clr_flags;
|
||||
extern struct dict_object *ogs_diam_s6a_idr_flags;
|
||||
extern struct dict_object *ogs_diam_s6a_cancellation_type;
|
||||
|
|
|
@ -738,6 +738,13 @@ void ogs_subscription_data_free(ogs_subscription_data_t *subscription_data)
|
|||
|
||||
ogs_assert(subscription_data);
|
||||
|
||||
if (subscription_data->imsi)
|
||||
ogs_free(subscription_data->imsi);
|
||||
if (subscription_data->mme_host)
|
||||
ogs_free(subscription_data->mme_host);
|
||||
if (subscription_data->mme_realm)
|
||||
ogs_free(subscription_data->mme_realm);
|
||||
|
||||
for (i = 0; i < subscription_data->num_of_slice; i++) {
|
||||
ogs_slice_data_t *slice_data = &subscription_data->slice[i];
|
||||
|
||||
|
|
|
@ -684,6 +684,8 @@ typedef struct ogs_subscription_data_s {
|
|||
int num_of_slice;
|
||||
ogs_slice_data_t slice[OGS_MAX_NUM_OF_SLICE];
|
||||
|
||||
char *imsi;
|
||||
|
||||
#define OGS_MAX_NUM_OF_MSISDN 2
|
||||
int num_of_msisdn;
|
||||
struct {
|
||||
|
@ -691,6 +693,10 @@ typedef struct ogs_subscription_data_s {
|
|||
int len;
|
||||
char bcd[OGS_MAX_MSISDN_BCD_LEN+1];
|
||||
} msisdn[OGS_MAX_NUM_OF_MSISDN];
|
||||
|
||||
char *mme_host;
|
||||
char *mme_realm;
|
||||
bool mme_ispurged;
|
||||
} ogs_subscription_data_t;
|
||||
|
||||
void ogs_subscription_data_free(ogs_subscription_data_t *subscription_data);
|
||||
|
|
|
@ -396,6 +396,26 @@ int hss_db_update_imeisv(char *imsi_bcd, char *imeisv)
|
|||
return rv;
|
||||
}
|
||||
|
||||
int hss_db_update_mme(char *imsi_bcd, char *mme_host, char *mme_realm,
|
||||
bool mme_ispurged)
|
||||
{
|
||||
int rv;
|
||||
char *supi = NULL;
|
||||
|
||||
ogs_assert(imsi_bcd);
|
||||
|
||||
ogs_thread_mutex_lock(&self.db_lock);
|
||||
supi = ogs_msprintf("%s-%s", OGS_ID_SUPI_TYPE_IMSI, imsi_bcd);
|
||||
ogs_assert(supi);
|
||||
|
||||
rv = ogs_dbi_update_mme(supi, mme_host, mme_realm, mme_ispurged);
|
||||
|
||||
ogs_free(supi);
|
||||
ogs_thread_mutex_unlock(&self.db_lock);
|
||||
|
||||
return rv;
|
||||
}
|
||||
|
||||
int hss_db_increment_sqn(char *imsi_bcd)
|
||||
{
|
||||
int rv;
|
||||
|
|
|
@ -63,6 +63,8 @@ int hss_db_auth_info(char *imsi_bcd, ogs_dbi_auth_info_t *auth_info);
|
|||
int hss_db_update_sqn(char *imsi_bcd, uint8_t *rand, uint64_t sqn);
|
||||
int hss_db_increment_sqn(char *imsi_bcd);
|
||||
int hss_db_update_imeisv(char *imsi_bcd, char *imeisv);
|
||||
int hss_db_update_mme(char *imsi_bcd, char *mme_host, char *mme_realm,
|
||||
bool mme_ispurged);
|
||||
|
||||
int hss_db_subscription_data(
|
||||
char *imsi_bcd, ogs_subscription_data_t *subscription_data);
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,50 @@
|
|||
/*
|
||||
* Copyright (C) 2019 by Sukchan Lee <acetcom@gmail.com>
|
||||
*
|
||||
* This file is part of Open5GS.
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU Affero General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#ifndef HSS_S6A_PATH_H
|
||||
#define HSS_S6A_PATH_H
|
||||
|
||||
#include "hss-context.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#define OGS_HSS_SUBDATA_NO_UPDATE (0)
|
||||
#define OGS_HSS_SUBDATA_MSISDN (1)
|
||||
#define OGS_HSS_SUBDATA_ARD (1 << 1)
|
||||
#define OGS_HSS_SUBDATA_SUB_STATUS (1 << 2)
|
||||
#define OGS_HSS_SUBDATA_NAM (1 << 3)
|
||||
#define OGS_HSS_SUBDATA_UEAMBR (1 << 4)
|
||||
#define OGS_HSS_SUBDATA_RAU_TAU_TIMER (1 << 5)
|
||||
#define OGS_HSS_SUBDATA_SLICE (1 << 6)
|
||||
#define OGS_HSS_SUBDATA_ALL 0xFFFFFFFF
|
||||
|
||||
/* HSS Sends Cancel Location Request to MME */
|
||||
void hss_s6a_send_clr(char *imsi_bcd, char *mme_host, char *mme_realm,
|
||||
uint32_t cancellation_type);
|
||||
|
||||
/* HSS Sends Insert Subscriber Data Request to MME */
|
||||
int hss_s6a_send_idr(char *imsi_bcd, uint32_t idr_flags, uint32_t subdata_mask);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* HSS_S6A_PATH_H */
|
|
@ -18,6 +18,7 @@
|
|||
libhss_sources = files('''
|
||||
hss-context.h
|
||||
hss-fd-path.h
|
||||
hss-s6a-path.h
|
||||
|
||||
hss-init.c
|
||||
hss-context.c
|
||||
|
|
|
@ -13,6 +13,9 @@ const Profile = new Schema({
|
|||
|
||||
msisdn: [ String ],
|
||||
imeisv: [ String ],
|
||||
mme_host: [ String ],
|
||||
mme_realm: [ String ],
|
||||
mme_ispurged: [ Boolean ],
|
||||
|
||||
security: {
|
||||
k: String,
|
||||
|
|
|
@ -13,6 +13,9 @@ const Subscriber = new Schema({
|
|||
|
||||
msisdn: [ String ],
|
||||
imeisv: [ String ],
|
||||
mme_host: [ String ],
|
||||
mme_realm: [ String ],
|
||||
mme_ispurged: [ Boolean ],
|
||||
|
||||
security: {
|
||||
k: String,
|
||||
|
|
|
@ -10,6 +10,7 @@ import CloseIcon from 'react-icons/lib/md/close';
|
|||
|
||||
import PhoneIcon from 'react-icons/lib/md/phone';
|
||||
import SecurityIcon from 'react-icons/lib/md/security';
|
||||
import MmeIcon from 'react-icons/lib/md/router';
|
||||
import PdnIcon from 'react-icons/lib/md/cast';
|
||||
import KeyboardControlIcon from 'react-icons/lib/md/keyboard-control';
|
||||
|
||||
|
@ -99,6 +100,12 @@ const Subscriber = styled.div`
|
|||
margin: 12px;
|
||||
font-size: 16px;
|
||||
}
|
||||
.sectionbody {
|
||||
display: flex;
|
||||
}
|
||||
.sectioncolumn {
|
||||
flex: 1;
|
||||
}
|
||||
.body {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
|
@ -163,6 +170,9 @@ const View = ({ visible, disableOnClickOutside, subscriber, onEdit, onDelete, on
|
|||
const imsi = (subscriber || {}).imsi;
|
||||
const msisdn_list = ((subscriber || {}).msisdn || []);
|
||||
const imeisv = (subscriber || {}).imeisv;
|
||||
const mme_host = (subscriber || {}).mme_host;
|
||||
const mme_realm = (subscriber || {}).mme_realm;
|
||||
const mme_ispurged = (subscriber || {}).mme_ispurged;
|
||||
const security = ((subscriber || {}).security || {});
|
||||
const ambr = ((subscriber || {}).ambr || {});
|
||||
const slice_list = ((subscriber || {}).slice || []);
|
||||
|
@ -193,94 +203,123 @@ const View = ({ visible, disableOnClickOutside, subscriber, onEdit, onDelete, on
|
|||
<div className="header">
|
||||
Subscriber Configuration
|
||||
</div>
|
||||
{(msisdn_list.length !== 0 || (imeisv && imeisv.length !== 0)) &&
|
||||
<div className="body">
|
||||
<div className="left">
|
||||
<PhoneIcon/>
|
||||
</div>
|
||||
<div className="right">
|
||||
{msisdn_list.map((msisdn, index) =>
|
||||
<div key={index} className="data">
|
||||
{msisdn}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>MSISDN</span>
|
||||
<div className="sectionbody">
|
||||
<div className="sectioncolumn">
|
||||
{(msisdn_list.length !== 0 || (imeisv && imeisv.length !== 0)) &&
|
||||
<div className="body">
|
||||
<div className="left">
|
||||
<PhoneIcon/>
|
||||
</div>
|
||||
)}
|
||||
{imeisv && imeisv.length !== 0 &&
|
||||
<div className="right">
|
||||
{msisdn_list.map((msisdn, index) =>
|
||||
<div key={index} className="data">
|
||||
{msisdn}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>MSISDN</span>
|
||||
</div>
|
||||
)}
|
||||
{imeisv && imeisv.length !== 0 &&
|
||||
<div className="data">
|
||||
{imeisv}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>IMEISV</span>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
<div className="body">
|
||||
<div className="left">
|
||||
<SecurityIcon/>
|
||||
</div>
|
||||
<div className="right">
|
||||
<div className="data">
|
||||
{imeisv}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>IMEISV</span>
|
||||
{security.k}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>K</span>
|
||||
</div>
|
||||
}
|
||||
{security.opc &&
|
||||
<div className="data">
|
||||
{security.opc}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>OPc</span>
|
||||
</div>
|
||||
}
|
||||
{security.op &&
|
||||
<div className="data">
|
||||
{security.op}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>OP</span>
|
||||
</div>
|
||||
}
|
||||
<div className="data">
|
||||
{security.amf}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>AMF</span>
|
||||
</div>
|
||||
{security.sqn &&
|
||||
<div className="data">
|
||||
{security.sqn}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>SQN</span>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
<div className="body">
|
||||
<div className="left">
|
||||
<SecurityIcon/>
|
||||
</div>
|
||||
<div className="right">
|
||||
<div className="data">
|
||||
{security.k}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>K</span>
|
||||
</div>
|
||||
{security.opc &&
|
||||
<div className="data">
|
||||
{security.opc}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>OPc</span>
|
||||
<div className="sectioncolumn">
|
||||
{mme_host && mme_host.length !== 0 &&
|
||||
<div className="body">
|
||||
<div className="left">
|
||||
<MmeIcon/>
|
||||
</div>
|
||||
<div className="right">
|
||||
<div className="data">
|
||||
{mme_host}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>MME Hostname</span>
|
||||
</div>
|
||||
{mme_realm &&
|
||||
<div className="data">
|
||||
{mme_realm}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>MME Realm</span>
|
||||
</div>
|
||||
}
|
||||
<div className="data">
|
||||
{mme_ispurged === true ? ( "Purged" ) : ( "Not Purged" )}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>UE is Purged at MME</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
{security.op &&
|
||||
<div className="data">
|
||||
{security.op}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>OP</span>
|
||||
<div className="body">
|
||||
<div className="left">
|
||||
<PdnIcon/>
|
||||
</div>
|
||||
}
|
||||
<div className="data">
|
||||
{security.amf}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>AMF</span>
|
||||
</div>
|
||||
{security.sqn &&
|
||||
<div className="data">
|
||||
{security.sqn}
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>SQN</span>
|
||||
<div className="right">
|
||||
<div className="data">
|
||||
{ambr['downlink'] === undefined ? "unlimited" :
|
||||
ambr.downlink['value'] === undefined ? "unlimited" :
|
||||
ambr.downlink.value
|
||||
} {ambr['downlink'] === undefined ? "unlimited" :
|
||||
ambr.downlink['value'] === undefined ? "" :
|
||||
ambr.downlink['unit'] === undefined ? "bps" :
|
||||
ambr.downlink.unit === 0 ? "bps" :
|
||||
ambr.downlink.unit === 1 ? "Kbps" :
|
||||
ambr.downlink.unit === 2 ? "Mbps" :
|
||||
ambr.downlink.unit === 3 ? "Gbps" :
|
||||
ambr.downlink.unit === 4 ? "Tbps" :
|
||||
"Unknown Unit" }
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>DL</span>
|
||||
</div>
|
||||
<div className="data">
|
||||
{ambr['uplink'] === undefined ? "unlimited" :
|
||||
ambr.uplink['value'] === undefined ? "unlimited" :
|
||||
ambr.uplink.value
|
||||
} {ambr['uplink'] === undefined ? "unlimited" :
|
||||
ambr.uplink['value'] === undefined ? "" :
|
||||
ambr.uplink['unit'] === undefined ? "bps" :
|
||||
ambr.uplink.unit === 0 ? "bps" :
|
||||
ambr.uplink.unit === 1 ? "Kbps" :
|
||||
ambr.uplink.unit === 2 ? "Mbps" :
|
||||
ambr.uplink.unit === 3 ? "Gbps" :
|
||||
ambr.uplink.unit === 4 ? "Tbps" :
|
||||
"Unknown Unit" }
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>UL</span>
|
||||
</div>
|
||||
</div>
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
<div className="body">
|
||||
<div className="left">
|
||||
<PdnIcon/>
|
||||
</div>
|
||||
<div className="right">
|
||||
<div className="data">
|
||||
{ambr['downlink'] === undefined ? "unlimited" :
|
||||
ambr.downlink['value'] === undefined ? "unlimited" :
|
||||
ambr.downlink.value
|
||||
} {ambr['downlink'] === undefined ? "unlimited" :
|
||||
ambr.downlink['value'] === undefined ? "" :
|
||||
ambr.downlink['unit'] === undefined ? "bps" :
|
||||
ambr.downlink.unit === 0 ? "bps" :
|
||||
ambr.downlink.unit === 1 ? "Kbps" :
|
||||
ambr.downlink.unit === 2 ? "Mbps" :
|
||||
ambr.downlink.unit === 3 ? "Gbps" :
|
||||
ambr.downlink.unit === 4 ? "Tbps" :
|
||||
"Unknown Unit" }
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>DL</span>
|
||||
</div>
|
||||
<div className="data">
|
||||
{ambr['uplink'] === undefined ? "unlimited" :
|
||||
ambr.uplink['value'] === undefined ? "unlimited" :
|
||||
ambr.uplink.value
|
||||
} {ambr['uplink'] === undefined ? "unlimited" :
|
||||
ambr.uplink['value'] === undefined ? "" :
|
||||
ambr.uplink['unit'] === undefined ? "bps" :
|
||||
ambr.uplink.unit === 0 ? "bps" :
|
||||
ambr.uplink.unit === 1 ? "Kbps" :
|
||||
ambr.uplink.unit === 2 ? "Mbps" :
|
||||
ambr.uplink.unit === 3 ? "Gbps" :
|
||||
ambr.uplink.unit === 4 ? "Tbps" :
|
||||
"Unknown Unit" }
|
||||
<span style={{color:oc.gray[5]}}><KeyboardControlIcon/>UL</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
Loading…
Reference in New Issue