Skip to content

Commit

Permalink
[client] New contract config
Browse files Browse the repository at this point in the history
  • Loading branch information
SamuelHassine committed Apr 29, 2024
1 parent 8522f0f commit e5ad793
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pyobas/contracts/contract_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,7 @@ class Contract:
+ VariableHelper.uri_variables()
)
attack_patterns_external_ids: List[str] = field(default_factory=list)
platforms: List[str] = field(default_factory=list)

def add_attack_pattern(self, var: str):
self.attack_patterns_external_ids.append(var)
Expand Down Expand Up @@ -140,6 +141,7 @@ def prepare_contracts(contracts):
"contract_labels": c.label,
"contract_attack_patterns_external_ids": c.attack_patterns_external_ids,
"contract_content": json.dumps(c, cls=utils.EnhancedJSONEncoder),
"contract_platforms": c.platforms,
},
contracts,
)
Expand Down

0 comments on commit e5ad793

Please sign in to comment.