tcex 4.0.11.dev4__tar.gz → 4.0.11.dev5__tar.gz
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.
- {tcex-4.0.11.dev4/tcex.egg-info → tcex-4.0.11.dev5}/PKG-INFO +1 -1
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/pyproject.toml +2 -1
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/__metadata__.py +1 -1
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/tc.py +9 -5
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/ti_transform/model/__init__.py +1 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/ti_transform/model/transform_model.py +84 -4
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/ti_transform/ti_predefined_functions.py +56 -20
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/ti_transform/ti_transform.py +33 -30
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/ti_transform/transform_abc.py +155 -46
- tcex-4.0.11.dev5/tcex/api/tc/ti_transform/transform_builder/__init__.py +32 -0
- tcex-4.0.11.dev5/tcex/api/tc/ti_transform/transform_builder/v2/__init__.py +3 -0
- tcex-4.0.11.dev5/tcex/api/tc/ti_transform/transform_builder/v2/errors.py +42 -0
- tcex-4.0.11.dev5/tcex/api/tc/ti_transform/transform_builder/v2/load_transform.py +318 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/playbook/playbook_create.py +21 -12
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/pleb/cached_property_filesystem.py +3 -4
- tcex-4.0.11.dev5/tcex/pleb/jmespath_custom.py +66 -0
- tcex-4.0.11.dev5/tcex/pleb/jmespath_functions_array_mixin.py +665 -0
- tcex-4.0.11.dev5/tcex/pleb/jmespath_functions_base.py +43 -0
- tcex-4.0.11.dev5/tcex/pleb/jmespath_functions_control_mixin.py +91 -0
- tcex-4.0.11.dev5/tcex/pleb/jmespath_functions_crypto_mixin.py +65 -0
- tcex-4.0.11.dev5/tcex/pleb/jmespath_functions_datetime_mixin.py +130 -0
- tcex-4.0.11.dev5/tcex/pleb/jmespath_functions_math_mixin.py +235 -0
- tcex-4.0.11.dev5/tcex/pleb/jmespath_functions_object_mixin.py +253 -0
- tcex-4.0.11.dev5/tcex/pleb/jmespath_functions_string_mixin.py +602 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/code_operation.py +4 -1
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5/tcex.egg-info}/PKG-INFO +1 -1
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex.egg-info/SOURCES.txt +12 -0
- tcex-4.0.11.dev4/tcex/pleb/jmespath_custom.py +0 -353
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/LICENSE +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/README.md +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/setup.cfg +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/api.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/ti_transform/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/util/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/util/threat_intel_util.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/batch/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/batch/association.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/batch/attribute.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/batch/batch.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/batch/batch_cleaner.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/batch/batch_submit.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/batch/batch_writer.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/batch/group.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/batch/indicator.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/batch/security_label.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/batch/tag.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/datastore/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/datastore/cache.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/datastore/datastore.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/metric/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/metric/metric.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/notification/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/notification/notification.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/filters.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/adversary.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/attack_pattern.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/campaign.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/course_of_action.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/document.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/email.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/event.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/incident.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/intrusion_set.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/malware.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/report.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/signature.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/tactic.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/threat.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/tool.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/group/group_type/vulnerability.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/indicator/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/indicator/indicator.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/indicator/indicator_type/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/indicator/indicator_type/address.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/indicator/indicator_type/email_address.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/indicator/indicator_type/file.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/indicator/indicator_type/host.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/indicator/indicator_type/url.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/mapping.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/owner.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/security_label.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/tag.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/tags.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/task.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/mapping/victim.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/tcex_ti_tc_request.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/threat_intelligence/threat_intelligence.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v2/v2.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/_gen/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/_gen/_gen.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/_gen/_gen_abc.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/_gen/_gen_args_abc.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/_gen/_gen_filter_abc.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/_gen/_gen_model_abc.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/_gen/_gen_object_abc.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/_gen/_options_abc.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/_gen/_options_data_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/_gen/_options_data_object.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/_gen/model/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/_gen/model/_filter_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/_gen/model/_property_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/adversary_assets/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/api_endpoints.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/artifact_types/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/artifact_types/artifact_type.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/artifact_types/artifact_type_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/artifact_types/artifact_type_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/artifacts/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/artifacts/artifact.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/artifacts/artifact_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/artifacts/artifact_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/attribute_types/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/attribute_types/attribute_type.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/attribute_types/attribute_type_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/attribute_types/attribute_type_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/attributes/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/attributes/attribute_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/case_attributes/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/case_attributes/case_attribute.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/case_attributes/case_attribute_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/case_attributes/case_attribute_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/case_management/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/case_management/case_management.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/cases/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/cases/case.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/cases/case_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/cases/case_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/file_actions/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/file_actions/file_action_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/file_occurrences/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/file_occurrences/file_occurrence_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/filter_abc.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/group_attributes/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/group_attributes/group_attribute.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/group_attributes/group_attribute_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/group_attributes/group_attribute_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/groups/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/groups/group.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/groups/group_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/groups/group_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/indicator_attributes/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/indicator_attributes/indicator_attribute.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/indicator_attributes/indicator_attribute_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/indicator_attributes/indicator_attribute_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/indicators/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/indicators/indicator.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/indicators/indicator_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/indicators/indicator_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirement/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirement/ir.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/categories/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/categories/category.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/categories/category_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/categories/category_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/intel_req_type_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/intel_requirement.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/intel_requirement_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/intel_requirement_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/keyword_sections/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/keyword_sections/keyword_section_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/results/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/results/result.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/results/result_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/results/result_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/subtypes/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/subtypes/subtype.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/subtypes/subtype_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/intel_requirements/subtypes/subtype_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/notes/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/notes/note.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/notes/note_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/notes/note_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/object_abc.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/object_collection_abc.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/assignee_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/assignee_user_group_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/assignee_user_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/exclusion_lists/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/exclusion_lists/exclusion_list.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/exclusion_lists/exclusion_list_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/exclusion_lists/exclusion_list_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/owner_roles/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/owner_roles/owner_role.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/owner_roles/owner_role_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/owner_roles/owner_role_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/owners/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/owners/owner.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/owners/owner_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/owners/owner_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/security.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/system_roles/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/system_roles/system_role.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/system_roles/system_role_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/system_roles/system_role_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/task_assignee_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/user_groups/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/user_groups/user_group.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/user_groups/user_group_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/user_groups/user_group_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/users/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/users/user.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/users/user_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security/users/user_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security_labels/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security_labels/security_label.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security_labels/security_label_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/security_labels/security_label_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tags/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tags/default_naics_tags.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tags/mitre_tags.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tags/naics_tags.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tags/tag.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tags/tag_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tags/tag_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tasks/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tasks/task.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tasks/task_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tasks/task_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/threat_intelligence/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/threat_intelligence/threat_intelligence.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tql/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tql/tql.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tql/tql_operator.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/tql/tql_type.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/v3.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/v3_model_abc.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/v3_types.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/victim_assets/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/victim_assets/victim_asset.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/victim_assets/victim_asset_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/victim_assets/victim_asset_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/victim_attributes/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/victim_attributes/victim_attribute.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/victim_attributes/victim_attribute_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/victim_attributes/victim_attribute_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/victims/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/victims/victim.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/victims/victim_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/victims/victim_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/workflow_events/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/workflow_events/workflow_event.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/workflow_events/workflow_event_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/workflow_events/workflow_event_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/workflow_templates/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/workflow_templates/workflow_template.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/workflow_templates/workflow_template_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/api/tc/v3/workflow_templates/workflow_template_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/app.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/app_spec_yml.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/install_json.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/install_json_update.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/install_json_validate.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/job_json.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/layout_json.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/model/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/model/app_spec_yml_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/model/install_json_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/model/job_json_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/model/layout_json_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/model/tcex_json_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/permutation.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/tcex_json.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/config/tcex_json_update.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/decorator/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/decorator/benchmark.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/decorator/debug.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/decorator/fail_on_output.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/decorator/on_exception.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/decorator/on_success.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/decorator/output.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/key_value_store/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/key_value_store/key_value_abc.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/key_value_store/key_value_api.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/key_value_store/key_value_mock.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/key_value_store/key_value_redis.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/key_value_store/key_value_store.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/key_value_store/redis_client.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/key_value_store/redis_client_ssl.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/playbook/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/playbook/advanced_request.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/playbook/playbook.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/playbook/playbook_delete.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/playbook/playbook_output.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/playbook/playbook_read.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/service/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/service/api_service.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/service/common_service.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/service/common_service_trigger.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/service/mqtt_message_broker.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/service/webhook_trigger_service.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/token/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/app/token/token.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/exit/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/exit/error_code.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/exit/exit.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/binary.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/case_management_entity.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/choice.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/datetime.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/edit_choice.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/exception.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/group_entity.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/indicator_entity.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/integer.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/ip_address.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/key_value.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/sensitive.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/string.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/tc_entity.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/field_type/validator.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/input.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/advanced_request_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/api_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/app_api_service_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/app_external_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/app_feed_api_service_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/app_organization_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/app_playbook_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/app_system_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/app_trigger_service_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/app_webhook_trigger_service_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/batch_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/cal_setting_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/cert_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/common_advanced_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/common_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/create_config_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/logging_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/model_map.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/module_app_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/module_requests_session_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/organization_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/path_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/playbook_common_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/playbook_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/proxy_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/service_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/input/model/smtp_setting_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/logger/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/logger/api_handler.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/logger/cache_handler.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/logger/logger.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/logger/rotating_file_handler_custom.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/logger/sensitive_filter.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/logger/trace_logger.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/pleb/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/pleb/cached_property.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/pleb/event.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/pleb/exception_thread.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/pleb/none_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/pleb/proxies.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/pleb/scoped_property.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/pleb/singleton.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/registry.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/requests_external/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/requests_external/external_session.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/requests_external/rate_limit_handler.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/requests_external/requests_external.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/requests_tc/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/requests_tc/auth/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/requests_tc/auth/hmac_auth.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/requests_tc/auth/tc_auth.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/requests_tc/auth/token_auth.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/requests_tc/requests_tc.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/requests_tc/tc_session.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/tcex.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/aes_operation.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/datetime_operation.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/file_operation.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/model/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/model/playbook_variable_model.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/render/__init__.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/render/render.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/render/render_panel.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/render/render_prompt.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/render/render_table.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/requests_to_curl.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/string_operation.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/util.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex/util/variable.py +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex.egg-info/dependency_links.txt +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex.egg-info/requires.txt +0 -0
- {tcex-4.0.11.dev4 → tcex-4.0.11.dev5}/tcex.egg-info/top_level.txt +0 -0
|
@@ -77,7 +77,7 @@ dev = [
|
|
|
77
77
|
"typer>=0.15.1",
|
|
78
78
|
]
|
|
79
79
|
test = [
|
|
80
|
-
"deepdiff>=8.2
|
|
80
|
+
"deepdiff>=8.6.2",
|
|
81
81
|
"fakeredis>=2.27.0",
|
|
82
82
|
"pytest>=8.3.4",
|
|
83
83
|
"pytest-cov>=6.0.0",
|
|
@@ -180,6 +180,7 @@ reportPrivateImportUsage = false
|
|
|
180
180
|
|
|
181
181
|
# Configuration for pytest test runner
|
|
182
182
|
[tool.pytest.ini_options]
|
|
183
|
+
addopts = "-n auto"
|
|
183
184
|
filterwarnings = []
|
|
184
185
|
junit_family = "xunit2"
|
|
185
186
|
testpaths = [
|
|
@@ -5,7 +5,11 @@ from requests import Session # TYPE-CHECKING
|
|
|
5
5
|
|
|
6
6
|
# first-party
|
|
7
7
|
from tcex.api.tc.ti_transform import TiTransform, TiTransforms
|
|
8
|
-
from tcex.api.tc.ti_transform.model import
|
|
8
|
+
from tcex.api.tc.ti_transform.model import (
|
|
9
|
+
AssociationTransformModel,
|
|
10
|
+
GroupTransformModel,
|
|
11
|
+
IndicatorTransformModel,
|
|
12
|
+
)
|
|
9
13
|
from tcex.api.tc.util.threat_intel_util import ThreatIntelUtil
|
|
10
14
|
from tcex.api.tc.v2.v2 import V2
|
|
11
15
|
from tcex.api.tc.v3.v3 import V3
|
|
@@ -39,7 +43,7 @@ class TC:
|
|
|
39
43
|
@staticmethod
|
|
40
44
|
def ti_transform(
|
|
41
45
|
ti_dict: dict,
|
|
42
|
-
transforms: list[GroupTransformModel | IndicatorTransformModel],
|
|
46
|
+
transforms: list[AssociationTransformModel | GroupTransformModel | IndicatorTransformModel],
|
|
43
47
|
) -> TiTransform:
|
|
44
48
|
"""Return an instance of TI Transform class."""
|
|
45
49
|
return TiTransform(ti_dict, transforms)
|
|
@@ -47,13 +51,13 @@ class TC:
|
|
|
47
51
|
@staticmethod
|
|
48
52
|
def ti_transforms(
|
|
49
53
|
ti_dict: list[dict],
|
|
50
|
-
transforms: list[GroupTransformModel | IndicatorTransformModel],
|
|
54
|
+
transforms: list[AssociationTransformModel | GroupTransformModel | IndicatorTransformModel],
|
|
51
55
|
*,
|
|
52
|
-
|
|
56
|
+
separate_batch_associations: bool = False,
|
|
53
57
|
) -> TiTransforms:
|
|
54
58
|
"""Return an instance of TI Transforms class."""
|
|
55
59
|
return TiTransforms(
|
|
56
|
-
ti_dict, transforms,
|
|
60
|
+
ti_dict, transforms, separate_batch_associations=separate_batch_associations
|
|
57
61
|
)
|
|
58
62
|
|
|
59
63
|
@cached_property
|
|
@@ -129,7 +129,7 @@ class AssociatedIndicatorFromIndicatorTransform(BaseModel, extra=Extra.forbid):
|
|
|
129
129
|
"""."""
|
|
130
130
|
|
|
131
131
|
summary: str | MetadataTransformModel = Field(..., description='')
|
|
132
|
-
|
|
132
|
+
indicator_type: str | MetadataTransformModel = Field(..., description='')
|
|
133
133
|
association_type: str | MetadataTransformModel = Field(..., description='')
|
|
134
134
|
|
|
135
135
|
|
|
@@ -235,8 +235,88 @@ class IndicatorTransformModel(TiTransformModel, extra=Extra.forbid):
|
|
|
235
235
|
values.get('value3'),
|
|
236
236
|
]
|
|
237
237
|
):
|
|
238
|
-
ex_msg = (
|
|
239
|
-
|
|
240
|
-
|
|
238
|
+
ex_msg = 'An indicator transform must be defined (e.g., value1, value2, value3).'
|
|
239
|
+
raise ValueError(ex_msg)
|
|
240
|
+
return values
|
|
241
|
+
|
|
242
|
+
|
|
243
|
+
class GroupToGroupAssociation(BaseModel, extra=Extra.forbid):
|
|
244
|
+
"""."""
|
|
245
|
+
|
|
246
|
+
xid_1: MetadataTransformModel = Field(..., description='')
|
|
247
|
+
xid_2: MetadataTransformModel = Field(..., description='')
|
|
248
|
+
|
|
249
|
+
|
|
250
|
+
class GroupToIndicatorAssociation(BaseModel, extra=Extra.forbid):
|
|
251
|
+
"""."""
|
|
252
|
+
|
|
253
|
+
xid: MetadataTransformModel = Field(..., description='')
|
|
254
|
+
indicator_value: MetadataTransformModel = Field(..., description='')
|
|
255
|
+
indicator_type: MetadataTransformModel = Field(..., description='')
|
|
256
|
+
|
|
257
|
+
|
|
258
|
+
class IndicatorToIndicatorAssociation(BaseModel, extra=Extra.forbid):
|
|
259
|
+
"""."""
|
|
260
|
+
|
|
261
|
+
indicator_value_1: MetadataTransformModel = Field(..., description='')
|
|
262
|
+
indicator_type_1: MetadataTransformModel = Field(..., description='')
|
|
263
|
+
indicator_value_2: MetadataTransformModel = Field(..., description='')
|
|
264
|
+
indicator_type_2: MetadataTransformModel = Field(..., description='')
|
|
265
|
+
custom_association_type: MetadataTransformModel = Field(..., description='')
|
|
266
|
+
|
|
267
|
+
|
|
268
|
+
class AssociationTransformModel(BaseModel, extra='forbid'):
|
|
269
|
+
"""."""
|
|
270
|
+
|
|
271
|
+
applies: Callable | None = Field(None, description='')
|
|
272
|
+
associations: list[
|
|
273
|
+
GroupToGroupAssociation | GroupToIndicatorAssociation | IndicatorToIndicatorAssociation
|
|
274
|
+
] = Field(default_factory=list, description='')
|
|
275
|
+
|
|
276
|
+
# root validator to handle union of types in associations list
|
|
277
|
+
@root_validator(pre=True)
|
|
278
|
+
@classmethod
|
|
279
|
+
def _one_indicator_value(cls, values):
|
|
280
|
+
"""Validate that one set of credentials is provided for the TC API."""
|
|
281
|
+
association_types = {
|
|
282
|
+
GroupToGroupAssociation,
|
|
283
|
+
GroupToIndicatorAssociation,
|
|
284
|
+
IndicatorToIndicatorAssociation,
|
|
285
|
+
}
|
|
286
|
+
if associations := values.get('associations'):
|
|
287
|
+
validated_associations = []
|
|
288
|
+
for association in associations:
|
|
289
|
+
match association:
|
|
290
|
+
case (
|
|
291
|
+
GroupToGroupAssociation()
|
|
292
|
+
| GroupToIndicatorAssociation()
|
|
293
|
+
| IndicatorToIndicatorAssociation()
|
|
294
|
+
):
|
|
295
|
+
validated_associations.append(association)
|
|
296
|
+
case dict():
|
|
297
|
+
for association_type in association_types:
|
|
298
|
+
try:
|
|
299
|
+
validated_association = association_type(**association)
|
|
300
|
+
validated_associations.append(validated_association)
|
|
301
|
+
break
|
|
302
|
+
except Exception:
|
|
303
|
+
continue # nosec
|
|
304
|
+
else:
|
|
305
|
+
ex_msg = (
|
|
306
|
+
'Association must be one of the following types: '
|
|
307
|
+
f'{association_types}.'
|
|
308
|
+
)
|
|
309
|
+
raise ValueError(ex_msg)
|
|
310
|
+
|
|
311
|
+
case _:
|
|
312
|
+
ex_msg = (
|
|
313
|
+
f'Association must be one of the following types: {association_types}.'
|
|
314
|
+
)
|
|
315
|
+
raise ValueError(ex_msg)
|
|
316
|
+
|
|
317
|
+
values['associations'] = validated_associations
|
|
318
|
+
|
|
319
|
+
else:
|
|
320
|
+
ex_msg = 'At least one association must be defined.'
|
|
241
321
|
raise ValueError(ex_msg)
|
|
242
322
|
return values
|
|
@@ -4,9 +4,10 @@
|
|
|
4
4
|
import hashlib
|
|
5
5
|
import json
|
|
6
6
|
import uuid
|
|
7
|
+
import warnings
|
|
7
8
|
from collections.abc import Iterable
|
|
8
9
|
from inspect import _empty, signature
|
|
9
|
-
from typing import TypedDict
|
|
10
|
+
from typing import TYPE_CHECKING, TypedDict
|
|
10
11
|
|
|
11
12
|
# first-party
|
|
12
13
|
from tcex.api.tc.ti_transform.model.transform_model import (
|
|
@@ -14,6 +15,10 @@ from tcex.api.tc.ti_transform.model.transform_model import (
|
|
|
14
15
|
IndicatorTransformModel,
|
|
15
16
|
)
|
|
16
17
|
|
|
18
|
+
if TYPE_CHECKING:
|
|
19
|
+
# first-party
|
|
20
|
+
from tcex import TcEx
|
|
21
|
+
|
|
17
22
|
|
|
18
23
|
class TransformBuilderExport(TypedDict):
|
|
19
24
|
"""Basic definition of a transform exported from Transform Builder."""
|
|
@@ -23,10 +28,18 @@ class TransformBuilderExport(TypedDict):
|
|
|
23
28
|
|
|
24
29
|
|
|
25
30
|
def transform_builder_to_model(
|
|
26
|
-
transform: TransformBuilderExport,
|
|
27
|
-
processing_functions: 'ProcessingFunctions',
|
|
31
|
+
transform: TransformBuilderExport, processing_functions: 'ProcessingFunctions', **_kwargs
|
|
28
32
|
) -> IndicatorTransformModel | GroupTransformModel:
|
|
29
33
|
"""Convert a transform from Transform Builder to one of the tcex transform models."""
|
|
34
|
+
if not _kwargs.get('internal_call'):
|
|
35
|
+
warnings.warn(
|
|
36
|
+
(
|
|
37
|
+
'Use of transform_builder_to_model will be deprecated in tcex5. instead, use '
|
|
38
|
+
'tcex.api.tc.ti_transform.transform_builder.load'
|
|
39
|
+
),
|
|
40
|
+
PendingDeprecationWarning,
|
|
41
|
+
stacklevel=2,
|
|
42
|
+
)
|
|
30
43
|
|
|
31
44
|
def find_entries(data, key, context='') -> Iterable[tuple[str, dict]]:
|
|
32
45
|
"""Find entries in a dict with a given name, regardless of depth."""
|
|
@@ -98,9 +111,9 @@ def custom_function_definition(definition: FunctionDefinition):
|
|
|
98
111
|
class ProcessingFunctions:
|
|
99
112
|
"""Predefined functions to use in transforms."""
|
|
100
113
|
|
|
101
|
-
def __init__(self, tcex) -> None:
|
|
114
|
+
def __init__(self, tcex: 'TcEx') -> None:
|
|
102
115
|
"""."""
|
|
103
|
-
self.tcex = tcex
|
|
116
|
+
self.tcex: TcEx = tcex
|
|
104
117
|
self.custom_fns = {}
|
|
105
118
|
|
|
106
119
|
@custom_function_definition(
|
|
@@ -132,20 +145,9 @@ class ProcessingFunctions:
|
|
|
132
145
|
"""Allow for custom processing to be described."""
|
|
133
146
|
fn = self.custom_fns.get(name.lower())
|
|
134
147
|
if not fn:
|
|
135
|
-
ex_msg = f'Custom function not implemented: {
|
|
136
|
-
ex_msg += f'\ncustom_fns: {self.custom_fns}'
|
|
148
|
+
ex_msg = f'Custom function not implemented: {description}'
|
|
137
149
|
raise NotImplementedError(ex_msg)
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
# Build params dynamically based on the function signature
|
|
141
|
-
all_args = {'ti_dict': ti_dict, 'transform': transform, **kwargs}
|
|
142
|
-
sig_params = signature(fn).parameters
|
|
143
|
-
|
|
144
|
-
# Only pass arguments that the function accepts
|
|
145
|
-
filtered_args = {
|
|
146
|
-
k: v for k, v in all_args.items() if k in sig_params or 'kwargs' in sig_params
|
|
147
|
-
}
|
|
148
|
-
return fn(value, **filtered_args)
|
|
150
|
+
return fn(value, ti_dict=ti_dict, transform=transform, **kwargs)
|
|
149
151
|
|
|
150
152
|
def static_map(self, value, mapping: dict):
|
|
151
153
|
"""Map values to static values.
|
|
@@ -156,6 +158,22 @@ class ProcessingFunctions:
|
|
|
156
158
|
mapping = json.loads(mapping)
|
|
157
159
|
return mapping.get(str(value), value)
|
|
158
160
|
|
|
161
|
+
def deduplicate_array(self, value: list) -> list:
|
|
162
|
+
"""Remove duplicate values from an array."""
|
|
163
|
+
return list(set(value))
|
|
164
|
+
|
|
165
|
+
def slice_array(self, value: list, start: int = 0, end: int | None = None) -> list:
|
|
166
|
+
"""Slice an array."""
|
|
167
|
+
return value[start:end]
|
|
168
|
+
|
|
169
|
+
def remove_trailing_whitespace(self, value: str) -> str:
|
|
170
|
+
"""Remove trailing whitespace from a string."""
|
|
171
|
+
return value.rstrip()
|
|
172
|
+
|
|
173
|
+
def remove_leading_whitespace(self, value: str) -> str:
|
|
174
|
+
"""Remove leading whitespace from a string."""
|
|
175
|
+
return value.lstrip()
|
|
176
|
+
|
|
159
177
|
def value_in(self, value, values: str, delimiter: str = ','):
|
|
160
178
|
"""Return the value if it is in the list of values, else return None."""
|
|
161
179
|
if not values.startswith('"'):
|
|
@@ -183,6 +201,14 @@ class ProcessingFunctions:
|
|
|
183
201
|
|
|
184
202
|
return table
|
|
185
203
|
|
|
204
|
+
def defang(self, value: str) -> str:
|
|
205
|
+
"""Defangs URLs, IPs, and common indicators to make them inert."""
|
|
206
|
+
return self.tcex.util.defang(value)
|
|
207
|
+
|
|
208
|
+
def refang(self, value: str) -> str:
|
|
209
|
+
"""Refangs URLs, IPs, and common indicators to make them active."""
|
|
210
|
+
return self.tcex.util.refang(value)
|
|
211
|
+
|
|
186
212
|
def any_to_datetime(self, value):
|
|
187
213
|
"""Convert any value to a datetime object."""
|
|
188
214
|
return self.tcex.util.any_to_datetime(value).isoformat()
|
|
@@ -279,6 +305,7 @@ class ProcessingFunctions:
|
|
|
279
305
|
api_def['kwargs'][kwarg]
|
|
280
306
|
)
|
|
281
307
|
except Exception as ex:
|
|
308
|
+
# import here to avoid circular import
|
|
282
309
|
# first-party
|
|
283
310
|
from tcex.api.tc.ti_transform import TransformException # noqa: PLC0415
|
|
284
311
|
|
|
@@ -319,6 +346,15 @@ class ProcessingFunctions:
|
|
|
319
346
|
def _snake_to_titlecase(name):
|
|
320
347
|
return name.replace('_', ' ').title()
|
|
321
348
|
|
|
349
|
+
@staticmethod
|
|
350
|
+
def _get_type_string_from_annotation(annotation) -> str:
|
|
351
|
+
"""Get a string representation of a type annotation."""
|
|
352
|
+
if annotation is None:
|
|
353
|
+
return 'str'
|
|
354
|
+
if hasattr(annotation, '__name__'):
|
|
355
|
+
return annotation.__name__
|
|
356
|
+
return str(annotation)
|
|
357
|
+
|
|
322
358
|
@staticmethod
|
|
323
359
|
def _get_params_defs(fn) -> list[ParamDefinition]:
|
|
324
360
|
"""Get the arguments for a function.
|
|
@@ -338,8 +374,8 @@ class ProcessingFunctions:
|
|
|
338
374
|
),
|
|
339
375
|
'name': p,
|
|
340
376
|
'label': ProcessingFunctions._snake_to_titlecase(p),
|
|
341
|
-
'type': (
|
|
342
|
-
sig.parameters[p].annotation
|
|
377
|
+
'type': ProcessingFunctions._get_type_string_from_annotation(
|
|
378
|
+
sig.parameters[p].annotation
|
|
343
379
|
),
|
|
344
380
|
'help': '',
|
|
345
381
|
'required': True,
|
|
@@ -6,6 +6,7 @@ from datetime import datetime
|
|
|
6
6
|
# first-party
|
|
7
7
|
from tcex.api.tc.ti_transform.model import GroupTransformModel, IndicatorTransformModel
|
|
8
8
|
from tcex.api.tc.ti_transform.transform_abc import (
|
|
9
|
+
AssociationTransformModel,
|
|
9
10
|
NoValidTransformException,
|
|
10
11
|
TransformABC,
|
|
11
12
|
TransformException,
|
|
@@ -24,7 +25,7 @@ class TiTransforms(TransformsABC):
|
|
|
24
25
|
TiTransform(
|
|
25
26
|
ti_dict,
|
|
26
27
|
self.transforms,
|
|
27
|
-
|
|
28
|
+
separate_batch_associations=self.separate_batch_associations,
|
|
28
29
|
)
|
|
29
30
|
)
|
|
30
31
|
|
|
@@ -63,7 +64,9 @@ class TiTransforms(TransformsABC):
|
|
|
63
64
|
continue
|
|
64
65
|
|
|
65
66
|
# now that batch is called we can identify the ti type
|
|
66
|
-
if self.
|
|
67
|
+
if self.separate_batch_associations or isinstance(
|
|
68
|
+
t.transform, AssociationTransformModel
|
|
69
|
+
):
|
|
67
70
|
associations = data.pop('association', [])
|
|
68
71
|
batch.setdefault('association', []).extend(associations)
|
|
69
72
|
if isinstance(t.transform, GroupTransformModel):
|
|
@@ -117,33 +120,29 @@ class TiTransform(TransformABC):
|
|
|
117
120
|
|
|
118
121
|
def add_custom_association(self, summary: str, indicator_type: str, association_type: str):
|
|
119
122
|
"""Add a custom association."""
|
|
120
|
-
if
|
|
123
|
+
if self.separate_batch_associations:
|
|
124
|
+
self.transformed_item.setdefault('association', []).append(
|
|
125
|
+
{
|
|
126
|
+
'ref_1': self.transformed_item['summary'],
|
|
127
|
+
'type_1': self.transformed_item['type'],
|
|
128
|
+
'ref_2': summary,
|
|
129
|
+
'type_2': indicator_type,
|
|
130
|
+
'association_type': association_type,
|
|
131
|
+
}
|
|
132
|
+
)
|
|
133
|
+
else:
|
|
121
134
|
raise TransformException(
|
|
122
135
|
field='associatedIndicator',
|
|
123
136
|
cause=RuntimeError(
|
|
124
137
|
'Cannot add associated indicator to IndicatorTransformModel when '
|
|
125
|
-
'
|
|
138
|
+
'separate_batch_associations is False.'
|
|
126
139
|
),
|
|
127
140
|
context=self.transformed_item,
|
|
128
141
|
)
|
|
129
142
|
|
|
130
|
-
self.transformed_item.setdefault('association', []).append(
|
|
131
|
-
{
|
|
132
|
-
'ref_1': self.transformed_item['summary'],
|
|
133
|
-
'type_1': self.transformed_item['type'],
|
|
134
|
-
'ref_2': summary,
|
|
135
|
-
'type_2': indicator_type,
|
|
136
|
-
'association_type': association_type,
|
|
137
|
-
}
|
|
138
|
-
)
|
|
139
|
-
|
|
140
143
|
def add_associated_indicator(self, summary: str, indicator_type: str):
|
|
141
144
|
"""Add an associated indicator."""
|
|
142
|
-
if
|
|
143
|
-
self.transformed_item.setdefault('associatedIndicators', []).append(
|
|
144
|
-
{'summary': summary, 'indicatorType': indicator_type}
|
|
145
|
-
)
|
|
146
|
-
else:
|
|
145
|
+
if self.separate_batch_associations:
|
|
147
146
|
self.transformed_item.setdefault('association', []).append(
|
|
148
147
|
{
|
|
149
148
|
'ref_1': self.transformed_item['xid'],
|
|
@@ -151,8 +150,12 @@ class TiTransform(TransformABC):
|
|
|
151
150
|
'type_2': indicator_type,
|
|
152
151
|
}
|
|
153
152
|
)
|
|
153
|
+
else:
|
|
154
|
+
self.transformed_item.setdefault('associatedIndicators', []).append(
|
|
155
|
+
{'summary': summary, 'indicatorType': indicator_type}
|
|
156
|
+
)
|
|
154
157
|
|
|
155
|
-
def add_associated_group(self,
|
|
158
|
+
def add_associated_group(self, ref_1: str):
|
|
156
159
|
"""Add an associated group.
|
|
157
160
|
|
|
158
161
|
{
|
|
@@ -160,36 +163,36 @@ class TiTransform(TransformABC):
|
|
|
160
163
|
{
|
|
161
164
|
'groupXid': 'dd78f2b94ac61d3e5a55c1223a7635db00cd0aaa8aba26c5306e36dd6c1662ee'}
|
|
162
165
|
"""
|
|
163
|
-
if not self.
|
|
166
|
+
if not self.separate_batch_associations:
|
|
164
167
|
# process type specific data
|
|
165
168
|
if isinstance(self.transform, GroupTransformModel):
|
|
166
|
-
self.transformed_item.setdefault('associatedGroupXid', []).append(
|
|
169
|
+
self.transformed_item.setdefault('associatedGroupXid', []).append(ref_1)
|
|
167
170
|
elif isinstance(self.transform, IndicatorTransformModel):
|
|
168
|
-
associated_group = {'groupXid':
|
|
171
|
+
associated_group = {'groupXid': ref_1}
|
|
169
172
|
self.transformed_item.setdefault('associatedGroups', []).append(associated_group)
|
|
170
173
|
elif isinstance(self.transform, GroupTransformModel):
|
|
171
174
|
self.transformed_item.setdefault('association', []).append(
|
|
172
175
|
{
|
|
173
|
-
'ref_1':
|
|
176
|
+
'ref_1': ref_1,
|
|
174
177
|
'ref_2': self.transformed_item['xid'],
|
|
175
178
|
}
|
|
176
179
|
)
|
|
177
|
-
self.log.
|
|
180
|
+
self.log.trace(
|
|
178
181
|
'Added associated group with xid: %s to %s',
|
|
179
|
-
|
|
182
|
+
ref_1,
|
|
180
183
|
self.transformed_item['xid'],
|
|
181
184
|
)
|
|
182
185
|
elif isinstance(self.transform, IndicatorTransformModel):
|
|
183
186
|
self.transformed_item.setdefault('association', []).append(
|
|
184
187
|
{
|
|
185
|
-
'ref_1':
|
|
188
|
+
'ref_1': ref_1,
|
|
186
189
|
'ref_2': self.transformed_item['summary'],
|
|
187
190
|
'type_2': self.transformed_item['type'],
|
|
188
191
|
}
|
|
189
192
|
)
|
|
190
|
-
self.log.
|
|
193
|
+
self.log.trace(
|
|
191
194
|
'Added associated group with xid: %s to %s',
|
|
192
|
-
|
|
195
|
+
ref_1,
|
|
193
196
|
self.transformed_item['summary'],
|
|
194
197
|
)
|
|
195
198
|
|
|
@@ -339,7 +342,7 @@ class TiTransform(TransformABC):
|
|
|
339
342
|
}
|
|
340
343
|
del v3_data['attribute']
|
|
341
344
|
|
|
342
|
-
#
|
|
345
|
+
# transform tags
|
|
343
346
|
if v3_data.get('tag'):
|
|
344
347
|
v3_data['tags'] = {'data': [{'name': t['name']} for t in v3_data['tag']]}
|
|
345
348
|
del v3_data['tag']
|