text
stringlengths
79
3.72M
<vulnerable_code><commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> /* * Copyright (C) 2019,2020 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 t...
<vulnerable_code>void amf_nnrf_handle_nf_discover( ogs_sbi_xact_t *xact, ogs_sbi_message_t *recvmsg) { bool handled; ogs_sbi_object_t *sbi_object = NULL; amf_ue_t *amf_ue = NULL; amf_sess_t *sess = NULL; ogs_sbi_nf_instance_t *nf_instance = NULL; OpenAPI_search_result_t *SearchResult =...
<vulnerable_code><commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> /* * Copyright (C) 2019,2020 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 t...
<vulnerable_code><commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> /* * 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 GN...
<vulnerable_code> OpenAPI_policy_association_request_t PolicyAssociationRequest; int i, j; OpenAPI_lnode_t *node = NULL; OpenAPI_list_t *AllowedSnssais = NULL; memset(&ueLocation, 0, sizeof(ueLocation)); ueLocation.nr_location = ogs_sbi_build_nr_location( &amf_ue->tai, &amf_ue->nr...
<vulnerable_code> SmContextCreateData.serving_nf_id = ogs_sbi_self()->nf_instance_id; SmContextCreateData.serving_network = ogs_sbi_build_plmn_id_nid(&amf_ue->tai.plmn_id); SmContextCreateData.supi = amf_ue->supi; SmContextCreateData.pei = amf_ue->pei; SmContextCreateData.s_nssai = &sNssai;...
<vulnerable_code> recvmsg->AccessAndMobilitySubscriptionData->gpsis; OpenAPI_ambr_rm_t *SubscribedUeAmbr = recvmsg->AccessAndMobilitySubscriptionData->subscribed_ue_ambr; OpenAPI_list_t *SubscribedDnnList = recvmsg->AccessAndMobilitySubscriptionData...
<vulnerable_code> #include "sbi-path.h" #include "nas-path.h" #include "nausf-build.h" #include "nudm-build.h" static int server_cb(ogs_sbi_request_t *request, void *data) { ogs_sbi_server_stop_all(); } void amf_sbi_send(ogs_sbi_nf_instance_t *nf_instance, ogs_sbi_xact_t *xact) { ogs_sbi_send(nf_instance, cli...
<vulnerable_code>{ return ogs_pool_cycle(&ausf_ue_pool, ausf_ue); }<commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> { return ogs_pool_cycle(&ausf_ue_pool, ausf_ue); } void ausf_ue_select_nf(ausf_ue_t *ausf_ue, OpenAPI_nf_type_e nf_type) { ogs_assert(ausf_...
<vulnerable_code> ogs_timer_start(nf_instance->t_registration_interval, ogs_app()->time.message.sbi.nf_register_interval); ogs_nnrf_nfm_send_nf_register(nf_instance); break; case OGS_FSM_EXIT_SIG: ogs_timer_start(nf_instance->t_registration_interval, ...
<vulnerable_code> } if (NF_INSTANCE_IS_OTHERS(nf_instance->id)) { handled = ogs_sbi_nnrf_handle_nf_profile( nf_instance, NFProfile, NULL, NULL); if (!handled) { continue; } if (!OGS_SBI_NF_INSTANCE_GET( ...
<vulnerable_code> ogs_sbi_server_stop_all(); } void ausf_sbi_send(ogs_sbi_nf_instance_t *nf_instance, ogs_sbi_xact_t *xact) { ogs_sbi_send(nf_instance, client_cb, xact);<commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> ogs_sbi_server_stop_all(); } void aus...
<vulnerable_code> union avp_value val; char imsi_bcd[OGS_MAX_IMSI_BCD_LEN+1]; int rv; uint32_t result_code = 0; ogs_subscription_data_t subscription_data; struct sockaddr_in sin; struct sockaddr_in6 sin6; ogs_assert(msg); ogs_debug("[HSS] Update-Location-Request\n"); /* Create ...
<vulnerable_code> mme_ue_t *mme_ue = NULL; mme_bearer_t *bearer = NULL; ogs_pdn_t *pdn = NULL; ogs_assert(sess); mme_ue = sess->mme_ue; ogs_assert(mme_ue); pdn = sess->pdn; ogs_assert(pdn); bearer = mme_default_bearer_in_sess(sess); ogs_assert(bearer); ogs_assert(mme_bea...
<vulnerable_code> if (req->presencemask & OGS_NAS_EPS_PDN_CONNECTIVITY_REQUEST_ACCESS_POINT_NAME_PRESENT) { sess->pdn = mme_pdn_find_by_apn(mme_ue, req->access_point_name.apn); if (!sess->pdn) { /* Invalid APN */ nas_eps_send_pdn_connectivity_reject( ...
<vulnerable_code> break; } ogs_assert(num <= OGS_MAX_NUM_OF_HOSTNAME); hostname[num++] = ogs_yaml_iter_value(&hostname_iter); ...
<vulnerable_code> ogs_diam_s6a_apn_configuration_profile, &avpch1); ogs_assert(ret == 0); if (avpch1) { ret = fd_msg_browse(avpch1, MSG_BRW_FIRST_CHILD, &avpch2, NULL); ogs_assert(ret == 0); while (avpch2) { ret = fd_msg_avp_hdr(avpch2, ...
<vulnerable_code> uint8_t type, mme_sess_t *sess) { int rv; ogs_pdn_t *pdn = NULL; mme_ue_t *mme_ue = NULL; mme_bearer_t *bearer = NULL; ogs_gtp_message_t gtp_message; char apn[OGS_MAX_APN_LEN]; ogs_assert(sess); pdn = sess->pdn; ogs_assert(pdn); bearer = mme_default_bear...
<vulnerable_code> mme_bearer_t *bearer = NULL; mme_sess_t *sess = NULL; ogs_pdn_t *pdn = NULL; ogs_gtp_bearer_qos_t bearer_qos; ogs_gtp_ambr_t *ambr = NULL; uint16_t decoded = 0; memcpy(&paa, rsp->pdn_address_allocation.data, rsp->pdn_address_allocation.len); if ...
<vulnerable_code> ogs_diam_s6a_ula_message_t *ula_message) { ogs_subscription_data_t *subscription_data = NULL; ogs_assert(mme_ue); ogs_assert(ula_message); subscription_data = &ula_message->subscription_data; ogs_assert(subscription_data); memcpy(&mme_ue->subscription_data, ...
<vulnerable_code> S1AP_Cause_PR_nas, S1AP_CauseNas_normal_release, S1AP_UE_CTX_REL_UE_CONTEXT_REMOVE, 0); ogs_pkbuf_free(s6abuf); break; } ogs_error("Invalid Type[%d]", s6a_message->cmd_code); break; } ogs_pk...
<vulnerable_code> enb_ue_t *enb_ue = NULL; mme_sess_t *sess = NULL; mme_bearer_t *bearer = NULL; ogs_subscription_data_t *subscription_data = NULL; ogs_assert(mme_ue); enb_ue = enb_ue_cycle(mme_ue->enb_ue); ogs_assert(enb_ue); subscription_data = &mme_ue->subscription_data; ogs_asser...
<vulnerable_code><commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> /* * Copyright (C) 2019,2020 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 t...
<vulnerable_code><commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> /* * Copyright (C) 2019,2020 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 t...
<vulnerable_code><commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> /* * Copyright (C) 2019,2020 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 t...
<vulnerable_code><commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> /* * Copyright (C) 2019,2020 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 t...
<vulnerable_code><commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> /* * Copyright (C) 2019,2020 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 t...
<vulnerable_code><commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> /* * Copyright (C) 2019,2020 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 t...
<vulnerable_code><commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> /* * Copyright (C) 2019,2020 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 t...
<vulnerable_code><commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> /* * Copyright (C) 2019,2020 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 t...
<vulnerable_code><commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> /* * Copyright (C) 2019,2020 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 t...
<vulnerable_code>{ return ogs_pool_cycle(&pcf_sess_pool, sess); }<commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> { return ogs_pool_cycle(&pcf_sess_pool, sess); } void pcf_ue_select_nf(pcf_ue_t *pcf_ue, OpenAPI_nf_type_e nf_type) { ogs_assert(pcf_ue); ...
<vulnerable_code> ogs_timer_start(nf_instance->t_registration_interval, ogs_app()->time.message.sbi.nf_register_interval); ogs_nnrf_nfm_send_nf_register(nf_instance); break; case OGS_FSM_EXIT_SIG: ogs_timer_start(nf_instance->t_registration_interval, ...
<vulnerable_code> } if (NF_INSTANCE_IS_OTHERS(nf_instance->id)) { handled = ogs_sbi_nnrf_handle_nf_profile( nf_instance, NFProfile, NULL, NULL); if (!handled) { continue; } if (!OGS_SBI_NF_INSTANCE_GET( ...
<vulnerable_code> message.h.resource.component[3] = (char *)OGS_SBI_RESOURCE_NAME_SM_DATA; message.param.snssai_presence = true; memcpy(&message.param.snssai, &sess->s_nssai, sizeof(message.param.snssai)); if (sess->dnn) message.param.dnn = sess->dnn;<commit_title>[PATCH 1/7] mask mongo credent...
<vulnerable_code> ogs_sbi_header_t header; ogs_sbi_response_t *response = NULL; ogs_assert(pcf_ue); ogs_assert(stream); server = ogs_sbi_server_from_stream(stream); ogs_assert(recvmsg); SWITCH(recvmsg->h.resource.component[3]) CASE(OGS_SBI_RESOURCE_NAME_AM_DATA) ogs_subscriptio...
<vulnerable_code> ogs_sbi_server_stop_all(); } void pcf_sbi_send(ogs_sbi_nf_instance_t *nf_instance, ogs_sbi_xact_t *xact) { ogs_sbi_send(nf_instance, client_cb, xact);<commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> ogs_sbi_server_stop_all(); } void pcf_...
<vulnerable_code>{ int rv; char *supi = NULL; ogs_assert(imsi_bcd); ogs_assert(apn); supi = ogs_msprintf("%s-%s", OGS_ID_SUPI_TYPE_IMSI, imsi_bcd); ogs_assert(supi); rv = ogs_dbi_session_data(supi, apn, session_data); ogs_free(supi); ogs_thread_mutex_unlock(&self.db_lock);<commit_...
<vulnerable_code> } /* Set QoS-Information */ if (gx_message.session_data.pdn.ambr.downlink || gx_message.session_data.pdn.ambr.uplink) { ret = fd_msg_avp_new(ogs_diam_gx_qos_information, 0, &avp); ogs_assert(ret == 0); if (gx_message.session_...
<vulnerable_code> break; } ogs_assert(num <= OGS_MAX_NUM_OF_HOSTNAME); hostname[num++] = ogs_yaml_iter_value(&hostname_iter); ...
<vulnerable_code> noti->eps_bearer_id.u8 = bearer->ebi; memset(&arp, 0, sizeof(arp)); arp.pre_emption_vulnerability = sess->pdn.qos.arp.pre_emption_vulnerability; arp.priority_level = sess->pdn.qos.arp.priority_level; arp.pre_emption_capability = sess->pdn.qos.arp.pre_emption_capability; noti->...
<vulnerable_code> req->bearer_contexts_to_be_created.eps_bearer_id.u8); if (sess) { ogs_warn("OLD Session Release [IMSI:%s,APN:%s]", sgwc_ue->imsi_bcd, sess->pdn.apn); sgwc_sess_remove(sess); } sess = sgwc_sess_add(sgwc_ue, apn); &req->bearer_contexts_to_be...
<vulnerable_code> memcpy(&paa, rsp->pdn_address_allocation.data, ogs_min(sizeof(paa), rsp->pdn_address_allocation.len)); if (paa.pdn_type == OGS_GTP_PDN_TYPE_IPV4) { /* Nothing */ } else if (paa.pdn_type == OGS_GTP_PDN_TYPE_IPV6) { /* Nothing */ } ...
<vulnerable_code> /* PDN Type */ req->pdn_type.presence = 1; req->pdn_type.u8 = sess->pdn.paa.pdn_type; pfcp_message.h.type = type; pkbuf = ogs_pfcp_build_msg(&pfcp_message);<commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> /* PDN Type */ ...
<vulnerable_code> break; } ogs_assert(num <= OGS_MAX_NUM_OF_HOSTNAME); hostname[num++] = ogs_yaml_iter_value(&hostname_iter); ...
<vulnerable_code> ogs_pfcp_pdr_t *dl_pdr = NULL, *ul_pdr = NULL; bearer = smf_bearer_find_by_qci_arp(sess, pcc_rule->qos.qci, pcc_rule->qos.arp.priority_level, pcc_rule->qos.arp.pre_emption_capability, ...
<vulnerable_code> static int smf_context_validation(void) { if (self.dns[0] == NULL && self.dns6[0] == NULL) { ogs_error("No smf.dns in '%s'", ogs_app()->file); return OGS_ERROR; } if (ogs_list_first(&ogs_pfcp_self()->subnet_list) == NULL) { ogs_error("No smf.pdn: in '%s'", ogs_app()...
<vulnerable_code> if (sess->ipv6) { ret = fd_msg_avp_new(ogs_diam_gx_framed_ipv6_prefix, 0, &avp); ogs_assert(ret == 0); memcpy(&paa, &sess->pdn.paa, OGS_PAA_IPV6_LEN); #define FRAMED_IPV6_PREFIX_LENGTH 128 /* from spec document */ paa.len = FRAMED_IPV6_PREFIX_LEN...
<vulnerable_code> message.gsm.h.procedure_transaction_identity = sess->pti; message.gsm.h.message_type = OGS_NAS_5GS_PDU_SESSION_ESTABLISHMENT_ACCEPT; selected_pdu_session_type->type = sess->pdn.ssc_mode; selected_pdu_session_type->value = sess->pdn.pdn_type; /* * TS23.501 /* Session-AMBR ...
<vulnerable_code> /* APN-AMBR * if PCRF changes APN-AMBR, this should be included. */ sess->gtp.create_session_response_apn_ambr = false; if ((gx_message->session_data.pdn.ambr.uplink && (sess->pdn.ambr.uplink / 1000) != (gx_message->session_data.pdn.ambr.uplink / 1000)) || ...
<vulnerable_code> ogs_timer_start(nf_instance->t_registration_interval, ogs_app()->time.message.sbi.nf_register_interval); ogs_nnrf_nfm_send_nf_register(nf_instance); break; case OGS_FSM_EXIT_SIG: ogs_timer_start(nf_instance->t_registration_interval, ...
<vulnerable_code> ogs_debug("PDUSessionResourceSetupRequestTransfer"); memset(&message, 0, sizeof(NGAP_PDUSessionResourceSetupRequestTransfer_t)); if (sess->pdn.ambr.downlink || sess->pdn.ambr.uplink) { ie = CALLOC(1, sizeof(NGAP_PDUSessionResourceSetupRequestTransferIEs_t)); ...
<vulnerable_code><commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> /* * Copyright (C) 2019,2020 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 t...
<vulnerable_code> SmPolicyContextData.supi = smf_ue->supi; ogs_assert(sess->psi); SmPolicyContextData.pdu_session_id = sess->psi; ogs_assert(sess->pdn.pdn_type); SmPolicyContextData.pdu_session_type = sess->pdn.pdn_type; ogs_assert(sess->dnn); SmPolicyContextData.dnn = sess->dnn; server ...
<vulnerable_code> if (AuthSessAmbr && trigger_results[ OpenAPI_policy_control_request_trigger_SE_AMBR_CH] == true) { if (AuthSessAmbr->uplink) sess->pdn.ambr.uplink = ogs_sbi_bitrate_from_string(AuthSessAmbr->uplink); ...
<vulnerable_code> sess->s_nssai.sst = sNssai->sst; sess->s_nssai.sd = ogs_s_nssai_sd_from_string(sNssai->sd); if (SmContextCreateData->hplmn_snssai) { sess->s_nssai.mapped_hplmn_sst = SmContextCreateData->hplmn_snssai->sst; sess->s_nssai.mapped_hplmn_sd = ogs_s_nssai_s...
<vulnerable_code> message.h.resource.component[1] = data; message.param.single_nssai_presence = true; memcpy(&message.param.single_nssai, &sess->s_nssai, sizeof(message.param.single_nssai)); if (sess->dnn) message.param.dnn = sess->dnn; request = ogs_sbi_build_request(&message)...
<vulnerable_code> continue; } if (sess->dnn && ogs_strcasecmp(sess->dnn, dnnConfigurationMap->key) != 0) continue; if (sess->ue_pdu_session_type) { if (node2->data) { uint8_t allowed_session_...
<vulnerable_code> len = len; /* PDN Address Allocation */ rsp->pdn_address_allocation.data = &sess->pdn.paa; if (sess->ipv4 && sess->ipv6) rsp->pdn_address_allocation.len = OGS_PAA_IPV4V6_LEN; else if (sess->ipv4) * if PCRF changes APN-AMBR, this should be included. */ if (sess-...
<vulnerable_code> /* UE IP Address */ ogs_assert(req->pdn_address_allocation.data); sess->pdn.pdn_type = req->pdn_type.u8; ogs_gtp_paa_to_ip( (ogs_paa_t *)req->pdn_address_allocation.data, &sess->pdn.ue_ip); smf_sess_set_ue_ip(sess); ogs_info("UE IMSI[%s] APN[%s] IPv4[%s] IPv6[%s]"...
<vulnerable_code> ogs_sbi_server_stop_all(); } void smf_sbi_send(ogs_sbi_nf_instance_t *nf_instance, ogs_sbi_xact_t *xact) { ogs_sbi_send(nf_instance, client_cb, xact); ogs_sbi_response_t *response = NULL; OpenAPI_sm_context_create_error_t SmContextCreateError; OpenAPI_problem_details_t problem; ...
<vulnerable_code>{ return ogs_pool_cycle(&udm_ue_pool, udm_ue); }<commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> { return ogs_pool_cycle(&udm_ue_pool, udm_ue); } void udm_ue_select_nf(udm_ue_t *udm_ue, OpenAPI_nf_type_e nf_type) { ogs_assert(udm_ue); ...
<vulnerable_code> ogs_timer_start(nf_instance->t_registration_interval, ogs_app()->time.message.sbi.nf_register_interval); ogs_nnrf_nfm_send_nf_register(nf_instance); break; case OGS_FSM_EXIT_SIG: ogs_timer_start(nf_instance->t_registration_interval, ...
<vulnerable_code> } if (NF_INSTANCE_IS_OTHERS(nf_instance->id)) { handled = ogs_sbi_nnrf_handle_nf_profile( nf_instance, NFProfile, NULL, NULL); if (!handled) { continue; } if (!OGS_SBI_NF_INSTANCE_GET( ...
<vulnerable_code> sendmsg.param.dnn = recvmsg->param.dnn; if (recvmsg->param.single_nssai_presence) { sendmsg.param.single_nssai_presence = true; memcpy(&sendmsg.param.single_nssai, &recvmsg->param.single_nssai, sizeof(sendmsg.param.single_nssai)); ...
<vulnerable_code> ogs_sbi_server_stop_all(); } void udm_sbi_send(ogs_sbi_nf_instance_t *nf_instance, ogs_sbi_xact_t *xact) { ogs_sbi_send(nf_instance, client_cb, xact);<commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> ogs_sbi_server_stop_all(); } void udm_...
<vulnerable_code> ogs_timer_start(nf_instance->t_registration_interval, ogs_app()->time.message.sbi.nf_register_interval); ogs_nnrf_nfm_send_nf_register(nf_instance); break; case OGS_FSM_EXIT_SIG: ogs_timer_start(nf_instance->t_registration_interval, ...
<vulnerable_code> return false; } static OpenAPI_pdu_session_type_e pdu_session_type_from_dbi(uint8_t pdn_type) { if (pdn_type == OGS_DIAM_PDN_TYPE_IPV4) return OpenAPI_pdu_session_type_IPV4; else if (pdn_type == OGS_DIAM_PDN_TYPE_IPV6) return OpenAPI_pdu_session_type_IPV6; else if (pdn_...
<vulnerable_code>{ ogs_sbi_server_stop_all(); }<commit_title>[PATCH 1/7] mask mongo credentials when logging (#827)<commit_description><fixed_code> { ogs_sbi_server_stop_all(); } void udr_nnrf_nfm_send_nf_register(ogs_sbi_nf_instance_t *nf_instance) { ogs_sbi_request_t *request = NULL; ogs_sbi_client_t...
<vulnerable_code> return OGS_ERROR; } if (ogs_list_first(&ogs_pfcp_self()->subnet_list) == NULL) { ogs_error("No upf.pdn: in '%s'", ogs_app()->file); return OGS_ERROR; } return OGS_OK; break; } ...
<vulnerable_code> test_sess_t *sess = NULL; test_bearer_t *bearer = NULL; const char *_k_string = "4d060eab0a7743bc8eede608a94b63de"; uint8_t k[OGS_KEY_LEN]; const char *_opc_string = "7c0f7d5a427048a86fb429cc003c117c"; uint8_t opc[OGS_KEY_LEN]; mongoc_collection_t *collection = NULL; b...
<vulnerable_code>static ogs_thread_t *ausf_thread = NULL; static ogs_thread_t *udm_thread = NULL; static ogs_thread_t *pcf_thread = NULL; static ogs_thread_t *udr_thread = NULL; int app_initialize(const char *const argv[]) udm_thread = test_child_create("udm", argv_out); if (ogs_app()->parameter.no_pcf == ...
<vulnerable_code>static ogs_thread_t *ausf_thread = NULL; static ogs_thread_t *udm_thread = NULL; static ogs_thread_t *pcf_thread = NULL; static ogs_thread_t *udr_thread = NULL; int app_initialize(const char *const argv[]) udm_thread = test_child_create("udm", argv_out); if (ogs_app()->parameter.no_pcf == ...
<vulnerable_code> uint32_t enb_ue_s1ap_id; uint64_t mme_ue_s1ap_id; const char *_k_string = "465b5ce8b199b49faa5f0a2ee238a6bc"; uint8_t k[OGS_KEY_LEN]; const char *_opc_string = "e8ed289deba952e4283b54e88e6183ca"; uint8_t opc[OGS_KEY_LEN]; mongoc_collection_t *collection = NULL; bson_t ...
<vulnerable_code> S1AP_UE_associatedLogicalS1_ConnectionListRes_t *partOfS1_Interface = NULL; const char *_k_string = "465b5ce8b199b49faa5f0a2ee238a6bc"; uint8_t k[OGS_KEY_LEN]; const char *_opc_string = "e8ed289deba952e4283b54e88e6183ca"; uint8_t opc[OGS_KEY_LEN]; mongoc_collection_t *collect...
<vulnerable_code> self.plmn_support[ self.num_of_plmn_support]. num_of_s_nssai <= OGS_MAX_NUM_OF_S_NSSAI); s_...
<vulnerable_code> message.emm.h.protocol_discriminator = OGS_NAS_PROTOCOL_DISCRIMINATOR_EMM; message.emm.h.message_type = OGS_NAS_EPS_AUTHENTICATION_RESPONSE; milenage_f2345(test_ue->opc, test_ue->k, test_ue->rand, res, ck, ik, ak, NULL); authentication_failure->presencemask |= ...
<vulnerable_code>{ int i; uint16_t psimask = 0; ogs_s_nssai_t *s_nssai = NULL; ogs_nas_5gs_message_t message; ogs_pkbuf_t *pkbuf = NULL; OGS_NAS_5GS_REGISTRATION_REQUEST_REQUESTED_NSSAI_PRESENT; requested_nssai->length = 0; for (i = 0; i < test_self()->num_of_plmn_suppo...
<vulnerable_code> test_ue->pdu_session_status = 0; test_ue->pdu_session_reactivation_result = 0; if (registration_accept->presencemask & OGS_NAS_5GS_REGISTRATION_ACCEPT_PDU_SESSION_STATUS_PRESENT) test_ue->pdu_session_status = pdu_session_status->psi; if (registration_accept->presencemas...
<vulnerable_code> "\x83\x06\x00\x00\x00\x00\x00\x0c\x00\x00\x0d\x00\x00\x02\x00\x00" "\x0a\x00\x00\x10\x00"; ogs_s_nssai_t *s_nssai = NULL; test_ue_t *test_ue = NULL; ogs_pkbuf_t *pkbuf = NULL; extended_protocol_configuration_options->length = sizeof(ue_pco); extended_protocol_conf...
<vulnerable_code> for (j = 0; j < test_self()->plmn_support[i].num_of_s_nssai; j++) { ogs_s_nssai_t *s_nssai = &test_self()->plmn_support[i].s_nssai[j]; ogs_uint24_t sd; SliceSupportItem = CALLOC(1, sizeof(NGAP_SliceSupportItem_t)); ogs_asn_uint8_to_OCTET_STRING(...
<vulnerable_code> test_sess_t *sess = NULL; test_bearer_t *qos_flow = NULL; const char *_k_string = "70d49a71dd1a2b806a25abe0ef749f1e"; uint8_t k[OGS_KEY_LEN]; const char *_opc_string = "6f1bf53d624b3a43af6592854e2444c7"; uint8_t opc[OGS_KEY_LEN]; mongoc_collection_t *collection = NULL; ...
<vulnerable_code> uint32_t enb_ue_s1ap_id; uint64_t mme_ue_s1ap_id; const char *_k_string = "465b5ce8b199b49faa5f0a2ee238a6bc"; uint8_t k[OGS_KEY_LEN]; const char *_opc_string = "e8ed289deba952e4283b54e88e6183ca"; uint8_t opc[OGS_KEY_LEN]; mongoc_collection_t *collection = NULL; bson_t ...
<vulnerable_code> test_ue_t *test_ue = NULL; test_bearer_t *qos_flow = NULL; const char *_k_string = "70d49a71dd1a2b806a25abe0ef749f1e"; uint8_t k[OGS_KEY_LEN]; const char *_opc_string = "6f1bf53d624b3a43af6592854e2444c7"; uint8_t opc[OGS_KEY_LEN]; mongoc_collection_t *collection = NULL; ...
<vulnerable_code> test_sess_t *sess = NULL; test_bearer_t *qos_flow = NULL; const char *_k_string = "70d49a71dd1a2b806a25abe0ef749f1e"; uint8_t k[OGS_KEY_LEN]; const char *_opc_string = "6f1bf53d624b3a43af6592854e2444c7"; uint8_t opc[OGS_KEY_LEN]; mongoc_collection_t *collection = NULL; ...
<vulnerable_code> #include "test-app.h" abts_suite *test_minimal(abts_suite *suite); const struct testlist { abts_suite *(*func)(abts_suite *suite); } alltests[] = { {test_minimal}, {NULL}, }; abts_suite *suite = NULL; atexit(terminate); test_app_run(argc, argv, "minimal.yaml", initialize); ...
<vulnerable_code> test_sess_t *sess = NULL; test_bearer_t *qos_flow = NULL; const char *_k_string = "5122250214c33e723a5dd523fc145fc0"; uint8_t k[OGS_KEY_LEN]; const char *_opc_string = "981d464c7c52eb6e5036234984ad0bcf"; uint8_t opc[OGS_KEY_LEN]; mongoc_collection_t *collection = NULL; ...
<vulnerable_code> OGS_GTP_SELECTION_MODE_MS_OR_NETWORK_PROVIDED_APN | 0xfc; req.pdn_type.presence = 1; req.pdn_type.u8 = OGS_GTP_PDN_TYPE_IPV4; memset(&paa, 0, sizeof(ogs_paa_t)); paa.pdn_type = OGS_GTP_PDN_TYPE_IPV4; req.pdn_address_allocation.presence = 1; req.pdn_address_allocation.d...
<vulnerable_code> test_sess_t *sess = NULL; test_bearer_t *bearer = NULL; const char *_k_string = "465b5ce8b199b49faa5f0a2ee238a6bc"; uint8_t k[OGS_KEY_LEN]; const char *_opc_string = "e8ed289deba952e4283b54e88e6183ca"; uint8_t opc[OGS_KEY_LEN]; mongoc_collection_t *collection = NULL; b...
<vulnerable_code> memset(&paa, 0, sizeof(ogs_paa_t)); memcpy(paa.addr6, ipsub.sub, OGS_IPV6_LEN); paa.pdn_type = 0x03; #define FRAMED_IPV6_PREFIX_LENGTH 128 /* from spec document */ paa.len = FRAMED_IPV6_PREFIX_LENGTH; val.os.data = (uint8_t*)&paa; memset(&paa, 0, sizeof...
<vulnerable_code> test_sess_t *sess = NULL; test_bearer_t *qos_flow = NULL; const char *_k_string = "70d49a71dd1a2b806a25abe0ef749f1e"; uint8_t k[OGS_KEY_LEN]; const char *_opc_string = "6f1bf53d624b3a43af6592854e2444c7"; uint8_t opc[OGS_KEY_LEN]; mongoc_collection_t *collection = NULL; ...
<vulnerable_code>require('mongoose-long')(mongoose); const Profile = new Schema({ title: { $type: String, required: true }, security: { }, ambr: { downlink: Schema.Types.Long, uplink: Schema.Types.Long }, pdn: [{ apn: { $type: String, required: true }, type: { $type: Number, defaul...
<vulnerable_code>require('mongoose-long')(mongoose); const Subscriber = new Schema({ imsi: { $type: String, unique: true, required: true }, security: { sqn: Schema.Types.Long }, access_restriction_data: { $type: Number, default: 32 // Handover to Non-3GPP Access Not Allowed }, subscriber_st...
<vulnerable_code> "title": "", "properties": { "downlink": { "type": "number", "title": "UE-AMBR Downlink (Kbps)*", "required": true }, "uplink": { "type": "number", "title": "UE-AMBR Uplink (Kbps)*", "required": true ...
<vulnerable_code> color: ${oc.gray[6]}; width: 240px; } .apn { font-size: 1.1rem; color: ${oc.gray[6]}; width: 120px; const { _id, title, pdn, ambr } = profile; <Card disabled={disabled} onClick={() => onView(_id)}> <Profile> <div className...
<vulnerable_code> const title = (profile || {}).title; const security = ((profile || {}).security || {}); const ambr = ((profile || {}).ambr || {}); const pdns = ((profile || {}).pdn || []); return ( <div> <Modal visible={visible} onOutside={onHide} disableOnClickOutside={d...
<vulnerable_code> op_value: "E8ED289D EBA952E4 283B54E8 8E6183CA", }, "ambr": { "downlink": 1024000, "uplink": 1024000 }, "pdn": [ { "apn": "internet", "type": 2, "ambr": { "downlink": 1024000, "uplink": 1024000 }, "qos": { "qci": 9, // ...
<vulnerable_code> return ogs_pool_cycle(&ran_ue_pool, ran_ue); } static int amf_ue_new_guti(amf_ue_t *amf_ue) { if (amf_ue->m_tmsi) { /* AMF has a VALID GUTI ogs_hash_set(self.guti_ue_hash, &amf_ue->guti, sizeof(ogs_nas_5gs_guti_t), amf_ue); return OGS_OK; } amf_ue_t *amf_ue_add(ra...
<vulnerable_code> /* Set GUTI */ ogs_debug("[%s] %s 5G-S_GUTI[AMF_ID:0x%x,M_TMSI:0x%x]", amf_ue->supi, amf_ue->guti_present ? "[V]" : "[N]", ogs_amf_id_hexdump(&amf_ue->guti.amf_id), amf_ue->guti.m_tmsi); if (amf_ue->guti_present) { registration_accept->presencemask |= OGS...
<vulnerable_code> OGS_FSM_TRAN(s, &gmm_state_authentication); break; #if 0 case OGS_NAS_5GS_TRACKING_AREA_UPDATE_REQUEST: ogs_error("[%s] Tracking area update request", amf_ue->supi); rv = gmm_handle_tau_request( amf_ue, &na...