You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: README.md
+4-2
Original file line number
Diff line number
Diff line change
@@ -90,7 +90,7 @@ The following arguments are available:
90
90
91
91
How the extractions are performed
92
92
93
-
*`--use_extractions` (REQUIRED): if you only want to use certain extraction types, you can pass their slug found in either `includes/ai/config.yaml`, `includes/lookup/config.yaml``includes/pattern/config.yaml` (e.g. `pattern_ipv4_address_only`). Default if not passed, no extractions applied. You can also pass a catch all wildcard `*` which will match all extraction paths (e.g. `pattern_*` would run all extractions starting with `pattern_`)
93
+
*`--use_extractions` (REQUIRED): if you only want to use certain extraction types, you can pass their slug found in either `includes/ai/config.yaml`, `includes/lookup/config.yaml``includes/pattern/config.yaml` (e.g. `pattern_ipv4_address_only`). Default if not passed, no extractions applied. You can also pass a catch all wildcard `*` which will match all extraction paths (e.g. `'pattern_*'` would run all extractions starting with `pattern_` -- make sure to use quotes when using a wildcard)
94
94
* Important: if using any AI extractions (`ai_*`), you must set an AI API key in your `.env` file
95
95
* Important: if you are using any MITRE ATT&CK, CAPEC, CWE, ATLAS or Location extractions you must set `CTIBUTLER` or NVD CPE or CVE extractions you must set `VULMATCH` settings in your `.env` file
96
96
*`--relationship_mode` (REQUIRED): either.
@@ -110,11 +110,13 @@ If any AI extractions, or AI relationship mode is set, you must set the followin
* See `tests/manual-tests/cases-ai-extraction-type.md` for some examples
115
115
*`--ai_settings_relationships`:
116
116
* similar to `ai_settings_extractions` but defines the model used to generate relationships. Only one model can be provided. Passed in same format as `ai_settings_extractions`
117
117
* See `tests/manual-tests/cases-ai-relationships.md` for some examples
118
+
*`--ai_check_content`: Passing this flag will get the AI to try and classify the text in the input to 1) determine if it is talking about threat intelligence, and 2) what type of threat intelligence it is talking about. For context, we use this to filter out non-threat intel posts in Obstracts and Stixify. You pass `provider:model` with this flag to determine the AI model you wish to use to perform the check.
119
+
*`--ai_create_attack_flow`: passing this flag will also prompt the AI model (the same entered for `--ai_settings_relationships`) to generate an [Attack Flow](https://center-for-threat-informed-defense.github.io/attack-flow/) for the MITRE ATT&CK extractions to define the logical order in which they are being described. You must pass `--ai_settings_relationships` for this to work.
Copy file name to clipboardexpand all lines: includes/extractions/ai/config.yaml
+5-5
Original file line number
Diff line number
Diff line change
@@ -725,7 +725,7 @@ ai_mitre_attack_enterprise:
725
725
version: 1.0.0
726
726
prompt_base: 'Extract all references to MITRE ATT&CK Enterprise tactics, techniques, groups, data sources, mitigations, software, and campaigns described in the text. These references may not be explicit in the text so you should be careful to account for the natural language of the text your analysis. Do not include MITRE ATT&CK ICS or MITRE ATT&CK Mobile in the results.'
727
727
prompt_helper: 'If you are unsure, you can learn more about MITRE ATT&CK Enterprise here: https://attack.mitre.org/matrices/enterprise/'
728
-
prompt_conversion: 'Convert all extractions into the corresponding ATT&CK ID.'
728
+
prompt_conversion: 'You should respond with only the ATT&CK ID.'
prompt_base: 'Extract all references to MITRE ATT&CK Mobile tactics, techniques, groups, data sources, mitigations, software, and campaigns described in the text. These references may not be explicit in the text so you should be careful to account for the natural language of the text your analysis. Do not include MITRE ATT&CK ICS or MITRE ATT&CK Enterprise in the results.'
742
742
prompt_helper: 'If you are unsure, you can learn more about MITRE ATT&CK Enterprise here: https://attack.mitre.org/matrices/mobile/'
743
-
prompt_conversion: 'Convert all extractions into the corresponding ATT&CK ID.'
743
+
prompt_conversion: 'You should respond with only the ATT&CK ID.'
744
744
test_cases: ai_mitre_attack_mobile
745
745
stix_mapping: ctibutler-mitre-attack-mobile-id
746
746
@@ -755,7 +755,7 @@ ai_mitre_attack_ics:
755
755
version: 1.0.0
756
756
prompt_base: 'Extract all references to MITRE ATT&CK ICS tactics, techniques, groups, data sources, mitigations, software, and campaigns described in the text. These references may not be explicit in the text so you should be careful to account for the natural language of the text your analysis. Do not include MITRE ATT&CK Mobile or MITRE ATT&CK Enterprise in the results.'
757
757
prompt_helper: 'If you are unsure, you can learn more about MITRE ATT&CK Enterprise here: https://attack.mitre.org/matrices/ics/'
758
-
prompt_conversion: 'Convert all extractions into the corresponding ATT&CK ID.'
758
+
prompt_conversion: 'You should respond with only the ATT&CK ID.'
759
759
test_cases: ai_mitre_attack_ics
760
760
stix_mapping: ctibutler-mitre-attack-ics-id
761
761
@@ -772,7 +772,7 @@ ai_mitre_capec:
772
772
version: 1.0.0
773
773
prompt_base: 'Extract all references to a MITRE CAPEC object from the text.'
774
774
prompt_helper: 'If you are unsure, you can learn more about MITRE CAPEC here: https://capec.mitre.org/'
775
-
prompt_conversion: 'Convert all extractions into the corresponding CAPEC ID in the format `CAPEC-ID`'
775
+
prompt_conversion: 'You should respond with only the CAPEC ID.'
776
776
test_cases: ai_mitre_capec
777
777
stix_mapping: ctibutler-mitre-capec-id
778
778
@@ -789,7 +789,7 @@ ai_mitre_cwe:
789
789
version: 1.0.0
790
790
prompt_base: 'Extract all references to a MITRE CWE object from the text.'
791
791
prompt_helper: 'If you are unsure, you can learn more about MITRE CAPEC here: https://cwe.mitre.org/'
792
-
prompt_conversion: 'Convert all extractions into the corresponding CWE ID in the format `CWE-ID`'
792
+
prompt_conversion: 'You should respond with only the CWE ID.'
description = "txt2stix is a Python script that is designed to identify and extract IoCs and TTPs from text files, identify the relationships between them, convert them to STIX 2.1 objects, and output as a STIX 2.1 bundle."
0 commit comments