Skip to content

Instantly share code, notes, and snippets.

View nimaid's full-sized avatar

Ella Jameson nimaid

  • Tucson, AZ
View GitHub Profile
@nimaid
nimaid / rand_str.py
Last active April 5, 2017 12:43
Python random string gen
import random
random.seed()
def rand_str(str_len, chars = '01234567890qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM'):
ret_str = ''
for x in range(str_len):
ret_str += random.choice(chars)
return ret_str
@nimaid
nimaid / fraksl.pde
Last active July 28, 2022 13:17
Fraksl Processing Script
/*
A port of the Fraksl Android App by Ella Jameson
WASD to move, QE to rotate, [UP][DOWN] to zoom, P to take a picture in the sketch directory
*/
void mirror_screen()
{
loadPixels();
for(int row = 0; row < height; row++)
{
@nimaid
nimaid / random_tinyurls.py
Last active October 29, 2019 01:11
Random TinyUrl Brute Force Finder
import random
import string
import urllib.request as urlreq
import csv
filename = 'random_tinyurls.csv'
def random_string(stringLength=10):
letters = string.ascii_lowercase + string.digits
return ''.join(random.choice(letters) for i in range(stringLength))
@nimaid
nimaid / logger.py
Last active April 30, 2022 08:22
A Python `STDOUT` and `STDERR` logger
# Logger module by Ella J. (nimaid)
#
# This module provides basic logging of STDOUT and STDERR to a text file
# Usage:
#
# import logger
# logger.start("/path/to/my/log.txt")
# ...
# logger.stop()
@nimaid
nimaid / docker_setup_template_apt.bash
Last active September 25, 2020 17:58
A bash script template for Dockerfile `RUN` commands, with automatic APT/PIP package management.
#!/bin/bash
set -e # Causes script to exit on errors (and therefore causes a build failure)
#~~~~~~~~~~~~~~~~~~~~~~ DOCKER SETUP SCRIPT BEST PRACTICES ~~~~~~~~~~~~~~~~~~~~~~~#
# #
# This bash script is designed to be used in a RUN command in a Dockerfile. It is #
# structured so as to encourage good practices when creating a Docker image. #
# #
# When a Docker command finishes, a snapshot of the filesystem is taken. Then, #
# Docker figures out what files were created/changed/deleted, and only saves the #
@nimaid
nimaid / best_compress.bat
Last active October 25, 2020 19:58
A batch script to get the best possible 7z compression. (USE WITH REDUNDANCY, EASILY CORRUPTIBLE)
@echo off
set exe_7z=C:\Program Files\7-Zip\7z.exe
REM https://superuser.com/questions/281573/what-are-the-best-options-to-use-when-compressing-files-using-7-zip
REM best for <16GB of RAM
set command_7z=a -mx=9 -mfb=273 -ms=on
@nimaid
nimaid / ask_question.py
Last active January 21, 2020 18:16
Easy-to-use Python3 function for simple user input.
def ask_question(question='Please choose', options=['Y', 'N'], default=None):
opt_list = []
for opt in options:
if opt not in opt_list:
opt_list.append(opt)
opt_list = [x.upper() for x in opt_list]
if len(opt_list) < 1:
raise Exception('No options provided!')
if default != None:
default = default.upper()
@nimaid
nimaid / reverse_ssh_port_forward
Last active May 21, 2021 10:36
Reverse SSH Tunnel Port Forwarding Helper
#!/bin/bash
set -e
echo
echo "Reverse SSH Tunnel Port Forwarding Helper"
echo "v0.8.2 by nimaid"
echo
function usage
{
@nimaid
nimaid / listener_local_msf
Last active January 31, 2020 21:22
A helper script for opening a local Metasploit windows/meterpreter/reverse_tcp listener
#!/bin/bash
set -e
echo
function usage() {
echo Usage: $(basename $0) port
exit 1
}
@nimaid
nimaid / create_powerstager
Last active January 31, 2020 21:16
A simple helper script for creating Powerstager payloads.
#!/bin/bash
set -e
PYTHONEXE=python
PSSCRIPT=/root/TheFatRat/tools/power.py
POWERSTAGER="$PYTHONEXE $PSSCRIPT"
ICON=pdf.ico
echo