contentctl 5.5.1__py3-none-any.whl → 5.5.2__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -6,7 +6,7 @@ from dataclasses import dataclass
6
6
 
7
7
  from contentctl.input.director import DirectorOutputDto
8
8
  from contentctl.objects.config import build
9
- from contentctl.output.api_json_output import ApiJsonOutput
9
+ from contentctl.output.api_json_output import JSON_API_VERSION, ApiJsonOutput
10
10
  from contentctl.output.conf_output import ConfOutput
11
11
  from contentctl.output.conf_writer import ConfWriter
12
12
 
@@ -76,7 +76,9 @@ class Build:
76
76
  api_json_output.writeDeployments(input_dto.director_output_dto.deployments)
77
77
 
78
78
  # create version file for sse api
79
- version_file = input_dto.config.getAPIPath() / "version.json"
79
+ version_file = (
80
+ input_dto.config.getAPIPath() / f"version_v{JSON_API_VERSION}.json"
81
+ )
80
82
  utc_time = (
81
83
  datetime.datetime.now(datetime.timezone.utc)
82
84
  .replace(microsecond=0, tzinfo=None)
@@ -16,6 +16,8 @@ import pathlib
16
16
 
17
17
  from contentctl.output.json_writer import JsonWriter
18
18
 
19
+ JSON_API_VERSION = 2
20
+
19
21
 
20
22
  class ApiJsonOutput:
21
23
  output_path: pathlib.Path
@@ -70,7 +72,9 @@ class ApiJsonOutput:
70
72
  # del()
71
73
 
72
74
  JsonWriter.writeJsonObject(
73
- os.path.join(self.output_path, "detections.json"), "detections", detections
75
+ os.path.join(self.output_path, f"detections_v{JSON_API_VERSION}.json"),
76
+ "detections",
77
+ detections,
74
78
  )
75
79
 
76
80
  def writeMacros(
@@ -86,7 +90,9 @@ class ApiJsonOutput:
86
90
  if k in macro:
87
91
  del macro[k]
88
92
  JsonWriter.writeJsonObject(
89
- os.path.join(self.output_path, "macros.json"), "macros", macros
93
+ os.path.join(self.output_path, f"macros_v{JSON_API_VERSION}.json"),
94
+ "macros",
95
+ macros,
90
96
  )
91
97
 
92
98
  def writeStories(
@@ -132,7 +138,9 @@ class ApiJsonOutput:
132
138
  ]
133
139
 
134
140
  JsonWriter.writeJsonObject(
135
- os.path.join(self.output_path, "stories.json"), "stories", stories
141
+ os.path.join(self.output_path, f"stories_v{JSON_API_VERSION}.json"),
142
+ "stories",
143
+ stories,
136
144
  )
137
145
 
138
146
  def writeBaselines(
@@ -163,7 +171,9 @@ class ApiJsonOutput:
163
171
  ]
164
172
 
165
173
  JsonWriter.writeJsonObject(
166
- os.path.join(self.output_path, "baselines.json"), "baselines", baselines
174
+ os.path.join(self.output_path, f"baselines_v{JSON_API_VERSION}.json"),
175
+ "baselines",
176
+ baselines,
167
177
  )
168
178
 
169
179
  def writeInvestigations(
@@ -195,7 +205,7 @@ class ApiJsonOutput:
195
205
  for investigation in objects
196
206
  ]
197
207
  JsonWriter.writeJsonObject(
198
- os.path.join(self.output_path, "response_tasks.json"),
208
+ os.path.join(self.output_path, f"response_tasks_v{JSON_API_VERSION}.json"),
199
209
  "response_tasks",
200
210
  investigations,
201
211
  )
@@ -227,7 +237,9 @@ class ApiJsonOutput:
227
237
  if k in lookup:
228
238
  del lookup[k]
229
239
  JsonWriter.writeJsonObject(
230
- os.path.join(self.output_path, "lookups.json"), "lookups", lookups
240
+ os.path.join(self.output_path, f"lookups_v{JSON_API_VERSION}.json"),
241
+ "lookups",
242
+ lookups,
231
243
  )
232
244
 
233
245
  def writeDeployments(
@@ -255,7 +267,7 @@ class ApiJsonOutput:
255
267
  # references are not to be included, but have been deleted in the
256
268
  # model_serialization logic
257
269
  JsonWriter.writeJsonObject(
258
- os.path.join(self.output_path, "deployments.json"),
270
+ os.path.join(self.output_path, f"deployments_v{JSON_API_VERSION}.json"),
259
271
  "deployments",
260
272
  deployments,
261
273
  )
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: contentctl
3
- Version: 5.5.1
3
+ Version: 5.5.2
4
4
  Summary: Splunk Content Control Tool
5
5
  License: Apache 2.0
6
6
  Author: STRT
@@ -1,5 +1,5 @@
1
1
  contentctl/__init__.py,sha256=kUR5RAFc7HCeiqdlX36dZOHkUI5wI6V_43RpEcD8b-0,22
2
- contentctl/actions/build.py,sha256=agpHT6QCCFdWTs4jU7v8xqvGy3DG_zgsZZT96j1gcW0,3965
2
+ contentctl/actions/build.py,sha256=C95i2MhxHkNJb9IdVp_MnRtuoowXxc5Gu-0xK24JEeU,4036
3
3
  contentctl/actions/deploy_acs.py,sha256=w3OqO8GXzB_5zHrE8lDYbadAy4Etw7F2o84Gze74RY0,3264
4
4
  contentctl/actions/detection_testing/DetectionTestingManager.py,sha256=94apBwLkXWsgdLSvE9f_KqCfQSdmDChMncMcsEdY1A8,10974
5
5
  contentctl/actions/detection_testing/GitService.py,sha256=HU1fKkb5463weqSZ3LrTVHtNrzBH_f5pE99-zD2j1A8,11345
@@ -91,7 +91,7 @@ contentctl/objects/throttling.py,sha256=oupWmdtvwAXzLmD3MBJyAU18SD2L2ciEZWUcnL8M
91
91
  contentctl/objects/unit_test.py,sha256=-rtSmZ8N2UZ4NkDsfzNXzXiF6dTDwt_jsQ_14xp0hjs,1005
92
92
  contentctl/objects/unit_test_baseline.py,sha256=ezg8Ctih_3che2ln2tuVCAtRPHaf5tDMR3dGb34MqaA,287
93
93
  contentctl/objects/unit_test_result.py,sha256=gqHqYN5XGBKdV-mdKhAdwfOw4_PpN3i9z_b6ciByDSc,2928
94
- contentctl/output/api_json_output.py,sha256=s07bD79qFyFQIzfsTpIoFVyGYWlC77J9DNAlVwZwaOs,8269
94
+ contentctl/output/api_json_output.py,sha256=AwuXFVzg3bY0DUsYaEGM73LAr9mJ5nxkOmUdVJgTzRs,8563
95
95
  contentctl/output/attack_nav_output.py,sha256=cbQNZkcNCKaQm7Ht70_tcmTvixtsuVDjQB4BpZ8s-Ts,2489
96
96
  contentctl/output/attack_nav_writer.py,sha256=AiQU3q8hzz_lJECI-sjyqOsWx64HUugg3aAHEeZl-qM,2750
97
97
  contentctl/output/conf_output.py,sha256=OJ4u38FEkuBHvIiK_57HoxUJasWV2rkX2abVamKh3Qg,11045
@@ -164,8 +164,8 @@ contentctl/templates/detections/web/.gitkeep,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRk
164
164
  contentctl/templates/macros/security_content_ctime.yml,sha256=Gg1YNllHVsX_YB716H1SJLWzxXZEfuJlnsgB2fuyoHU,159
165
165
  contentctl/templates/macros/security_content_summariesonly.yml,sha256=9BYUxAl2E4Nwh8K19F3AJS8Ka7ceO6ZDBjFiO3l3LY0,162
166
166
  contentctl/templates/stories/cobalt_strike.yml,sha256=uj8idtDNOAIqpZ9p8usQg6mop1CQkJ5TlB4Q7CJdTIE,3082
167
- contentctl-5.5.1.dist-info/LICENSE.md,sha256=hQWUayRk-pAiOZbZnuy8djmoZkjKBx8MrCFpW-JiOgo,11344
168
- contentctl-5.5.1.dist-info/METADATA,sha256=XhbhGN1aMAw53wwWqnr7_ykYAR0P9tAwUVi6erB6Kzo,5134
169
- contentctl-5.5.1.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
170
- contentctl-5.5.1.dist-info/entry_points.txt,sha256=5bjZ2NkbQfSwK47uOnA77yCtjgXhvgxnmCQiynRF_-U,57
171
- contentctl-5.5.1.dist-info/RECORD,,
167
+ contentctl-5.5.2.dist-info/LICENSE.md,sha256=hQWUayRk-pAiOZbZnuy8djmoZkjKBx8MrCFpW-JiOgo,11344
168
+ contentctl-5.5.2.dist-info/METADATA,sha256=uEd5lG5USXUlZ89CQMCnSGQ1zIXKT5tGmrK4jCzDaC0,5134
169
+ contentctl-5.5.2.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
170
+ contentctl-5.5.2.dist-info/entry_points.txt,sha256=5bjZ2NkbQfSwK47uOnA77yCtjgXhvgxnmCQiynRF_-U,57
171
+ contentctl-5.5.2.dist-info/RECORD,,