[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7EFJWCF30JSSJEFDY1VM0G0":3,"skill-same:01M7EFJWCF30JSSJEFDY1VM0G0":73},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":45,"commitSha":46,"skillDirectory":47,"forksCount":48,"repositoryHtmlUrl":49,"repositoryHomepageUrl":6,"ownerHtmlUrl":50,"ownerBlogUrl":6,"ownerDescription":51,"updatedAt":52,"install":53,"resources":66},"01M7EFJWCF30JSSJEFDY1VM0G0","building-threat-feed-aggregation-with-misp",null,"Deploy MISP via Docker and configure feeds from sources like abuse.ch, AlienVault OTX, and CIRCL to aggregate, correlate, and distribute threat intelligence, including automated feed synchronization and STIX\u002FTAXII-based integration with Splunk, Elasticsearch, and SOAR platforms. Use when standing up centralized IOC management or wiring multi-source threat feeds into a SIEM.","lza6\u002FArmor-piercing-system-prompts","lza6","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F128880206?v=4","01M7EB3K7WPX5T28EJ2NVHE6EG","Chinese-tingfeng","01M7EB3K97E1KQ16QWKJMFNGX8",11,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F04-安全渗透\u002Fbuilding-threat-feed-aggregation-with-misp\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: building-threat-feed-aggregation-with-misp\ndescription: Deploy MISP via Docker and configure feeds from sources like abuse.ch, AlienVault OTX, and CIRCL to aggregate, correlate, and distribute threat intelligence, including automated feed synchronization and STIX\u002FTAXII-based integration with Splunk, Elasticsearch, and SOAR platforms. Use when standing up centralized IOC management or wiring multi-source threat feeds into a SIEM.\ndomain: cybersecurity\nsubdomain: threat-intelligence\ntags:\n- misp\n- threat-feed\n- aggregation\n- indicator\n- sharing\n- correlation\n- siem-integration\n- threat-intelligence\nversion: '1.0'\nauthor: mahipal\nlicense: Apache-2.0\nnist_csf:\n- ID.RA-01\n- ID.RA-05\n- DE.CM-01\n- DE.AE-02\nmitre_attack:\n- T1071\n- T1105\n- T1588.001\n---\n# Building Threat Feed Aggregation with MISP\n\n## Overview\n\nMISP is the leading open-source threat intelligence platform for collecting, storing, distributing, and sharing cybersecurity indicators and threat intelligence. It aggregates feeds from OSINT sources, commercial providers, and sharing communities into a unified platform with automatic correlation, STIX\u002FTAXII export, and direct integration with SIEMs and security tools. This skill covers deploying MISP via Docker, configuring feeds from sources like abuse.ch, AlienVault OTX, and CIRCL, setting up automated feed synchronization, and integrating with Splunk, Elasticsearch, and SOAR platforms.\n\n\n## When to Use\n\n- When deploying or configuring building threat feed aggregation with misp capabilities in your environment\n- When establishing security controls aligned to compliance requirements\n- When building or improving security architecture for this domain\n- When conducting security assessments that require this implementation\n\n## Prerequisites\n\n- Docker and Docker Compose for deployment\n- Python 3.9+ with `pymisp` library for API interaction\n- Linux server with 8GB+ RAM for production deployment\n- Understanding of IOC types and threat intelligence lifecycle\n- Network access to external feed URLs\n\n## Key Concepts\n\n### MISP Architecture\n\nMISP stores threat intelligence as Events containing Attributes (IOCs) organized by type and category. Events can have Tags (MITRE ATT&CK, TLP marking, sector tags), Galaxies (threat actor profiles, malware families, attack patterns), and Objects (structured groupings of related attributes). Events are correlated automatically across the instance.\n\n### Feed Types\n\nMISP supports three feed formats: MISP format (native JSON events), CSV (comma-separated IOCs), and freetext (unstructured text with automatic IOC extraction). Feeds can be remote (fetched from URLs) or local (uploaded files). MISP ships with 80+ default OSINT feeds including abuse.ch URLhaus, Botvrij, CIRCL OSINT, and malware traffic analysis.\n\n### Sharing and Synchronization\n\nMISP instances can synchronize with other MISP instances via push\u002Fpull mechanisms. Sharing groups control distribution (organization only, this community, connected communities, all communities). The TAXII server module enables integration with STIX\u002FTAXII consumers.\n\n## Workflow\n\n### Step 1: Deploy MISP with Docker\n\n```yaml\n# docker-compose.yml for MISP deployment\nversion: '3.8'\nservices:\n  misp:\n    image: coolacid\u002Fmisp-docker:core-latest\n    container_name: misp\n    restart: unless-stopped\n    ports:\n      - \"443:443\"\n      - \"80:80\"\n    environment:\n      - MYSQL_HOST=misp-db\n      - MYSQL_DATABASE=misp\n      - MYSQL_USER=misp\n      - MYSQL_PASSWORD=misp_db_password_change_me\n      - MISP_ADMIN_EMAIL=admin@organization.com\n      - MISP_ADMIN_PASSPHRASE=admin_password_change_me\n      - MISP_BASEURL=https:\u002F\u002Fmisp.organization.com\n      - POSTFIX_RELAY_HOST=smtp.organization.com\n      - TIMEZONE=UTC\n    volumes:\n      - misp-data:\u002Fvar\u002Fwww\u002FMISP\u002Fapp\u002Ffiles\n      - misp-config:\u002Fvar\u002Fwww\u002FMISP\u002Fapp\u002FConfig\n    depends_on:\n      - misp-db\n      - misp-redis\n\n  misp-db:\n    image: mysql:8.0\n    container_name: misp-db\n    restart: unless-stopped\n    environment:\n      - MYSQL_DATABASE=misp\n      - MYSQL_USER=misp\n      - MYSQL_PASSWORD=misp_db_password_change_me\n      - MYSQL_ROOT_PASSWORD=root_password_change_me\n    volumes:\n      - misp-db-data:\u002Fvar\u002Flib\u002Fmysql\n\n  misp-redis:\n    image: redis:7\n    container_name: misp-redis\n    restart: unless-stopped\n\nvolumes:\n  misp-data:\n  misp-config:\n  misp-db-data:\n```\n\n### Step 2: Configure Feeds via PyMISP API\n\n```python\nfrom pymisp import PyMISP, MISPFeed\nimport json\n\nclass MISPFeedManager:\n    def __init__(self, misp_url, misp_key, verify_ssl=False):\n        self.misp = PyMISP(misp_url, misp_key, verify_ssl)\n        print(f\"[+] Connected to MISP: {misp_url}\")\n\n    def list_feeds(self):\n        \"\"\"List all configured feeds.\"\"\"\n        feeds = self.misp.feeds()\n        enabled = [f for f in feeds if f.get(\"Feed\", {}).get(\"enabled\")]\n        disabled = [f for f in feeds if not f.get(\"Feed\", {}).get(\"enabled\")]\n        print(f\"[+] Feeds: {len(enabled)} enabled, {len(disabled)} disabled\")\n        return feeds\n\n    def enable_default_feeds(self):\n        \"\"\"Enable recommended default OSINT feeds.\"\"\"\n        recommended_feeds = [\n            \"CIRCL OSINT Feed\",\n            \"Botvrij.eu - Indicators of Compromise\",\n            \"abuse.ch URLhaus Host file\",\n            \"abuse.ch Feodo Tracker\",\n            \"abuse.ch SSL Blacklist\",\n            \"malwaredomainlist\",\n            \"CyberCure - IP Feed\",\n        ]\n\n        feeds = self.misp.feeds()\n        enabled_count = 0\n        for feed in feeds:\n            feed_data = feed.get(\"Feed\", {})\n            if feed_data.get(\"name\") in recommended_feeds:\n                if not feed_data.get(\"enabled\"):\n                    self.misp.enable_feed(feed_data[\"id\"])\n                    self.misp.enable_feed_cache(feed_data[\"id\"])\n                    enabled_count += 1\n                    print(f\"  [+] Enabled: {feed_data['name']}\")\n\n        print(f\"[+] Enabled {enabled_count} feeds\")\n\n    def add_custom_feed(self, name, url, provider, feed_format=\"csv\",\n                        input_source=\"network\", enabled=True):\n        \"\"\"Add a custom threat intelligence feed.\"\"\"\n        feed = MISPFeed()\n        feed.name = name\n        feed.provider = provider\n        feed.url = url\n        feed.source_format = feed_format\n        feed.input_source = input_source\n        feed.enabled = enabled\n        feed.caching_enabled = True\n        feed.publish = False\n        feed.distribution = \"3\"  # All communities\n\n        result = self.misp.add_feed(feed)\n        if \"Feed\" in result:\n            feed_id = result[\"Feed\"][\"id\"]\n            print(f\"[+] Added feed: {name} (ID: {feed_id})\")\n            return feed_id\n        else:\n            print(f\"[-] Error adding feed: {result}\")\n            return None\n\n    def fetch_all_feeds(self):\n        \"\"\"Trigger fetch for all enabled feeds.\"\"\"\n        feeds = self.misp.feeds()\n        for feed in feeds:\n            feed_data = feed.get(\"Feed\", {})\n            if feed_data.get(\"enabled\"):\n                self.misp.fetch_feed(feed_data[\"id\"])\n                print(f\"  [*] Fetching: {feed_data['name']}\")\n        print(\"[+] Feed fetch triggered for all enabled feeds\")\n\nmanager = MISPFeedManager(\n    \"https:\u002F\u002Fmisp.organization.com\",\n    \"YOUR_MISP_API_KEY\",\n)\nmanager.enable_default_feeds()\nmanager.add_custom_feed(\n    name=\"Abuse.ch MalwareBazaar Recent\",\n    url=\"https:\u002F\u002Fbazaar.abuse.ch\u002Fexport\u002Fcsv\u002Frecent\u002F\",\n    provider=\"abuse.ch\",\n    feed_format=\"csv\",\n)\nmanager.fetch_all_feeds()\n```\n\n### Step 3: Search and Correlate Indicators\n\n```python\ndef search_indicators(misp, value=None, type_attribute=None, tags=None, last_days=30):\n    \"\"\"Search MISP for indicators with correlation.\"\"\"\n    from datetime import datetime, timedelta\n    date_from = (datetime.now() - timedelta(days=last_days)).strftime(\"%Y-%m-%d\")\n\n    search_params = {\n        \"date_from\": date_from,\n        \"published\": True,\n        \"enforceWarninglist\": True,\n    }\n    if value:\n        search_params[\"value\"] = value\n    if type_attribute:\n        search_params[\"type_attribute\"] = type_attribute\n    if tags:\n        search_params[\"tags\"] = tags\n\n    results = misp.search(\"attributes\", **search_params)\n    attributes = results.get(\"Attribute\", [])\n    print(f\"[+] Search returned {len(attributes)} attributes\")\n\n    # Group by event for context\n    events = {}\n    for attr in attributes:\n        event_id = attr.get(\"event_id\", \"\")\n        if event_id not in events:\n            events[event_id] = {\"attributes\": [], \"tags\": set()}\n        events[event_id][\"attributes\"].append({\n            \"type\": attr.get(\"type\", \"\"),\n            \"value\": attr.get(\"value\", \"\"),\n            \"category\": attr.get(\"category\", \"\"),\n            \"timestamp\": attr.get(\"timestamp\", \"\"),\n        })\n        for tag in attr.get(\"Tag\", []):\n            events[event_id][\"tags\"].add(tag.get(\"name\", \"\"))\n\n    return {\"attributes\": attributes, \"events\": events}\n\n# Search for specific IOC\nmisp = manager.misp\nresults = search_indicators(misp, value=\"203.0.113.1\")\nresults_by_type = search_indicators(misp, type_attribute=\"ip-dst\", last_days=7)\nresults_by_tag = search_indicators(misp, tags=[\"tlp:white\", \"type:OSINT\"])\n```\n\n### Step 4: Export to SIEM (Splunk \u002F Elasticsearch)\n\n```python\nimport requests\nfrom datetime import datetime, timedelta\n\nclass MISPSIEMExporter:\n    def __init__(self, misp_client):\n        self.misp = misp_client\n\n    def export_to_splunk(self, splunk_url, hec_token, days=7):\n        \"\"\"Export recent MISP indicators to Splunk via HEC.\"\"\"\n        date_from = (datetime.now() - timedelta(days=days)).strftime(\"%Y-%m-%d\")\n        results = self.misp.search(\"attributes\", date_from=date_from,\n                                    published=True, enforceWarninglist=True)\n        attributes = results.get(\"Attribute\", [])\n\n        headers = {\"Authorization\": f\"Splunk {hec_token}\"}\n        exported = 0\n        for attr in attributes:\n            event = {\n                \"event\": {\n                    \"ioc_type\": attr.get(\"type\", \"\"),\n                    \"ioc_value\": attr.get(\"value\", \"\"),\n                    \"category\": attr.get(\"category\", \"\"),\n                    \"event_id\": attr.get(\"event_id\", \"\"),\n                    \"timestamp\": attr.get(\"timestamp\", \"\"),\n                    \"tags\": [t.get(\"name\", \"\") for t in attr.get(\"Tag\", [])],\n                },\n                \"sourcetype\": \"misp:attribute\",\n                \"source\": \"misp\",\n                \"index\": \"threat_intel\",\n            }\n            resp = requests.post(\n                f\"{splunk_url}\u002Fservices\u002Fcollector\u002Fevent\",\n                headers=headers, json=event,\n                verify=not os.environ.get(\"SKIP_TLS_VERIFY\", \"\").lower() == \"true\",  # Set SKIP_TLS_VERIFY=true for self-signed certs in lab environments\n            )\n            if resp.status_code == 200:\n                exported += 1\n\n        print(f\"[+] Exported {exported}\u002F{len(attributes)} indicators to Splunk\")\n\n    def export_ioc_list(self, output_file, ioc_types=None, days=30):\n        \"\"\"Export flat IOC list for firewall\u002Fproxy blocklists.\"\"\"\n        ioc_types = ioc_types or [\"ip-dst\", \"domain\", \"hostname\", \"url\"]\n        date_from = (datetime.now() - timedelta(days=days)).strftime(\"%Y-%m-%d\")\n\n        all_iocs = []\n        for ioc_type in ioc_types:\n            results = self.misp.search(\n                \"attributes\", type_attribute=ioc_type,\n                date_from=date_from, published=True,\n                enforceWarninglist=True,\n            )\n            for attr in results.get(\"Attribute\", []):\n                all_iocs.append(attr.get(\"value\", \"\"))\n\n        unique_iocs = sorted(set(all_iocs))\n        with open(output_file, \"w\") as f:\n            for ioc in unique_iocs:\n                f.write(f\"{ioc}\\n\")\n\n        print(f\"[+] Exported {len(unique_iocs)} unique IOCs to {output_file}\")\n\nexporter = MISPSIEMExporter(misp)\nexporter.export_ioc_list(\"blocklist_ips.txt\", ioc_types=[\"ip-dst\"], days=7)\n```\n\n## Validation Criteria\n\n- MISP deployed and accessible via web interface and API\n- Default OSINT feeds enabled and fetching data\n- Custom feeds added and ingesting indicators\n- Indicators searchable with correlation across events\n- IOCs exported to SIEM (Splunk\u002FElasticsearch) successfully\n- Blocklists generated for firewall\u002Fproxy integration\n\n## References\n\n- [MISP Project](https:\u002F\u002Fwww.misp-project.org\u002F)\n- [MISP GitHub Repository](https:\u002F\u002Fgithub.com\u002FMISP\u002FMISP)\n- [MISP Default Feeds](https:\u002F\u002Fwww.misp-project.org\u002Ffeeds\u002F)\n- [PyMISP Documentation](https:\u002F\u002Fpymisp.readthedocs.io\u002F)\n- [Kraven Security: MISP Using Feeds](https:\u002F\u002Fkravensecurity.com\u002Fthreat-intelligence-with-misp-part-4-using-feeds\u002F)\n- [Cosive: What is MISP](https:\u002F\u002Fwww.cosive.com\u002Fblog\u002Fwhat-is-misp-the-ultimate-introduction)\n","# Building Threat Feed Aggregation with MISP\n\n## Overview\n\nMISP is the leading open-source threat intelligence platform for collecting, storing, distributing, and sharing cybersecurity indicators and threat intelligence. It aggregates feeds from OSINT sources, commercial providers, and sharing communities into a unified platform with automatic correlation, STIX\u002FTAXII export, and direct integration with SIEMs and security tools. This skill covers deploying MISP via Docker, configuring feeds from sources like abuse.ch, AlienVault OTX, and CIRCL, setting up automated feed synchronization, and integrating with Splunk, Elasticsearch, and SOAR platforms.\n\n\n## When to Use\n\n- When deploying or configuring building threat feed aggregation with misp capabilities in your environment\n- When establishing security controls aligned to compliance requirements\n- When building or improving security architecture for this domain\n- When conducting security assessments that require this implementation\n\n## Prerequisites\n\n- Docker and Docker Compose for deployment\n- Python 3.9+ with `pymisp` library for API interaction\n- Linux server with 8GB+ RAM for production deployment\n- Understanding of IOC types and threat intelligence lifecycle\n- Network access to external feed URLs\n\n## Key Concepts\n\n### MISP Architecture\n\nMISP stores threat intelligence as Events containing Attributes (IOCs) organized by type and category. Events can have Tags (MITRE ATT&CK, TLP marking, sector tags), Galaxies (threat actor profiles, malware families, attack patterns), and Objects (structured groupings of related attributes). Events are correlated automatically across the instance.\n\n### Feed Types\n\nMISP supports three feed formats: MISP format (native JSON events), CSV (comma-separated IOCs), and freetext (unstructured text with automatic IOC extraction). Feeds can be remote (fetched from URLs) or local (uploaded files). MISP ships with 80+ default OSINT feeds including abuse.ch URLhaus, Botvrij, CIRCL OSINT, and malware traffic analysis.\n\n### Sharing and Synchronization\n\nMISP instances can synchronize with other MISP instances via push\u002Fpull mechanisms. Sharing groups control distribution (organization only, this community, connected communities, all communities). The TAXII server module enables integration with STIX\u002FTAXII consumers.\n\n## Workflow\n\n### Step 1: Deploy MISP with Docker\n\n```yaml\n# docker-compose.yml for MISP deployment\nversion: '3.8'\nservices:\n  misp:\n    image: coolacid\u002Fmisp-docker:core-latest\n    container_name: misp\n    restart: unless-stopped\n    ports:\n      - \"443:443\"\n      - \"80:80\"\n    environment:\n      - MYSQL_HOST=misp-db\n      - MYSQL_DATABASE=misp\n      - MYSQL_USER=misp\n      - MYSQL_PASSWORD=misp_db_password_change_me\n      - MISP_ADMIN_EMAIL=admin@organization.com\n      - MISP_ADMIN_PASSPHRASE=admin_password_change_me\n      - MISP_BASEURL=https:\u002F\u002Fmisp.organization.com\n      - POSTFIX_RELAY_HOST=smtp.organization.com\n      - TIMEZONE=UTC\n    volumes:\n      - misp-data:\u002Fvar\u002Fwww\u002FMISP\u002Fapp\u002Ffiles\n      - misp-config:\u002Fvar\u002Fwww\u002FMISP\u002Fapp\u002FConfig\n    depends_on:\n      - misp-db\n      - misp-redis\n\n  misp-db:\n    image: mysql:8.0\n    container_name: misp-db\n    restart: unless-stopped\n    environment:\n      - MYSQL_DATABASE=misp\n      - MYSQL_USER=misp\n      - MYSQL_PASSWORD=misp_db_password_change_me\n      - MYSQL_ROOT_PASSWORD=root_password_change_me\n    volumes:\n      - misp-db-data:\u002Fvar\u002Flib\u002Fmysql\n\n  misp-redis:\n    image: redis:7\n    container_name: misp-redis\n    restart: unless-stopped\n\nvolumes:\n  misp-data:\n  misp-config:\n  misp-db-data:\n```\n\n### Step 2: Configure Feeds via PyMISP API\n\n```python\nfrom pymisp import PyMISP, MISPFeed\nimport json\n\nclass MISPFeedManager:\n    def __init__(self, misp_url, misp_key, verify_ssl=False):\n        self.misp = PyMISP(misp_url, misp_key, verify_ssl)\n        print(f\"[+] Connected to MISP: {misp_url}\")\n\n    def list_feeds(self):\n        \"\"\"List all configured feeds.\"\"\"\n        feeds = self.misp.feeds()\n        enabled = [f for f in feeds if f.get(\"Feed\", {}).get(\"enabled\")]\n        disabled = [f for f in feeds if not f.get(\"Feed\", {}).get(\"enabled\")]\n        print(f\"[+] Feeds: {len(enabled)} enabled, {len(disabled)} disabled\")\n        return feeds\n\n    def enable_default_feeds(self):\n        \"\"\"Enable recommended default OSINT feeds.\"\"\"\n        recommended_feeds = [\n            \"CIRCL OSINT Feed\",\n            \"Botvrij.eu - Indicators of Compromise\",\n            \"abuse.ch URLhaus Host file\",\n            \"abuse.ch Feodo Tracker\",\n            \"abuse.ch SSL Blacklist\",\n            \"malwaredomainlist\",\n            \"CyberCure - IP Feed\",\n        ]\n\n        feeds = self.misp.feeds()\n        enabled_count = 0\n        for feed in feeds:\n            feed_data = feed.get(\"Feed\", {})\n            if feed_data.get(\"name\") in recommended_feeds:\n                if not feed_data.get(\"enabled\"):\n                    self.misp.enable_feed(feed_data[\"id\"])\n                    self.misp.enable_feed_cache(feed_data[\"id\"])\n                    enabled_count += 1\n                    print(f\"  [+] Enabled: {feed_data['name']}\")\n\n        print(f\"[+] Enabled {enabled_count} feeds\")\n\n    def add_custom_feed(self, name, url, provider, feed_format=\"csv\",\n                        input_source=\"network\", enabled=True):\n        \"\"\"Add a custom threat intelligence feed.\"\"\"\n        feed = MISPFeed()\n        feed.name = name\n        feed.provider = provider\n        feed.url = url\n        feed.source_format = feed_format\n        feed.input_source = input_source\n        feed.enabled = enabled\n        feed.caching_enabled = True\n        feed.publish = False\n        feed.distribution = \"3\"  # All communities\n\n        result = self.misp.add_feed(feed)\n        if \"Feed\" in result:\n            feed_id = result[\"Feed\"][\"id\"]\n            print(f\"[+] Added feed: {name} (ID: {feed_id})\")\n            return feed_id\n        else:\n            print(f\"[-] Error adding feed: {result}\")\n            return None\n\n    def fetch_all_feeds(self):\n        \"\"\"Trigger fetch for all enabled feeds.\"\"\"\n        feeds = self.misp.feeds()\n        for feed in feeds:\n            feed_data = feed.get(\"Feed\", {})\n            if feed_data.get(\"enabled\"):\n                self.misp.fetch_feed(feed_data[\"id\"])\n                print(f\"  [*] Fetching: {feed_data['name']}\")\n        print(\"[+] Feed fetch triggered for all enabled feeds\")\n\nmanager = MISPFeedManager(\n    \"https:\u002F\u002Fmisp.organization.com\",\n    \"YOUR_MISP_API_KEY\",\n)\nmanager.enable_default_feeds()\nmanager.add_custom_feed(\n    name=\"Abuse.ch MalwareBazaar Recent\",\n    url=\"https:\u002F\u002Fbazaar.abuse.ch\u002Fexport\u002Fcsv\u002Frecent\u002F\",\n    provider=\"abuse.ch\",\n    feed_format=\"csv\",\n)\nmanager.fetch_all_feeds()\n```\n\n### Step 3: Search and Correlate Indicators\n\n```python\ndef search_indicators(misp, value=None, type_attribute=None, tags=None, last_days=30):\n    \"\"\"Search MISP for indicators with correlation.\"\"\"\n    from datetime import datetime, timedelta\n    date_from = (datetime.now() - timedelta(days=last_days)).strftime(\"%Y-%m-%d\")\n\n    search_params = {\n        \"date_from\": date_from,\n        \"published\": True,\n        \"enforceWarninglist\": True,\n    }\n    if value:\n        search_params[\"value\"] = value\n    if type_attribute:\n        search_params[\"type_attribute\"] = type_attribute\n    if tags:\n        search_params[\"tags\"] = tags\n\n    results = misp.search(\"attributes\", **search_params)\n    attributes = results.get(\"Attribute\", [])\n    print(f\"[+] Search returned {len(attributes)} attributes\")\n\n    # Group by event for context\n    events = {}\n    for attr in attributes:\n        event_id = attr.get(\"event_id\", \"\")\n        if event_id not in events:\n            events[event_id] = {\"attributes\": [], \"tags\": set()}\n        events[event_id][\"attributes\"].append({\n            \"type\": attr.get(\"type\", \"\"),\n            \"value\": attr.get(\"value\", \"\"),\n            \"category\": attr.get(\"category\", \"\"),\n            \"timestamp\": attr.get(\"timestamp\", \"\"),\n        })\n        for tag in attr.get(\"Tag\", []):\n            events[event_id][\"tags\"].add(tag.get(\"name\", \"\"))\n\n    return {\"attributes\": attributes, \"events\": events}\n\n# Search for specific IOC\nmisp = manager.misp\nresults = search_indicators(misp, value=\"203.0.113.1\")\nresults_by_type = search_indicators(misp, type_attribute=\"ip-dst\", last_days=7)\nresults_by_tag = search_indicators(misp, tags=[\"tlp:white\", \"type:OSINT\"])\n```\n\n### Step 4: Export to SIEM (Splunk \u002F Elasticsearch)\n\n```python\nimport requests\nfrom datetime import datetime, timedelta\n\nclass MISPSIEMExporter:\n    def __init__(self, misp_client):\n        self.misp = misp_client\n\n    def export_to_splunk(self, splunk_url, hec_token, days=7):\n        \"\"\"Export recent MISP indicators to Splunk via HEC.\"\"\"\n        date_from = (datetime.now() - timedelta(days=days)).strftime(\"%Y-%m-%d\")\n        results = self.misp.search(\"attributes\", date_from=date_from,\n                                    published=True, enforceWarninglist=True)\n        attributes = results.get(\"Attribute\", [])\n\n        headers = {\"Authorization\": f\"Splunk {hec_token}\"}\n        exported = 0\n        for attr in attributes:\n            event = {\n                \"event\": {\n                    \"ioc_type\": attr.get(\"type\", \"\"),\n                    \"ioc_value\": attr.get(\"value\", \"\"),\n                    \"category\": attr.get(\"category\", \"\"),\n                    \"event_id\": attr.get(\"event_id\", \"\"),\n                    \"timestamp\": attr.get(\"timestamp\", \"\"),\n                    \"tags\": [t.get(\"name\", \"\") for t in attr.get(\"Tag\", [])],\n                },\n                \"sourcetype\": \"misp:attribute\",\n                \"source\": \"misp\",\n                \"index\": \"threat_intel\",\n            }\n            resp = requests.post(\n                f\"{splunk_url}\u002Fservices\u002Fcollector\u002Fevent\",\n                headers=headers, json=event,\n                verify=not os.environ.get(\"SKIP_TLS_VERIFY\", \"\").lower() == \"true\",  # Set SKIP_TLS_VERIFY=true for self-signed certs in lab environments\n            )\n            if resp.status_code == 200:\n                exported += 1\n\n        print(f\"[+] Exported {exported}\u002F{len(attributes)} indicators to Splunk\")\n\n    def export_ioc_list(self, output_file, ioc_types=None, days=30):\n        \"\"\"Export flat IOC list for firewall\u002Fproxy blocklists.\"\"\"\n        ioc_types = ioc_types or [\"ip-dst\", \"domain\", \"hostname\", \"url\"]\n        date_from = (datetime.now() - timedelta(days=days)).strftime(\"%Y-%m-%d\")\n\n        all_iocs = []\n        for ioc_type in ioc_types:\n            results = self.misp.search(\n                \"attributes\", type_attribute=ioc_type,\n                date_from=date_from, published=True,\n                enforceWarninglist=True,\n            )\n            for attr in results.get(\"Attribute\", []):\n                all_iocs.append(attr.get(\"value\", \"\"))\n\n        unique_iocs = sorted(set(all_iocs))\n        with open(output_file, \"w\") as f:\n            for ioc in unique_iocs:\n                f.write(f\"{ioc}\\n\")\n\n        print(f\"[+] Exported {len(unique_iocs)} unique IOCs to {output_file}\")\n\nexporter = MISPSIEMExporter(misp)\nexporter.export_ioc_list(\"blocklist_ips.txt\", ioc_types=[\"ip-dst\"], days=7)\n```\n\n## Validation Criteria\n\n- MISP deployed and accessible via web interface and API\n- Default OSINT feeds enabled and fetching data\n- Custom feeds added and ingesting indicators\n- Indicators searchable with correlation across events\n- IOCs exported to SIEM (Splunk\u002FElasticsearch) successfully\n- Blocklists generated for firewall\u002Fproxy integration\n\n## References\n\n- [MISP Project](https:\u002F\u002Fwww.misp-project.org\u002F)\n- [MISP GitHub Repository](https:\u002F\u002Fgithub.com\u002FMISP\u002FMISP)\n- [MISP Default Feeds](https:\u002F\u002Fwww.misp-project.org\u002Ffeeds\u002F)\n- [PyMISP Documentation](https:\u002F\u002Fpymisp.readthedocs.io\u002F)\n- [Kraven Security: MISP Using Feeds](https:\u002F\u002Fkravensecurity.com\u002Fthreat-intelligence-with-misp-part-4-using-feeds\u002F)\n- [Cosive: What is MISP](https:\u002F\u002Fwww.cosive.com\u002Fblog\u002Fwhat-is-misp-the-ultimate-introduction)\n",{"name":5,"tags":24,"author":33,"domain":34,"license":15,"version":35,"nist_csf":36,"subdomain":32,"description":7,"mitre_attack":41},[25,26,27,28,29,30,31,32],"misp","threat-feed","aggregation","indicator","sharing","correlation","siem-integration","threat-intelligence","mahipal","cybersecurity","1.0",[37,38,39,40],"ID.RA-01","ID.RA-05","DE.CM-01","DE.AE-02",[42,43,44],"T1071","T1105","T1588.001","main","d69096e239f2a89aabc2cd078c47664a9d3b1e11","04-安全渗透\u002Fbuilding-threat-feed-aggregation-with-misp",3,"https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts","https:\u002F\u002Fgithub.com\u002Flza6","个人vx：Tf00798\r\n个人✈：@TFGY999","2026-10-08 14:29:22",{"source":8,"skillName":5,"commands":54,"prompt":64,"zipAvailable":65},[55,58,61],{"tool":56,"command":57},"npx","npx skills add lza6\u002FArmor-piercing-system-prompts --skill building-threat-feed-aggregation-with-misp",{"tool":59,"command":60},"bunx","bunx skills add lza6\u002FArmor-piercing-system-prompts --skill building-threat-feed-aggregation-with-misp",{"tool":62,"command":63},"pnpm","pnpm dlx skills add lza6\u002FArmor-piercing-system-prompts --skill building-threat-feed-aggregation-with-misp","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F04-安全渗透\u002Fbuilding-threat-feed-aggregation-with-misp\u002FSKILL.md",true,[67],{"path":68,"resourceType":69,"resourceTypeDesc":70,"sizeBytes":71,"sourceHtmlUrl":72},"references\u002Fapi-reference.md","REFERENCE","参考文档",2135,"https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F04-安全渗透\u002Fbuilding-threat-feed-aggregation-with-misp\u002Freferences\u002Fapi-reference.md",[74,83,88,95,102,109],{"skillNo":75,"name":76,"nameZh":6,"description":77,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":78,"licenseFileUrl":6,"sourceHtmlUrl":79,"categories":80,"keywords":81,"publishedAt":82},"01M7FFG485KY83TD6HSC4YPCMC","obsidian-clipper-template-creator","Guide for creating templates for the Obsidian Web Clipper. Use when you want to create a new clipping template, understand available variables, or format clipped content.","MIT","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobsidian-clipper-template-creator\u002FSKILL.md",[],[],"2026-11-16 10:05:34",{"skillNo":84,"name":76,"nameZh":6,"description":77,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":78,"licenseFileUrl":6,"sourceHtmlUrl":85,"categories":86,"keywords":87,"publishedAt":82},"01M7FFG0T6AZ0STEJPSB3CX84K","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobsidian-clipper-template-creator-antigravity-awesome-skills-main\u002FSKILL.md",[],[],{"skillNo":89,"name":90,"nameZh":6,"description":91,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":78,"licenseFileUrl":6,"sourceHtmlUrl":92,"categories":93,"keywords":94,"publishedAt":82},"01M7FFFY0QEM14SKWPDYGMXM2P","python-api","Programmatic Object-Detection-Metrics API guidance for BoundingBox, BoundingBoxes, Evaluator, enums, coordinate conversion, AP\u002FmAP semantics, and source-style import diagnostics.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobject-detection-metrics\u002Fsub-skills\u002Fpython-api\u002FSKILL.md",[],[],{"skillNo":96,"name":97,"nameZh":6,"description":98,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":78,"licenseFileUrl":6,"sourceHtmlUrl":99,"categories":100,"keywords":101,"publishedAt":82},"01M7FFFVZQZ2GJ0C0TGP7JHD20","file-evaluation","Folder-based PASCAL VOC AP\u002FmAP evaluation from ground-truth and detection text files.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobject-detection-metrics\u002Fsub-skills\u002Ffile-evaluation\u002FSKILL.md",[],[],{"skillNo":103,"name":104,"nameZh":6,"description":105,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":78,"licenseFileUrl":6,"sourceHtmlUrl":106,"categories":107,"keywords":108,"publishedAt":82},"01M7FFFSFNYSE77SJ6PE1CK2DA","object-detection-metrics","Guides legacy Object-Detection-Metrics PASCAL VOC AP\u002FmAP evaluation from detection text folders and direct Python API classes.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fobject-detection-metrics\u002FSKILL.md",[],[],{"skillNo":110,"name":111,"nameZh":6,"description":112,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":78,"licenseFileUrl":6,"sourceHtmlUrl":113,"categories":114,"keywords":115,"publishedAt":82},"01M7FFFP0GCK1RVXBCPQ8APBMT","nx-workspace-patterns","Configure and optimize Nx monorepo workspaces. Use when setting up Nx, configuring project boundaries, optimizing build caching, or implementing affected commands.","https:\u002F\u002Fgithub.com\u002Flza6\u002FArmor-piercing-system-prompts\u002Fblob\u002Fmain\u002F07-后端与架构\u002Fnx-workspace-patterns\u002FSKILL.md",[],[]]