Skip to content
Open redirect Write-up Advanced

Internet Explorer has a URL problem

Internet Explorer mishandled URL-encoded hostnames during redirects, causing users to be sent to a different domain than intended. This allowed theft of GitHub OAuth codes and, combined with a path parameter issue in Google Fusion Tables, led to XSS on google.com.

File Descriptor Follow

Published on web.archive.org

September 6, 2016 | Tags: Google, RPO, XSS, Bug Bounty

File Descriptor (@filedescriptor), on web.archive.org

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 Internet Explorer incorrectly decoded and overlaid URL-encoded hostname components during redirects, and also failed to normalise encoded dot-dot-slash sequences in paths, causing a mismatch between the address bar and the actual request.

Impact

Attackers could steal OAuth authorization codes for any GitHub user and achieve XSS on google.com in Internet Explorer 11 (and Edge for the second bug), though the first bug was fixed in IE11 on Windows 10.

What the attacker needed

Victim uses Internet Explorer 11 on Windows 7/8.1; victim clicks a crafted link; attacker controls a domain

The fix

GitHub fixed the OAuth bug by recursively normalising the redirect_uri in the Location header, and Google fixed the RPO issue by moving products to dedicated subdomains and removing path parameter support.

How it was found

  1. Craft a redirect URL with a triple-encoded hostname that normalises to the legitimate callback but is sent single-encoded in the Location header.
  2. Visit the crafted GitHub OAuth authorization link in Internet Explorer.
  3. Observe that the browser redirects to an attacker-controlled domain with the OAuth code in the query string.
  4. For the Google Fusion Tables bug, navigate to a URL with an encoded dot-dot-slash path that the server ignores as a path parameter.
  5. Load a page that imports a script using a relative path, causing the script to be fetched from an attacker-controlled domain via an open redirect.

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.

When a website redirects you to another page, it uses a URL. Internet Explorer made a mistake when the URL contained special encoded characters in the domain name, so it sent people to a different website than the one intended. Attackers could use this to steal login codes or run malicious scripts on a trusted site.

What is Open redirect?

A trusted site forwards users to any address an attacker picks; rarely paid alone, often the missing link in a chain.

Similar reports

View all

Same bug class and techniques, clearest first.

Open redirect

The lesson behind this report.

A trusted site forwards users to any address an attacker picks; rarely paid alone, often the missing link in a chain.