Read more

Don't open user-supplied links with target="_blank"

Henning Koch
March 15, 2016Software engineer at makandra GmbH

The HTML spec was changed to prevent window.opener from accessing the parent page. This is implemented by all browsers except IE11.

This will give the target site full access to your Javascript environment through window.opener, if the target is on the same domain.

Illustration web development

Do you need DevOps-experts?

Your development team has a full backlog? No time for infrastructure architecture? Our DevOps team is ready to support you!

  • We build reliable cloud solutions with Infrastructure as code
  • We are experts in security, Linux and databases
  • We support your dev team to perform
Read more Show archive.org snapshot

Even if the target site is on another domain, it still has some access and can for example manipulate window.location to perform a phishing attack.

You may use a rel="noopener" attribute to avoid this in modern browsers, except IE or Edge.

Posted by Henning Koch to makandra dev (2016-03-15 13:28)