mirror of
https://github.com/open5gs/open5gs.git
synced 2026-05-02 21:30:10 +00:00
[AMF] security protection (UERANSIM-issues316)
1. Allocate ngKSI other than the value already used. 2. Add the protection of Service request 3. fix SBI convert error ng_ap_cause
This commit is contained in:
parent
b0e8dbb31a
commit
5ea9b22209
384 changed files with 226 additions and 2699 deletions
|
|
@ -56,10 +56,6 @@ cJSON *OpenAPI_dynamic5_qi_convertToJSON(OpenAPI_dynamic5_qi_t *dynamic5_qi)
|
|||
}
|
||||
|
||||
item = cJSON_CreateObject();
|
||||
if (!dynamic5_qi->resource_type) {
|
||||
ogs_error("OpenAPI_dynamic5_qi_convertToJSON() failed [resource_type]");
|
||||
goto end;
|
||||
}
|
||||
cJSON *resource_type_local_JSON = OpenAPI_qos_resource_type_convertToJSON(dynamic5_qi->resource_type);
|
||||
if (resource_type_local_JSON == NULL) {
|
||||
ogs_error("OpenAPI_dynamic5_qi_convertToJSON() failed [resource_type]");
|
||||
|
|
@ -71,28 +67,16 @@ cJSON *OpenAPI_dynamic5_qi_convertToJSON(OpenAPI_dynamic5_qi_t *dynamic5_qi)
|
|||
goto end;
|
||||
}
|
||||
|
||||
if (!dynamic5_qi->priority_level) {
|
||||
ogs_error("OpenAPI_dynamic5_qi_convertToJSON() failed [priority_level]");
|
||||
goto end;
|
||||
}
|
||||
if (cJSON_AddNumberToObject(item, "priorityLevel", dynamic5_qi->priority_level) == NULL) {
|
||||
ogs_error("OpenAPI_dynamic5_qi_convertToJSON() failed [priority_level]");
|
||||
goto end;
|
||||
}
|
||||
|
||||
if (!dynamic5_qi->packet_delay_budget) {
|
||||
ogs_error("OpenAPI_dynamic5_qi_convertToJSON() failed [packet_delay_budget]");
|
||||
goto end;
|
||||
}
|
||||
if (cJSON_AddNumberToObject(item, "packetDelayBudget", dynamic5_qi->packet_delay_budget) == NULL) {
|
||||
ogs_error("OpenAPI_dynamic5_qi_convertToJSON() failed [packet_delay_budget]");
|
||||
goto end;
|
||||
}
|
||||
|
||||
if (!dynamic5_qi->packet_err_rate) {
|
||||
ogs_error("OpenAPI_dynamic5_qi_convertToJSON() failed [packet_err_rate]");
|
||||
goto end;
|
||||
}
|
||||
if (cJSON_AddStringToObject(item, "packetErrRate", dynamic5_qi->packet_err_rate) == NULL) {
|
||||
ogs_error("OpenAPI_dynamic5_qi_convertToJSON() failed [packet_err_rate]");
|
||||
goto end;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue