Skip to content

Instantly share code, notes, and snippets.

View pry0cc's full-sized avatar
💭
Hacking the Planet

pry0cc pry0cc

💭
Hacking the Planet
  • Amazon Web Services
  • Austin, TX
  • X @pry0cc
View GitHub Profile
#!/bin/bash
#
# https://github.com/Nyr/openvpn-install
#
# Copyright (c) 2013 Nyr. Released under the MIT License.
# Detect Debian users running the script with "sh" instead of bash
if readlink /proc/$$/exe | grep -q "dash"; then
echo "This script needs to be run with bash, not sh"
@pry0cc
pry0cc / ports.py
Created October 15, 2020 21:51
Get all ports from an nmap XML output file in the host:ip format
#!/usr/bin/env python
## $ ports.py nmap.xml
## 8.8.8.8:80
## 8.8.8.8:443
## 8.8.8.8:3305
#install requirements: pip install python-libnmap
#uses python 2
@pry0cc
pry0cc / reverse-ssh.sh
Created August 5, 2015 22:10
A reverse ssh script.
mode=$1
local_ip=$2
local_port=$3
function serv_ins {
echo "ssh -N -R $local_port:localhost:22 root@$local_ip" | sudo timeout 2 nc -l -c -p $local_port
}
if [ $mode = -s ]
then
@pry0cc
pry0cc / iptrack
Created July 30, 2016 21:49
A snappy application to find out everything known about an IP.
#!/usr/bin/env ruby
require 'json'
require 'mechanize'
require 'rubygems'
require 'open-uri'
puts "Looking up #{ARGV[0]}"
agent = Mechanize.new
#!/bin/bash
email="$1"
key=""
if [[ -z "$email" ]]; then
echo "No email supplied"
exit 1
fi
#!/bin/bash
url="$1"
domain=$(echo "$url" | unfurl domain)
pat=$(echo "$url" | unfurl path)
nmap -T4 -p80,443 -Pn -sV "$domain" --script http-ntlm-info --script-args http-ntlm-info.root="$pat"
@pry0cc
pry0cc / typosmash.sh
Last active April 5, 2022 19:16
A script that uses interlace and urlcrazy to multi-threadedly check if domains are available for TypoSquats
#!/bin/bash
echo "" > $1.txt
urlcrazy $1 -f csv | cut -d "," -f 2 | grep -v "Typo" > domains.txt 2>&1 | grep -v "warn"
interlace -tL domains.txt -threads 100 -c "curl -s \"https://api.scaleway.com/domain/v2alpha2/available-domains?search=_target_\" | jq -r '.[][] | select(.a
vailable==true) | .domain' >> $1.txt" >> /dev/null 2>&1
rm -f domains.txt
/usr/bin/cat $1.txt
rm $1.txt
#!/bin/bash
protocols=("ssh" "ftp" "telnet" "netbios-ssn" "ms-wbt-server" "vnc")
for protocol in "${protocols[@]}"
do
mkdir -p "proto/$protocol"
users="usernames/generic.txt"
passes="passwords/generic.txt"
@pry0cc
pry0cc / amass_configs.json
Created February 10, 2021 23:49
Amass secret configurations in JSON to help tool authors add amass key integration
{
"data_sources.AlienVault": {
},
"data_sources.AlienVault.Credentials": {
"apikey ": ""
},
"data_sources.BinaryEdge": {
"ttl 10080": ""
},
"data_sources.BinaryEdge.Credentials": {
@pry0cc
pry0cc / dns-resolvers.txt
Created March 8, 2021 23:03
Providers that haven't complained yet
1.1.1.1
9.9.9.9
8.8.8.8
129.250.35.250
1.0.0.1
212.31.32.130
198.82.247.34
129.250.35.251
195.113.144.194
194.179.1.100