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

So I needed pycrypto for some AES bits I was doing.

Unfortunately I was playing in windows so it wasn’t as easy as apt-get install.

Download pycrypto from here. Once downloaded extract it and then you’ll need to run ‘python setup.py build’. Unfortunately python 2.7.5 looks for visual studio 2007 so you need to trick it into using the version of visual studio you having installed, in my case… Continue reading