# 5.7.512: access denied, message must be RFC 5322 section 3.6.2 compliant

URL: https://iblockspam.com/smtp-errors/550-5-7-512
Last updated: 2026-11-03

Code: 550 5.7.512 (permanent failure, the message bounced)
Provider: Microsoft 365 / Outlook.com

Microsoft 365 rejected the message because it was sent without a valid email address in the From header, which RFC 5322 section 3.6.2 requires.

What the bounce says:

```
Access denied, message must be RFC 5322 section 3.6.2 compliant
```
Microsoft's text for 5.7.512, as listed in its Exchange Online NDR reference.

Microsoft's NDR reference lists 5.7.512 "Access denied, message must be RFC 5322 section 3.6.2 compliant": the message was sent without a valid From email address. Microsoft notes it applies to Office 365 only, that each message must contain a valid email address in the From header field, and that proper formatting includes angle brackets around the address, for example <security@contoso.com>. Without an address in that format, Microsoft 365 rejects the message.

RFC 5322 section 3.6.2 defines the originator fields, From, Sender and Reply-To. The From field names the author of the message. A display name on its own, an address with no domain, or a From header that's missing entirely all fail the check.

The usual sources are homemade scripts, website forms, monitoring tools and old devices that build headers themselves. A common pattern is a From value such as "Website" or "root" with no address at all. Set a full sender address in the application, or send through a mail library that formats the header for you, then send a test.

## Common causes

- The From header is missing from the message.
- From contains only a display name, or an address without a domain.
- A script or device formats the From address incorrectly.
- An app builds raw headers instead of using a mail library.

## How to fix it (sender)

- Set a complete From address in the application, form or device, such as Website <noreply@yourdomain.com>.
- Use a maintained mail library or SMTP plugin that formats headers for you.
- Send a test to a Microsoft 365 mailbox and check the From header in the received message.

## How to fix it (recipient or admin)

- No action needed by recipients: the sending system must include a valid From address.

**Q: What does 'RFC 5322 section 3.6.2 compliant' mean in a Microsoft 365 bounce?**
Section 3.6.2 of RFC 5322 defines the From header. Microsoft requires every message to include a valid email address in From, formatted with angle brackets, for example <security@contoso.com>.

**Q: Why does my scanner or script get 5.7.512 from Microsoft 365?**
It is probably sending a From value without a real address, such as just a device name. Set a full sender address in the device or script settings, then send a test.

Sources:
- Email nondelivery reports (NDRs) and SMTP errors in Exchange Online (Microsoft Learn): https://learn.microsoft.com/en-us/troubleshoot/exchange/email-delivery/ndr/non-delivery-reports-in-exchange-online
- RFC 5322, section 3.6.2: Originator fields: https://www.rfc-editor.org/rfc/rfc5322#section-3.6.2

---

Source: iBlockSpam, https://iblockspam.com/smtp-errors/550-5-7-512 (this is a Markdown copy; the HTML page is canonical). Quote with attribution and a link. Site index for AI assistants: https://iblockspam.com/llms.txt
