Skip to content

Instantly share code, notes, and snippets.

@m0rb
m0rb / brutely.pl
Created April 16, 2016 23:44
brutely - crawl bit.ly and similar URL shortening services using brute force methodology
#!/usr/bin/perl -w
# Usage: brutely.pl URL <LENGTH> (length defaults to 6)
# Ex: ./brutely.pl https://bit.ly/1 6
# 4/16/16 -- chris_commat_misentropic_commercial
use strict;
use warnings;
use HTTP::Tiny;
my $ua = HTTP::Tiny->new( { agent => "ayy/1.0", keep_alive => 1 } );
my $ln = $ARGV[1]; $ln ||= 6;
#!/bin/sh
# countryblock.sh -- yet another country blackholing script by morb
# psst, hey kid! wanna blackhole countries with the flick of a wrist?
CC=$1;[ -z $CC ]&&printf "Usage: $0 <country code>\nex:\n$0 cn #China\n"&&exit 1
[ "$USER" != "root" ]&&printf "root required.\n"&&exit 1
ZONE="http://www.ipdeny.com/ipblocks/data/countries/${CC}.zone"
curl -s $ZONE | xargs -I, ip route add blackhole , metric 999
@m0rb
m0rb / bl2_movietoggle.sh
Created October 20, 2016 16:15
Borderlands 2 Cutscene/Movie toggle script
#!/bin/bash
# Borderlands 2 is pretty heavy with the cutscenes in Sanctuary.
# Constantly. Playing. Character intros.
# Fortunately we can toggle the cutscenes on or off...
# --morb
TEMP=$(mktemp)
DIR="${HOME}/.steam/steam/SteamApps/common/Borderlands 2/steamassets/willowgame/config"
errexit() {
echo $@;rm $TEMP;exit 1
}
@m0rb
m0rb / uiwixpanel.sh
Created May 18, 2017 02:17
uiwix payment gateway crawler
#!/bin/bash
# deps: tesseract, torify, curl
# use seq and GNU parallel to speed up crawling
# ex - $ seq 1000000000 2000000000 | parallel --jobs +20 ./uiwixcrawl.sh {}
# 5/17/17 - chris_commat_misentropic_commercial
URL="http://4ujngbdqqm6t2c53.onion"
grab() {
torify curl -s $@ -H 'Host: 4ujngbdqqm6t2c53.onion' -H \
@m0rb
m0rb / swhelper.sh
Created May 19, 2017 23:25
"Shadow Warrior Original" (from Steam) prep script for jfsw port on *nix
#!/bin/bash
# "Shadow Warrior Original" -> jfsw prep script
# 5/19/17 - chris_commat_misentropic_commercial
#
#
# Run this from a directory where you copied the 'gameroot' contents
# from the Steam version of SW.
#
# Place the 'sw' binary there as well.
# Have fun!
@m0rb
m0rb / gist:6039eb6254319980a3dc9e906733cac4
Created July 11, 2017 23:11
The Ur-Quan Masters -- Credit filling binary patch (for a savefile)
QlNESUZGNDAxAAAAAAAAADIAAAAAAAAA0AMAAAAAAABCWmg5MUFZJlNZcn321wAAB0BGaBBAAAQA
QAAgACGTBCGAQ4m5S7xdyRThQkHJ99tcQlpoOTFBWSZTWd/+4BEAAABIBMQAQAAIAAAIoAAgqg0D
ANldoSzHeLuSKcKEhv/3AIhCWmg5F3JFOFCQAAAAAA==
---
base64 -d the above into a file, use bspatch(1) to apply it against one of your savefiles to fill up your RU all the way.
$ bspatch starcon2.00 starcon2.01 credit.patch
where starcon2.01 will be your new savefile. You should have a few billion RU to work with.
@m0rb
m0rb / oysttyer_bell.patch
Created October 1, 2017 17:38
oysttyer -- bell on notification
-- a/oysttyer.pl
+++ b/oysttyer.pl
@@ -56,7 +56,7 @@
$padded_patch_version = substr($oysttyer_PATCH_VERSION . " ", 0, 2);
%opts_boolean = map { $_ => 1 } qw(
- ansi noansi verbose superverbose oysttyeristas noprompt
+ ansi noansi bell verbose superverbose oysttyeristas noprompt
seven silent hold daemon script anonymous readline ssl
newline vcheck verify noratelimit notrack nonewrts notimeline
@m0rb
m0rb / add_door.pl
Created April 5, 2018 16:50
add_door.pl
#!/usr/bin/perl -w
use warnings;
use X11::GUITest qw/:ALL/;
my $doorct = $ARGV[0];
my $doorname = $ARGV[1];
my $doorkey = $ARGV[2];
my $doorcmd = $ARGV[3];
StartApp('dosbox');
my ($win) = WaitWindowViewable('dosbox');
@m0rb
m0rb / bingo.sh
Created July 19, 2018 16:37
bingo.sh
#!/bin/bash
[ -z $1 ] && echo "Usage: $0 listfile.txt" && exit 1
IFS=$'\r\n'
LIST=($(cat $1))
RNG=($(shuf -i 0-$(( ${#LIST[@]} - 1)) -n 25))
I=0
for X in {1..25};
do convert -background white -size 120x120 -gravity Center -weight 500 -pointsize 14 caption:"${LIST[${RNG[${I}]}]}" cell${X}.png
I=$(( $I + 1 ))
done
# Quick hexedit job for a Windows-focused Doom pwad launcher
# https://github.com/Forevener/DRPGSEL/releases/tag/v1.0.3
QlNESUZGNDAyAAAAAAAAAEcAAAAAAAAAAEABAAAAAABCWmg5MUFZJlNZ7e7orQAABEZAYCBAARAA
QAAgACI00zUIYCN4itBfF3JFOFCQ7e7orUJaaDkxQVkmU1lEe0qcAACi4DLACAgBAAQACJgAAAgg
AFCAGAhVDGkzqUUEQUiIUIob9EUV5zO502KqH4u5IpwoSCI9pU4AQlpoORdyRThQkAAAAAA=