# Block attachments and copy mail by rule

To set mail rules for the domain, open Edit Domain, click the **Option** tab and fill **Disallowed attachment file type**, the two BCC boxes, or the external domain alert. Click **View / Save Changes** and confirm. Use **Add Tag** for email tags. BCC takes up to 5 addresses each.

## How to block attachments and copy mail by rule

1. Open **Edit Domain** for your domain and click the **Option** tab.
2. In **Disallowed attachment file type**, type extensions separated by commas.
3. In the BCC boxes, type up to 5 addresses, separated by commas.
4. Tick the external domain alert if you need it and list your internal domains.
5. Click **View / Save Changes**, check the list, then click **Save**.

## Options

| Option | What it does |
|---|---|
| **Disallowed attachment file type** | Extensions users cannot send, for example `exe,bat`. Write them without a dot. Up to 1000 characters. The administrator gets the mail when a user tries to send a restricted attachment. |
| **Receive BCC of All Incoming mail to E-mail address** | Sends a copy of all incoming mail to these addresses. Up to 5, comma separated. |
| **Save Copy** | **YES** or **NO**. Chooses whether the BCC copy is saved. |
| **Send BCC of all outgoing mail to E-mail address** | Sends a copy of all outgoing mail to these addresses. Up to 5. |
| **Alert user when sending Email to external Domain, Enter internal domain(s) name** | Tick it and list your internal domains, comma separated. Users are warned when they send to any other domain. |
| **User feedback for block** | An address to which users send suspicious mail. Mail from an internal user to this address is scanned, and the address written in the subject in square brackets is blocked for that sender. |
| **Add Tag** (next to Email Tag) | Opens a window to add domain email tags. Each tag is up to 20 characters and saved in capitals. A domain can have up to 20. Use the bin icon to delete one. |

## Example

> Acme blocks `exe,bat,scr`, and sends all outgoing copies to `audit@acme.in` with up to 5 addresses allowed.

## Good to know

- The BCC values are set on every user but are not switched on for them.
- Tags save as soon as you add them. All other options need **View / Save Changes**.

## Common questions

**Can the BCC address be outside my domain?**

Each BCC address in the incoming box must belong to a domain that exists on the XgenPlus server. Otherwise the save is refused.


Source: https://docs.xgenplus.com/admin/domain-mail-rules/
