diff --git a/x-pack/plugins/security_solution/public/detection_engine/rule_management/components/rule_details/json_diff/json_diff.test.tsx b/x-pack/plugins/security_solution/public/detection_engine/rule_management/components/rule_details/json_diff/json_diff.test.tsx
index 8e9c465d265b8..d86be3ce90b97 100644
--- a/x-pack/plugins/security_solution/public/detection_engine/rule_management/components/rule_details/json_diff/json_diff.test.tsx
+++ b/x-pack/plugins/security_solution/public/detection_engine/rule_management/components/rule_details/json_diff/json_diff.test.tsx
@@ -179,7 +179,7 @@ describe('Rule upgrade workflow: viewing rule changes in JSON diff view', () =>
});
describe('Technical properties should not be included in preview', () => {
- it.each(['revision', 'created_at', 'created_by', 'updated_at', 'updated_by'])(
+ it.each(['revision', 'created_at', 'created_by', 'updated_at', 'updated_by', 'rule_source'])(
'Should not include "%s" in preview',
(property) => {
const oldRule: RuleResponse = {
@@ -190,6 +190,7 @@ describe('Rule upgrade workflow: viewing rule changes in JSON diff view', () =>
created_by: 'mockUserOne',
updated_at: '01/01/2024T00:00:000z',
updated_by: 'mockUserTwo',
+ rule_source: { type: 'internal' },
};
const newRule: RuleResponse = {
@@ -200,6 +201,7 @@ describe('Rule upgrade workflow: viewing rule changes in JSON diff view', () =>
created_by: 'mockUserOne',
updated_at: '02/02/2024T00:00:001z',
updated_by: 'mockUserThree',
+ rule_source: { type: 'external', is_customized: true },
};
render();
diff --git a/x-pack/plugins/security_solution/public/detection_engine/rule_management/components/rule_details/rule_diff_tab.tsx b/x-pack/plugins/security_solution/public/detection_engine/rule_management/components/rule_details/rule_diff_tab.tsx
index dd6d0417d3bb6..c2bf9ffa29098 100644
--- a/x-pack/plugins/security_solution/public/detection_engine/rule_management/components/rule_details/rule_diff_tab.tsx
+++ b/x-pack/plugins/security_solution/public/detection_engine/rule_management/components/rule_details/rule_diff_tab.tsx
@@ -57,6 +57,10 @@ const HIDDEN_PROPERTIES: Array = [
'updated_by',
'created_at',
'created_by',
+ /*
+ * Another technical property that is used for logic under the hood the user doesn't need to be aware of
+ */
+ 'rule_source',
];
const sortAndStringifyJson = (jsObject: Record): string =>
diff --git a/x-pack/plugins/security_solution/public/detection_engine/rule_management/logic/mock.ts b/x-pack/plugins/security_solution/public/detection_engine/rule_management/logic/mock.ts
index f8a7f7b6d4ae8..616469f03c1ba 100644
--- a/x-pack/plugins/security_solution/public/detection_engine/rule_management/logic/mock.ts
+++ b/x-pack/plugins/security_solution/public/detection_engine/rule_management/logic/mock.ts
@@ -41,6 +41,7 @@ export const savedRuleMock: RuleResponse = {
references: [],
related_integrations: [],
required_fields: [],
+ rule_source: { type: 'internal' },
setup: '',
severity: 'high',
severity_mapping: [],
@@ -53,7 +54,6 @@ export const savedRuleMock: RuleResponse = {
version: 1,
revision: 1,
exceptions_list: [],
- rule_source: { type: 'internal' },
};
export const rulesMock: FetchRulesResponse = {