Skip to content
Info disclosure Write-up Beginner

HTML Form Injection Vulnerability in Gmail

Gmail renders HTML forms inside emails, and while it warns and disables autofill for password fields, it allows autofill for credit card forms. An attacker could send an email with a credit card form and trick a victim into submitting their stored card details.

Souhaib Naceri Follow

Published on medium.com

Did you know that Gmail allows the use of the <form> HTML tag? This feature presents a potential security risk, especially when attempting to steal user credentials or sensitive information.

h4x0r_dz, on medium.com

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 Gmail's email rendering allows HTML forms and applies weaker protections (no warning, autofill enabled) to credit card fields compared to password fields.

Impact

A victim could inadvertently submit their stored credit card details to an attacker-controlled endpoint, but Gmail does show a warning for password forms and disables autofill there.

What the attacker needed

Victim uses Gmail webmail; victim has saved a credit card in Chrome; victim opens the attacker's email

How it was found

  1. In Chrome, go to payment settings and add a fake credit card.
  2. As an attacker, send an email containing an HTML form for credit card details.
  3. When the victim opens the email, the form is shown and autofill is allowed, leading to disclosure of card information.

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.

Gmail lets emails contain forms, which are boxes you fill in and submit. Normally Gmail warns you and blocks autofill for password forms, but for credit card forms it does not block autofill. So a bad email could trick you into sending your saved card details.

What is Info disclosure?

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.

More by Souhaib Naceri

View all

7 more disclosed reports, best first.

Similar reports

View all

Same bug class and techniques, clearest first.

Information disclosure

The lesson behind this report.

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.