[SMF] Gy: Include 3GPP-RAT-Type AVP in PS-Information AVP

The AVP is optional, but used by some OCS vendors like PortaOne OCS make
use of it.
This commit is contained in:
Pau Espin 2024-03-20 16:03:44 +01:00 committed by Sukchan Lee
parent 6420e80fe6
commit d0b31177cc
1 changed files with 11 additions and 0 deletions

View File

@ -552,6 +552,17 @@ static void fill_ps_information(smf_sess_t *sess, uint32_t cc_request_type,
/* 3GPP-User-Location-Info, 3GPP TS 29.061 16.4.7.2 22 */
smf_fd_msg_avp_add_3gpp_uli(sess, (struct msg *)avpch1);
/* 3GPP-RAT-Type, TS 29.061 16.4.7.2 21 */
/* GGSN: TS 29.060 7.7.50, PGW: TS 29.274 8.17 */
ret = fd_msg_avp_new(ogs_diam_gy_3gpp_rat_type, 0, &avpch2);
ogs_assert(ret == 0);
val.os.data = (uint8_t*)&sess->gtp_rat_type;
val.os.len = 1;
ret = fd_msg_avp_setvalue(avpch2, &val);
ogs_assert(ret == 0);
ret = fd_msg_avp_add(avpch1, MSG_BRW_LAST_CHILD, avpch2);
ogs_assert(ret == 0);
if (sess->smf_ue->imeisv_len > 0) {
/* User-Equipment-Info, 3GPP TS 32.299 7.1.17 */
ret = fd_msg_avp_new(ogs_diam_gy_user_equipment_info, 0, &avpch2);