Skip to content

Instantly share code, notes, and snippets.

{
"feeds": [
"https://about.gitlab.com/security-releases.xml",
"https://adepts.of0x.cc/feed.xml",
"https://sensepost.com/rss.xml",
"https://itm4n.github.io/feed.xml",
"https://www.blackarrow.net/feed/",
"https://rosenzweig.io/blog/gpu-feed.xml",
"https://dirkjanm.io/feed.xml",
"http://www.harmj0y.net/blog/feed/",
@ca0s
ca0s / generic.py
Last active March 19, 2020 08:45
Generic HTTP scanner
import subprocess
import threading
import argparse
import requests
import urllib3
import logging
import queue
import json
import time
import sys
@ca0s
ca0s / doipfresh.py
Created November 12, 2019 16:12
Get new IP addresses assigned to your DigitalOcean droplets
import digitalocean
import argparse
import logging
import json
import time
import config
fields = [ 'id', 'name', 'memory', 'vcpus', 'disk', 'status', 'locked', 'created_at', 'status', 'networks', 'kernel', 'backup_ids', 'snapshot_ids', 'action_ids', 'features', 'image', 'ip_address', 'private_ip_address', 'ip_v6_address', 'end_point', 'volume_ids' ]
import socket
import signal
import logging
import sys
logging.basicConfig()
log = logging.getLogger("portsim")
log.setLevel(logging.INFO)
ports = list(range(2000, 2200))
@ca0s
ca0s / multiwhois.py
Created October 31, 2019 09:41
Get whois data
from concurrent.futures import ThreadPoolExecutor, as_completed
from pythonwhois import get_whois
from ipwhois import IPWhois
import argparse
import socket
import re
# naive but will suffice
ip_re = re.compile(r'\d+\.\d+\.\d+\.\d+')
@ca0s
ca0s / http-screenshot.nse
Created October 29, 2019 10:12
A slightly improved version of nmap's http-screenshot.nse
local shortport = require "shortport"
local stdnse = require "stdnse"
description = [[
Gets a screenshot from a Web service using webshot.js, a nodejs/puppeteer script.
It can be used with IVRE.
]]
# Parses a cobalt strike config dump. Feed it a file containing
# a memory dump which starts with the config.
import struct
import sys
def _read_short(data, index):
return struct.unpack('>H', data[index : index + 2])[0]
def _read_int(data, index):
@ca0s
ca0s / cgrep.py
Last active August 26, 2019 15:42
#!/usr/bin/env python
import argparse
import re
import os
from concurrent.futures import ThreadPoolExecutor, as_completed
def regex(s):
try:
@ca0s
ca0s / rtf.py
Created December 4, 2017 14:33
Simple RTF tool
#!/usr/bin/python2
import argparse
import olefile
import struct
import sys
def parse_objdata(obj):
cobj = obj.lstrip('\\')
cobj = cobj.lstrip("objdata ")
#!/usr/bin/python2
# ca0s @ ka0labs.net
# make AFL write to a FIFO file, relay it to your server's socket
import argparse
import socket
import select
import sys
import os