From 2ead67ef4fea41d68e7c322b062c7e51ed9d6232 Mon Sep 17 00:00:00 2001 From: luwenpeng Date: Thu, 24 Oct 2024 14:32:17 +0800 Subject: [PATCH] =?UTF-8?q?TSG-22784=20TFE=E9=80=82=E9=85=8DTRAFFIC=5FMIRR?= =?UTF-8?q?OR=5FPROFIL=E5=BA=93=E8=A1=A8=E5=AD=97=E6=AE=B5=E5=8F=98?= =?UTF-8?q?=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- plugin/business/traffic-mirror/src/entry.cpp | 10 +++++----- resource/pangu/doh.json | 4 ++-- resource/pangu/pangu_http.json | 4 ++-- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/plugin/business/traffic-mirror/src/entry.cpp b/plugin/business/traffic-mirror/src/entry.cpp index 13073c2..cf87ce8 100644 --- a/plugin/business/traffic-mirror/src/entry.cpp +++ b/plugin/business/traffic-mirror/src/entry.cpp @@ -131,10 +131,10 @@ void policy_table_ex_data_new_cb(const char *table_name, const char *key, const goto error_out; } - subobj = cJSON_GetObjectItem(object, "traffic_mirror"); + subobj = cJSON_GetObjectItem(object, "traffic_mirroring"); if (unlikely(!subobj)) { - TFE_LOG_ERROR(instance->logger, "invalid format, traffic_mirror is not defined, %s", table_line); + TFE_LOG_ERROR(instance->logger, "invalid format, traffic_mirroring is not defined, %s", table_line); goto error_out; } @@ -147,7 +147,7 @@ void policy_table_ex_data_new_cb(const char *table_name, const char *key, const item = cJSON_GetObjectItem(subobj, "enable"); if (unlikely(!item || !cJSON_IsNumber(item))) { - TFE_LOG_ERROR(instance->logger, "invalid JSON, traffic_mirror->enable not existed or invalid type."); + TFE_LOG_ERROR(instance->logger, "invalid JSON, traffic_mirroring->enable not existed or invalid type."); goto error_out; } @@ -157,10 +157,10 @@ void policy_table_ex_data_new_cb(const char *table_name, const char *key, const goto success; } - item = cJSON_GetObjectItem(subobj, "mirror_profile"); + item = cJSON_GetObjectItem(subobj, "mirroring_profile"); if (unlikely(!item || !cJSON_IsString(item))) { - TFE_LOG_DEBUG(instance->logger, "traffic_mirror->mirror_profile not existed, user default vlan id :%d.", instance->default_vlan_id); + TFE_LOG_DEBUG(instance->logger, "traffic_mirroring->mirroring_profile not existed, user default vlan id :%d.", instance->default_vlan_id); ex_data->is_profile_set = 0; uuid_clear(ex_data->profile_uuid); } diff --git a/resource/pangu/doh.json b/resource/pangu/doh.json index e89e741..2fa0870 100644 --- a/resource/pangu/doh.json +++ b/resource/pangu/doh.json @@ -77,8 +77,8 @@ { "table_name": "PXY_INTERCEPT_RULE", "table_content": [ - {"uuid":"INTERCEP-0000-0000-0000-000000000001","action":"intercept", "log_option":"none", "action_parameter":{"vsys_id":1,"keyring_for_trusted":"KERING00-TRUS-0000-0000-000000000001","keyring_for_untrusted":"KERING00-UNTR-0000-0000-000000000001","decryption_profile":"DECRYPT0-0000-0000-0000-000000000001","tcp_option_profile":"TCPOPT00-0000-0000-0000-000000000001","traffic_mirror":{"enable":0}},"is_valid":1}, - {"uuid":"INTERCEP-0000-0000-0000-000000000002","action":"intercept", "log_option":"none","action_parameter":{"vsys_id":1,"keyring_for_trusted":"KERING00-TRUS-0000-0000-000000000001","keyring_for_untrusted":"KERING00-UNTR-0000-0000-000000000001","decryption_profile":"DECRYPT0-0000-0000-0000-000000000001","tcp_option_profile":"TCPOPT00-0000-0000-0000-000000000001","traffic_mirror":{"enable":1,"mirror_profile":"TRAFFIC0-MIRR-0000-0000-000000000001"}},"is_valid":1} + {"uuid":"INTERCEP-0000-0000-0000-000000000001","action":"intercept", "log_option":"none", "action_parameter":{"vsys_id":1,"keyring_for_trusted":"KERING00-TRUS-0000-0000-000000000001","keyring_for_untrusted":"KERING00-UNTR-0000-0000-000000000001","decryption_profile":"DECRYPT0-0000-0000-0000-000000000001","tcp_option_profile":"TCPOPT00-0000-0000-0000-000000000001","traffic_mirroring":{"enable":0}},"is_valid":1}, + {"uuid":"INTERCEP-0000-0000-0000-000000000002","action":"intercept", "log_option":"none","action_parameter":{"vsys_id":1,"keyring_for_trusted":"KERING00-TRUS-0000-0000-000000000001","keyring_for_untrusted":"KERING00-UNTR-0000-0000-000000000001","decryption_profile":"DECRYPT0-0000-0000-0000-000000000001","tcp_option_profile":"TCPOPT00-0000-0000-0000-000000000001","traffic_mirroring":{"enable":1,"mirroring_profile":"TRAFFIC0-MIRR-0000-0000-000000000001"}},"is_valid":1} ] }, { diff --git a/resource/pangu/pangu_http.json b/resource/pangu/pangu_http.json index 8cb6b9e..1ab7205 100644 --- a/resource/pangu/pangu_http.json +++ b/resource/pangu/pangu_http.json @@ -175,8 +175,8 @@ { "table_name": "PXY_INTERCEPT_RULE", "table_content": [ - {"uuid":"INTERCEP-0000-0000-0000-000000000001","action":"intercept", "log_option":"none", "action_parameter":{"vsys_id":1,"keyring_for_trusted":"KERING00-TRUS-0000-0000-000000000001","keyring_for_untrusted":"KERING00-UNTR-0000-0000-000000000001","decryption_profile":"DECRYPT0-0000-0000-0000-000000000001","tcp_option_profile":"TCPOPT00-0000-0000-0000-000000000001","traffic_mirror":{"enable":0}},"is_valid":1}, - {"uuid":"INTERCEP-0000-0000-0000-000000000002","action":"intercept", "log_option":"none","action_parameter":{"vsys_id":1,"keyring_for_trusted":"KERING00-TRUS-0000-0000-000000000001","keyring_for_untrusted":"KERING00-UNTR-0000-0000-000000000001","decryption_profile":"DECRYPT0-0000-0000-0000-000000000001","tcp_option_profile":"TCPOPT00-0000-0000-0000-000000000001","traffic_mirror":{"enable":1,"mirror_profile":"TRAFFIC0-MIRR-0000-0000-000000000001"}},"is_valid":1} + {"uuid":"INTERCEP-0000-0000-0000-000000000001","action":"intercept", "log_option":"none", "action_parameter":{"vsys_id":1,"keyring_for_trusted":"KERING00-TRUS-0000-0000-000000000001","keyring_for_untrusted":"KERING00-UNTR-0000-0000-000000000001","decryption_profile":"DECRYPT0-0000-0000-0000-000000000001","tcp_option_profile":"TCPOPT00-0000-0000-0000-000000000001","traffic_mirroring":{"enable":0}},"is_valid":1}, + {"uuid":"INTERCEP-0000-0000-0000-000000000002","action":"intercept", "log_option":"none","action_parameter":{"vsys_id":1,"keyring_for_trusted":"KERING00-TRUS-0000-0000-000000000001","keyring_for_untrusted":"KERING00-UNTR-0000-0000-000000000001","decryption_profile":"DECRYPT0-0000-0000-0000-000000000001","tcp_option_profile":"TCPOPT00-0000-0000-0000-000000000001","traffic_mirroring":{"enable":1,"mirroring_profile":"TRAFFIC0-MIRR-0000-0000-000000000001"}},"is_valid":1} ] }, {