> ## Documentation Index
> Fetch the complete documentation index at: https://docs.xorlab.com/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Pages under /latest/ document the current release. Paths that begin with a version number, for example /10.0/, are frozen snapshots of superseded releases kept for reference only — never present their instructions as current. If the reader's version is unknown, answer from /latest/ and say which version the answer describes.
> xorlab is deployed on-premises, hybrid, or as a cloud service, and integrates with either Microsoft 365 or on-premises mail infrastructure. Configuration steps often differ between these. State which deployment and integration mode an instruction applies to instead of presenting one as universal.
> Distinguish inline mode from monitoring mode when describing anything that acts on email. Monitoring mode observes a copy and cannot block or quarantine; inline mode routes mail through xorlab and can.
> Write the product name as lowercase 'xorlab'. Use the documented component names: xorlab Control Center (XCC), xorlab MTA, xorlab Sandbox (DANA), xorlab Natural Language Understanding (NLU). After the first mention, use the short forms XCC, MTA, Sandbox, and NLU. Do not use DANA as a standalone name for the Sandbox, but keep it where it is a literal string in configuration keys, container names, and hostnames.
> Do not invent configuration keys, rule parameters, list names, log properties, or API fields. If a value is not present in this documentation, say that it is not documented rather than guessing.

# Email Direction

> How xorlab assigns each email a direction (incoming, outgoing, internal, or external) based on your guarded domains.

Every email will be assigned one of the following four directions:

* **Incoming:** The domain of the recipient is guarded, but the domain of the sender is not.
* **Outgoing:** The domain of the sender is guarded, but the domain of the recipient is not.
* **Internal:** The domain of the sender and recipient are both guarded.
* **External:** Neither sender nor recipient domain is guarded.

The direction is important because by default, only **Incoming** emails are filtered. The direction assignment is done based on sender and recipient, and not based on IP address or a dedicated listener.

<img src="https://mintcdn.com/xorlab/O_O2TUa6eRBR54aI/latest/assets/mail-direction.png?fit=max&auto=format&n=O_O2TUa6eRBR54aI&q=85&s=ee3ff411b47ff91db928e0fc887013ef" alt="Mail direction" width="1920" height="716" data-path="latest/assets/mail-direction.png" />

A sender that can’t be authenticated is always considered as **not guarded**.

<Warning>
  **External direction**

  The direction **External** is in almost all cases caused by a configuration issue: Either a domain is missing from `guarded_tenants.yml`, or xorlab is accidentally receiving emails for a domain that it should not receive any. For a properly configured xorlab, there should be no **External** emails. You can check this with the search `direction:external`.
</Warning>

<Note>
  **External verdict vs. External direction**

  In addition to the External direction, there is also a verdict External. The latter has nothing to do with the direction, and is the fallback verdict for benign emails that cannot be categorized further.
</Note>
