Skip to content

Instantly share code, notes, and snippets.

@h4sh5
Created February 27, 2020 22:39
Show Gist options
  • Save h4sh5/114cb5e5cbc5cfe9171e406f3cca6df5 to your computer and use it in GitHub Desktop.
Save h4sh5/114cb5e5cbc5cfe9171e406f3cca6df5 to your computer and use it in GitHub Desktop.
#!/usr/bin/env python
import zlib, base64, re, xml.dom.minidom, struct, binascii
import sys
import urllib
d = sys.stdin.read()
urldecoded = urllib.unquote(d)
b64decoded = base64.b64decode(urldecoded)
decompressed = zlib.decompress(b64decoded, -15)
x = xml.dom.minidom.parseString(decompressed)
xml_pretty = x.toprettyxml(indent='\t')
print xml_pretty
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment