Follow us :
Data Security

The Hidden Forwarding Rule: What an Attacker Leaves in a Hijacked Mailbox

Employee touching an envelope icon on a touch screen, email forwarding security — Xen Bilişim

An employee’s mailbox was taken over. You reset the password, signed out every session, and the employee logged back in. Is it over? Not necessarily. If the attacker got in, they may have done one more thing: added an inbox rule that sends a copy of every message to an address of their own. The password changed, the rule did not, and the company’s correspondence keeps flowing out.

Why does a rule work so well?

Not every attacker moves for cash on day one. Some wait and read. They learn the invoice threads, the payment cycles, who writes to whom and in what tone. Then, at the right moment, they step in with a “our bank details have changed” email. A forwarding rule serves that patient approach because the user may notice nothing in Outlook. The inbox looks normal, the mail looks normal, one extra copy simply leaves.

Microsoft’s own documentation says as much. Users can set inbox rules that forward mail to outside recipients, on purpose or because the account was compromised. Admin-configured mailbox forwarding (SMTP forwarding) is the second route.

What is external forwarding set to in your tenant?

In Exchange Online, the outbound spam policy decides whether mail can be forwarded automatically to external recipients. There are three options:

SettingWhat it does
Automatic - System-controlledThe default. Behaviour depends on the organisation
OnAutomatic external forwarding is allowed
OffExternal forwarding is blocked and the sender gets a non-delivery report (NDR)

The first row deserves attention. In 2021 Microsoft changed it to behave as “Off” for new organisations and for existing ones that were not actively using the value. Organisations that were already using it can still behave as “On”. So if your tenant predates 2021, you may not know what the setting does for you. Microsoft’s advice is to pick On or Off deliberately instead of leaving it on Automatic.

Switching it to Off has two effects. Inbox rules that forward outside, and admin-configured external forwarding, stop working. Forwarding between internal users is not affected.

When the block catches a message, the sender receives this error: “5.7.520 Access denied, Your organization does not allow external forwarding.” If a user complains that the forward to a customer no longer works, this may be why.

How to check what you have

Three places are enough.

  1. The outbound spam policy. In the Microsoft Defender portal, open the outbound spam filter policy and read the automatic forwarding value. If it says Automatic, turn it into a deliberate choice.
  2. The auto forwarded messages report. For cloud mailboxes, Exchange has a report showing which users forward automatically to external recipients. If it is not empty, ask of every address: is this intentional?
  3. The suspect mailbox’s rules. As an admin, Get-InboxRule -Mailbox [email protected] lists every rule in the mailbox. A rule you do not recognise, one with a blank or meaningless name, one that forwards, or one that deletes incoming mail, is a sign of takeover.

For admin-configured forwarding, look in the Exchange admin center under Recipients, Mailboxes, the user, then Email forwarding.

One more detail. Remote domain settings can block forwarding that users set up, but they do not block admin-configured mailbox forwarding or forwarding done through mail flow rules. Closing forwarding on a remote domain alone is not enough. The outbound spam policy is the main switch.

What order to work in after a takeover

Order matters. Many teams start with the password and stop there.

  • Sign out all sessions and reset the password.
  • Check that multi-factor authentication is on and that no new verification method was added.
  • Review every inbox rule in the mailbox and delete any you do not recognise.
  • Check whether admin-set forwarding exists.
  • Look at what the account sent. You need to know who received what.
  • Find out since when the rule has been running. Everything after that date left the company, and your decision about warning customers and suppliers comes from it.

If that correspondence contains personal data, the clock for a breach notification under Türkiye’s KVKK (the personal data protection law) may already be running, which is why the start date of the rule matters. Talk to your data protection adviser about the legal side.

Frequently asked questions

Will turning off external forwarding affect my staff?

Only those who forward automatically to outside addresses. Internal forwarding keeps working. If a few users genuinely need it, create a separate outbound spam policy and allow it for those accounts only.

Doesn’t multi-factor authentication prevent this?

It makes signing in harder, but once an attacker is inside, for example through an employee tricked by an approval prompt (an MFA fatigue attack is one such case), a rule can still be created. Blocking external forwarding stops the copy from leaving even after a successful sign-in. One does not replace the other.

How often should I check?

Look at the outbound spam policy once a year and open the forwarding report every quarter. When an account is compromised, check that account’s rules immediately.

If you are not sure what the setting is in your own tenant, contact us and we will look at the tenant settings and write back with the result.

Share this post
Türkçe oku

Related Posts