Phishing Or What How I Got Access To The Internal Email Of A Company
The contact form sent email through the company's own mail service, and the request body exposed fields for recipient, sender, subject and HTML body. Only the sender field was validated, so an attacker could send fully customised HTML emails, including phishing links and attachments, from the company's real internal address to anyone.
Hey guys, good to have you back on my blog. This is a bug that I found last September, but this vulnerability was a different one.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the server trusted client-supplied email fields (recipient, subject and HTML body) and only validated the sender address, instead of fixing the recipient and generating the body server-side.
Impact
An attacker could send arbitrary HTML emails, including phishing links and attachments, that appeared to come from the company's genuine internal address; the report was initially rated low and later raised to medium.
What the attacker needed
Access to the contact form; ability to intercept the request
How it was found
- Fill in the contact form and capture the outgoing request.
- Notice the request contains recipient, sender, subject and HTML body fields.
- Change the recipient, subject and HTML body values, leaving only the sender field as validated.
- Send the request and observe the customised email arriving from the company's address.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
A contact form usually just passes a message to the site owner. Here the form secretly built an email request with fields for who it goes to, who it appears to come from, the subject and the body. The site only checked the sender field, so a user could rewrite the rest and make the company's own mail system deliver convincing fake messages.
What is Business logic?
The application works as coded but not as intended: a negative price, a skipped payment step, a limit that can be crossed.