A modern platform for visual, flexible, and extensible graph-based investigations. For cybersecurity analysts and investigators.
Fixes Maigret enricher missing display_name, bio, location, and created_at
Nickaec9dafa3abe
diff --git a/flowsint-enrichers/src/flowsint_enrichers/social/to_maigret.py b/flowsint-enrichers/src/flowsint_enrichers/social/to_maigret.pyindex 97f0759a..3b81e69b 100644--- a/flowsint-enrichers/src/flowsint_enrichers/social/to_maigret.py+++ b/flowsint-enrichers/src/flowsint_enrichers/social/to_maigret.py@@ -95,14 +95,24 @@ class MaigretEnricher(Enricher):except ValueError:followers = following = posts = None+ display_name = ids.get("fullname") or ids.get("nickname")+ if display_name:+ nodeLabel = f"{display_name} ({platform})"+ else:+ nodeLabel = None+try:results.append(SocialAccount(+ nodeLabel=nodeLabel,username=username_obj,+ display_name=display_name,profile_url=profile_url,- platform=platform,profile_picture_url=ids.get("image"),- bio=None,+ bio=ids.get("bio"),+ location=ids.get("location"),+ platform=platform,+ created_at=ids.get("created_at"),followers_count=followers,following_count=following,posts_count=posts,diff --git a/flowsint-types/src/flowsint_types/social_account.py b/flowsint-types/src/flowsint_types/social_account.pyindex 3bed5160..3830c298 100644--- a/flowsint-types/src/flowsint_types/social_account.py+++ b/flowsint-types/src/flowsint_types/social_account.py@@ -92,13 +92,20 @@ class SocialAccount(FlowsintType):self.id = f"{self.username.value}@{self.platform}"elif self.username:self.id = self.username.value- self.nodeLabel = self.id-- # Use display name if available, otherwise username- if self.display_name:- self.nodeLabel = f"{self.display_name} (@{self.username.value})"else:+ self.id = self.display_name or "unknown"++ # Only modify nodeLabel if it isn't set+ if not self.nodeLabel:self.nodeLabel = self.id++ # Use display name if available, otherwise username+ if self.display_name:+ if self.username:+ self.nodeLabel = f"{self.display_name} (@{self.username.value})"+ else:+ self.nodeLabel = self.display_name+return self@classmethod