Merge pull request #240 from laf0rge/master
diameter spec compliance related fixes
This commit is contained in:
commit
4f9a2e94fc
|
@ -399,6 +399,15 @@ static int hss_s6a_ulr_cb( struct msg **msg, struct avp *avp,
|
|||
ret = fd_msg_avp_add(avp, MSG_BRW_LAST_CHILD, avp_ambr);
|
||||
ogs_assert(ret == 0);
|
||||
|
||||
/* Set the Subscribed RAU TAU Timer */
|
||||
ret = fd_msg_avp_new(s6a_subscribed_rau_tau_timer, 0, &avp_rau_tau_timer);
|
||||
ogs_assert(ret == 0);
|
||||
val.i32 = subscription_data.subscribed_rau_tau_timer * 60; /* seconds */
|
||||
ret = fd_msg_avp_setvalue(avp_rau_tau_timer, &val);
|
||||
ogs_assert(ret == 0);
|
||||
ret = fd_msg_avp_add(avp, MSG_BRW_LAST_CHILD, avp_rau_tau_timer);
|
||||
ogs_assert(ret == 0);
|
||||
|
||||
if (subscription_data.num_of_pdn) {
|
||||
/* Set the APN Configuration Profile */
|
||||
struct avp *apn_configuration_profile;
|
||||
|
@ -620,14 +629,6 @@ static int hss_s6a_ulr_cb( struct msg **msg, struct avp *avp,
|
|||
ogs_assert(ret == 0);
|
||||
}
|
||||
|
||||
ret = fd_msg_avp_new(s6a_subscribed_rau_tau_timer, 0, &avp);
|
||||
ogs_assert(ret == 0);
|
||||
val.i32 = subscription_data.subscribed_rau_tau_timer * 60; /* seconds */
|
||||
ret = fd_msg_avp_setvalue(avp, &val);
|
||||
ogs_assert(ret == 0);
|
||||
ret = fd_msg_avp_add(ans, MSG_BRW_LAST_CHILD, avp);
|
||||
ogs_assert(ret == 0);
|
||||
|
||||
/* Set Vendor-Specific-Application-Id AVP */
|
||||
ret = fd_message_vendor_specific_appid_set(ans, S6A_APPLICATION_ID);
|
||||
ogs_assert(ret == 0);
|
||||
|
|
|
@ -704,11 +704,23 @@ static void mme_s6a_ula_cb(void *data, struct msg **msg)
|
|||
ogs_error("no_Max-Bandwidth-DL");
|
||||
error++;
|
||||
}
|
||||
|
||||
} else {
|
||||
ogs_error("no_AMBR");
|
||||
error++;
|
||||
}
|
||||
|
||||
ret = fd_avp_search_avp(avp, s6a_subscribed_rau_tau_timer, &avpch1);
|
||||
ogs_assert(ret == 0);
|
||||
if (avp) {
|
||||
ret = fd_msg_avp_hdr(avpch1, &hdr);
|
||||
ogs_assert(ret == 0);
|
||||
subscription_data->subscribed_rau_tau_timer = hdr->avp_value->i32;
|
||||
} else {
|
||||
ogs_error("no_Subscribed_RAU-TAU-Timer");
|
||||
error++;
|
||||
}
|
||||
|
||||
ret = fd_avp_search_avp(avp, s6a_apn_configuration_profile, &avpch1);
|
||||
ogs_assert(ret == 0);
|
||||
if (avpch1) {
|
||||
|
@ -806,8 +818,7 @@ static void mme_s6a_ula_cb(void *data, struct msg **msg)
|
|||
pdn->qos.arp.pre_emption_capability =
|
||||
hdr->avp_value->i32;
|
||||
} else {
|
||||
ogs_error("no_Preemption-Capability");
|
||||
error++;
|
||||
pdn->qos.arp.pre_emption_capability = 1; /* disabled */
|
||||
}
|
||||
|
||||
ret = fd_avp_search_avp(avpch4,
|
||||
|
@ -819,8 +830,7 @@ static void mme_s6a_ula_cb(void *data, struct msg **msg)
|
|||
pdn->qos.arp.pre_emption_vulnerability =
|
||||
hdr->avp_value->i32;
|
||||
} else {
|
||||
ogs_error("no_Preemption-Vulnerability");
|
||||
error++;
|
||||
pdn->qos.arp.pre_emption_vulnerability = 0; /* enabled */
|
||||
}
|
||||
|
||||
} else {
|
||||
|
@ -928,17 +938,6 @@ static void mme_s6a_ula_cb(void *data, struct msg **msg)
|
|||
error++;
|
||||
}
|
||||
|
||||
ret = fd_msg_search_avp(*msg, s6a_subscribed_rau_tau_timer, &avp);
|
||||
ogs_assert(ret == 0);
|
||||
if (avp) {
|
||||
ret = fd_msg_avp_hdr(avp, &hdr);
|
||||
ogs_assert(ret == 0);
|
||||
subscription_data->subscribed_rau_tau_timer = hdr->avp_value->i32;
|
||||
} else {
|
||||
ogs_error("no_Subscribed_RAU-TAU-Timer");
|
||||
error++;
|
||||
}
|
||||
|
||||
if (!error) {
|
||||
int rv;
|
||||
e = mme_event_new(MME_EVT_S6A_MESSAGE);
|
||||
|
|
Loading…
Reference in New Issue