A modern platform for visual, flexible, and extensible graph-based investigations. For cybersecurity analysts and investigators.
feat(core): progress on templates
dextmorgn3f252ea6ab57
diff --git a/flowsint-core/src/flowsint_core/core/template_enricher.py b/flowsint-core/src/flowsint_core/core/template_enricher.pyindex 59278258..9c84aa9e 100644--- a/flowsint-core/src/flowsint_core/core/template_enricher.py+++ b/flowsint-core/src/flowsint_core/core/template_enricher.py@@ -108,6 +108,7 @@ class TemplateEnricher(Enricher):self.OutputType = self._detect_type(self.template.output.type)self.request = self.template.requestself._resolved_secrets: Dict[str, str] = {}+ self.raw_response: Dict[str, Any] | None = None@staticmethoddef _build_params_schema_from_template(template: Template) -> List[Dict[str, Any]]:@@ -332,7 +333,15 @@ class TemplateEnricher(Enricher):)await asyncio.sleep(wait_time)continue-+ try:+ body = response.json()+ except Exception:+ body = response.text+ self.raw_response = {+ "status_code": response.status_code,+ "headers": dict(response.headers),+ "body": body,+ }response.raise_for_status()return response@@ -536,6 +545,9 @@ class TemplateEnricher(Enricher):)return results+ def get_raw_response(self) -> Dict[str, Any] | None:+ return self.raw_response+InputType = TemplateEnricher.InputTypeOutputType = TemplateEnricher.OutputType