Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #Blog post: http://middleeastmalware.blogspot.com/2015/04/cyber-attack-9.html
- import sys,os,time
- def DecodeCyberGate(InputFileX):
- if os.path.exists(InputFileX)==False:
- print "File does not exist\r\n"
- return
- fIn = open(InputFileX,"r")
- contentX = fIn.read()
- fIn.close()
- if len(contentX)==0:
- print "File is empty\r\n"
- return
- else:
- print "Processing input of length " + str(len(contentX))
- DecodedContent = ""
- for CX in contentX:
- int_CX = ord(CX)
- int_key = int(188)
- DecodedContent = DecodedContent + chr(int_CX ^ int_key)
- print DecodedContent
- fOut = open("result.txt","wb")
- fOut.write(DecodedContent)
- fOut.close()
- return
- def main():
- if len(sys.argv)!=2:
- print "Usage: DecodeCyberGate.py input.txt\r\n"
- sys.exit(-1)
- else:
- DecodeCyberGate(sys.argv[1])
- sys.exit(0)
- if __name__ == "__main__":
- main()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement