# How integrations run

> How connectors, collectors, injectors and executors run next to OpenCTI and OpenAEV, how they reach their platform, and which ones xtm-docker always starts.

- URL: https://filigran.io/docs/deploy/integrations/how-they-run/
- Products: OpenCTI 7.261119.0, OpenAEV 3.261118.0, XTM Composer 3.261121.0
- For: platform engineers, administrators
- Type: Concept

An integration is a small program that connects OpenCTI or OpenAEV to another system: it imports or exports data, enriches it, or runs actions. Most integrations run as their own container next to the platform. This page explains how they run, how they reach their platform, and which ones the XTM stack starts by default, so you can choose how to run yours.

## Four kinds of integration {#four-kinds-of-integration}

| Kind | Platform | What it does | How it is built |
| --- | --- | --- | --- |
| Connector | OpenCTI | Imports, enriches, streams or exports threat intelligence | [Connectors](https://filigran.io/docs/develop/integration-model/connectors/) |
| Collector | OpenAEV | Reads detection and prevention results, or reference data, from a security tool or a source | [Collectors](https://filigran.io/docs/develop/integration-model/collectors/) |
| Injector | OpenAEV | Runs injects: sends emails, runs scans, calls other tools | [Injectors](https://filigran.io/docs/develop/integration-model/injectors/) |
| Executor | OpenAEV | Deploys and runs OpenAEV agents on endpoints | [Executors](https://filigran.io/docs/develop/integration-model/executors/) |

The catalog of available integrations is the [XTM Hub integrations library](https://hub.filigran.io/cybersecurity-solutions/open-cti-integrations). Each platform also shows its own catalog: **Integrations**, **Available** tab (**Data > Ingestion > Connector catalog** before 7.260811) in OpenCTI, **Integrations** > **Catalog** in OpenAEV.

### Built-in and external {#built-in-and-external}

Some integrations live inside the platform and need no deployment:

- OpenAEV embeds some injectors, such as email, SMS and media pressure. You configure them in the platform configuration.
- OpenAEV runs its own agent natively, and you configure the executors of endpoint security products, such as Tanium or CrowdStrike Falcon, in **Integrations** > **Executors** of OpenAEV.

Everything else is external: a program, usually in Python, published as a Docker image (`opencti/connector-*`, `openaev/collector-*`, `openaev/injector-*`), that you run yourself or let XTM Composer run for you.

## How an integration reaches its platform {#how-an-integration-reaches-its-platform}

Every external integration needs two settings to reach its platform, plus an identity of its own:

| Setting | OpenCTI connector | OpenAEV collector or injector |
| --- | --- | --- |
| Platform URL | `OPENCTI_URL` | `OPENAEV_URL` |
| API token | `OPENCTI_TOKEN` | `OPENAEV_TOKEN` |
| Unique ID, a UUIDv4 | `CONNECTOR_ID` | `COLLECTOR_ID` or `INJECTOR_ID` |
| Display name | `CONNECTOR_NAME` | `COLLECTOR_NAME` or `INJECTOR_NAME` |

At start, the integration registers with the platform through its API, with its token. The platform then gives it the address and credentials of RabbitMQ:

- An OpenCTI connector pushes the STIX 2.1 bundles it produces to its RabbitMQ queue, and the OpenCTI workers write them into the platform. Enrichment and export connectors also receive their jobs from RabbitMQ.
- An OpenAEV injector receives its work through RabbitMQ in the same way.

**Diagram: How an integration exchanges data with its platform**

- Integrations: Connector (OpenCTI import, enrichment, stream, export), Collector, injector (OpenAEV, external ones)
- Platforms: OpenCTI (API at OPENCTI_URL), OpenAEV (API at OPENAEV_URL)
- Queues: RabbitMQ (One queue per integration)

Connections:

- Connector → OpenCTI: register with token
- Collector, injector → OpenAEV: register with token
- Connector → RabbitMQ: push and listen
- Collector, injector → RabbitMQ: injectors listen
- OpenCTI → RabbitMQ: workers consume

So an integration must reach two things on the network: the platform URL you give it, and RabbitMQ at the host name and port the platform hands out. In the XTM stack, both are on the Docker network of the deployment (`xtm_default` with the default `COMPOSE_PROJECT_NAME=xtm`), as `http://opencti:8080`, `http://openaev:8080` and `rabbitmq:5672`. A connector that cannot reach RabbitMQ can talk to OpenCTI over HTTP only: see [Run an integration without XTM Composer](https://filigran.io/docs/deploy/integrations/manual/).

The token decides what the integration can do. OpenCTI recommends one user per connector, in the `Connectors` group. OpenAEV integrations can share an administrator token. The details are in [Run an integration without XTM Composer](https://filigran.io/docs/deploy/integrations/manual/#create-a-token).

## Three ways to run integrations {#three-ways-to-run-integrations}

| Way | What you do | When to choose it |
| --- | --- | --- |
| [XTM Composer](https://filigran.io/docs/deploy/integrations/composer/) | Deploy, start, stop and configure integrations from the platform interface. XTM Composer runs the containers | Most deployments. It requires an Enterprise Edition license |
| The default integrations of xtm-docker | Nothing: they are part of the stack | The integrations every platform needs, always started with the stack |
| [By hand](https://filigran.io/docs/deploy/integrations/manual/) | Add a service to a Compose file, or run the Python program | An integration that is not in the catalog, or a deployment without Enterprise Edition |

You can combine them: the default integrations run as Compose services while XTM Composer runs the ones you add later.

## The default integrations of xtm-docker {#the-default-integrations-of-xtm-docker}

[FiligranHQ/xtm-docker](https://github.com/FiligranHQ/xtm-docker) always starts these integrations with the stack: they are defined next to their platform, in `modules/opencti.yml` and `modules/openaev.yml`. Each one runs as a Compose service with `restart: always`, starts once its platform is healthy, and uses the admin token of its platform (`OPENCTI_ADMIN_TOKEN` or `OPENAEV_ADMIN_TOKEN` in `.env`). Its ID is in `.env` too.

**OpenCTI connectors**

| Service | What it does |
| --- | --- |
| `connector-export-file-stix` | Exports data as STIX 2.1 |
| `connector-export-file-csv` | Exports data as CSV |
| `connector-export-file-txt` | Exports data as plain text |
| `connector-import-file-stix` | Imports STIX 2.1 bundles |
| `connector-import-document` | Imports PDF, HTML and text documents and extracts their knowledge |
| `connector-import-file-yara` | Imports YARA rules |
| `connector-analysis` | Analyzes PDF, HTML and text documents |
| `connector-import-external-reference` | Imports the content of external references |
| `connector-opencti` | Loads the OpenCTI datasets: marking definitions, identities, locations |
| `connector-mitre` | Loads MITRE ATT&CK |

The import, analysis and dataset connectors (`connector-import-*`, `connector-analysis`, `connector-opencti`, `connector-mitre`) set `CONNECTOR_AUTO_CREATE_SERVICE_ACCOUNT=true`, with a confidence level of 100. At start, each one creates a service account named `[C] <connector name>` in the `Connectors` group, then runs with its token instead of the admin token.

The three export connectors keep a token of their own: an export connector acts as the user who asked for the export, and only an account with **Bypass all capabilities** can do so. Give each one the token of a service account in a group that has it, such as Administrators, in `CONNECTOR_EXPORT_FILE_STIX_TOKEN`, `CONNECTOR_EXPORT_FILE_CSV_TOKEN` and `CONNECTOR_EXPORT_FILE_TXT_TOKEN` of `.env`. Left empty, as in `.env.sample`, they use the admin token.

**OpenAEV collectors and injectors**

| Service | Kind | What it does |
| --- | --- | --- |
| `collector-mitre-attack` | Collector | Loads MITRE ATT&CK attack patterns |
| `collector-openaev` | Collector | Loads the OpenAEV datasets |
| `collector-atomic-red-team` | Collector | Loads the Atomic Red Team tests |
| `collector-nvd-nist-cve` | Collector | Loads CVEs from the NVD. Set `COLLECTOR_NVD_NIST_CVE_API_KEY` in `.env`: optional, recommended |
| `injector-nmap` | Injector | Runs Nmap network scans |
| `injector-nuclei` | Injector | Runs Nuclei vulnerability scans |

## See them run {#see-them-run}

Each platform lists the integrations that registered with it, managed by XTM Composer or not:

- OpenCTI: **Integrations**, **Deployed** tab (**Data > Ingestion > Connectors** before 7.260811) shows each connector, its status and the messages waiting in its RabbitMQ queue.
- OpenAEV: **Integrations** > **Collectors** and **Integrations** > **Injectors** show each collector and injector and its status.

From the host, the containers of the default integrations are Compose services:

```bash
docker compose ps --format '{{.Service}} {{.Status}}' | grep -E '^(connector|collector|injector)-'
```

**Check that it worked**

Each default integration is `Up`. A container that keeps restarting cannot reach its platform: run `docker compose logs <service>` to see why.

## What's next {#what-s-next}

- [XTM Composer](https://filigran.io/docs/deploy/integrations/composer/), to run integrations from the platform interface.
- [Run an integration without XTM Composer](https://filigran.io/docs/deploy/integrations/manual/), for Docker and Python deployments, networking and tokens.
- [Integration model](https://filigran.io/docs/develop/integration-model/), to build your own integration.
