python

So in order to teach myself how to create multi-threaded python apps I decided to have a go this morning at writing a simple MD5 bruteforcer (using a wordlist).

The way this works is that you create worker threads and each worker thread pulls an item from the queue and processes it; when finished it pulls another item from the queue and so on.

123456789101112131415161718192021222324252627282930313233343536373839#!/usr/bin/env python # md5brute.py import sys,Queue,threading,hashlib,os… Continue reading

So I created synothumb.sh a while ago to quickly create thumbnails for my Synology DS211j NAS box. Unfortunately many people wanted something that would run easily on a mac so i have just rewritten this to run using python and the PIL module (how to install PIL).

You’ll need to mount the remote drive via nfs(network file share) and not afp(apple file protocol)

Here’s the code. I strongly… Continue reading

So I wanted a quick way to create an MD5 sum of all the files recursively in a directory so i wrote a quick python script to do this.

Basically run the python file and provide the directory you want to check. This will create a new txt file named md5sYYYY-MM-DD-HHMM.txt containing a list of the files found along with their md5sums.

Then to check the the files run it… Continue reading

So I wanted to identify quickly character frequency in a text file and quickly throw this out as a bar chart.

As I enjoy python it made sense to code it in python. The bar chart uses the pyplot bits from matplotlib.

It was also important to import collections because dictionaries are unordered and the bar chart would not display in alphabetical order.

12345C:\Users\phillipsme\Desktop\python>python.exe charfreqency.py cipher.txt OrderedDict([('a', 135), ('b',… Continue reading

So it’s annoying when you’re testing AV and you need to create an eicar virus. Usually the AV will keep deleting the file and your text string.

This simple code is given the file name and will produce the output file. The benefit of using this script is that the eicar string is not actually stored inside the script as clear text.

12345678910111213141516171819202122232425#!/usr/bin/env python # Author: phillips321 # Site:… Continue reading