Skip to content

Commit 7abbf7b

Browse files
authored
det-4012: add codes (#1289)
1 parent a8ef728 commit 7abbf7b

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

python/sdk/prelude_sdk/models/codes.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -191,6 +191,7 @@ class Control(Enum, metaclass=MissingItem):
191191
CROWDSTRIKE_VULN = 31
192192
DEFENDER_VULN = 32
193193
NETSKOPE = 33
194+
CUSTOM = 34
194195

195196
@classmethod
196197
def _missing_(cls, value):
@@ -329,6 +330,13 @@ class ControlCategory(Enum, metaclass=MissingItem):
329330
def _missing_(cls, value):
330331
return ControlCategory.INVALID
331332

333+
@property
334+
def scm_category(self):
335+
for k, v in SCMCategory.category_mapping().items():
336+
if self in v:
337+
return k
338+
return SCMCategory.NONE
339+
332340
@classmethod
333341
def mapping(cls):
334342
return {

0 commit comments

Comments
 (0)