Programs & Scripts

Unfortunately, I don’t have a lot of code that I can put on the web. Many of the things I write contain information that needs to be “cleaned” to protect confidential information pertaining to current and past employers. Additionally the bulk of what I’ve written in the past is contractually owned by previous employers and I am not legally allowed to make them available.

On some scripts you may need to right click (command-click on a mac) the download link and select “save link as” from the context menu.

pageRate

Quick script I put together to break down the per/page cost of doing a comic book. Easily adapted to other things. [download]

Video of how it works:

 

Art Inspiration

Point it at a directory full of images you’ve saved, and it will pick three at random. Use one for subect, another for composition, and another for pallet… or however you want.

art_inspiration_screenshot

Download

Netapp Capacity Calcuator

This is a c# app I put together to help people quickly calculate usable space on a netapp network storage appliance. This is old, and needs to be updated.

Download :: Homepage

mkoinkcf.sh

This is a script I always put before the && oinkmaster.pl in my cronjobs. It looks for rules that have been commented out with a # and makes sure they stay commented out. The real work is done by makesidex.pl which is distributed with oinkmaster. I just noticed that it comes up on the snort mailing list and a couple of other places, but doesn’t really come up on google. This might, and thus help people fix it on their own instead of posting to the mailing list. It will need editing depending on where things are, but since it’s 2 lines, I hope it won’t be too hard to figure out.

Download

ftpload.pl

ftpload.pl is a simple threaded load tester for ftpdownloads. It requires a version of perl that

supports threading, and several cpan modules, which can be installed via the install.sh

script on unix.

Usage:

 

ftpload.pl -h host -u username -p password -f file -r reps -s sets

ftpload.pl --host host --user username --password password --file file --reps reps --sets sets

ftpload.pl --host=host --user=username --password=password --file=file --reps=reps --sets=sets

The reps are the number of hits per set, so if you wanted to do 100 reps and

10 sets ftpload.pl -h localhost -u me -p password -r 100 -s 10 -f somefile.tgz

username & password, if left blank will use anonymous & ftpload@example.com respectively.

By way of a quick warning: If you really crank this thing, it can hang your box. I hung a 3ghz w/ 1Gb of ram pretty easily with -r 200 -s 40, so be careful.

Download

faxstat

This is a quick cgi script that was written to use hylafax’s faxstat command to

show the status of outgoing faxes that have been recently submitted. It displays

a text file (pretty easy to change to html) so that users can see what is going

on with their faxes with out having to have access to the system.

Download

mkoinkcf.sh

This is a script I always put before the && oinkmaster.pl in my cronjobs. It looks for rules that have been commented out with a # and makes sure they stay commented out. The real work is done by makesidex.pl which is distributed with oinkmaster. I just noticed that it comes up on the snort mailing list and a couple of other places, but doesn’t really come up on google. This might, and thus help people fix it on their own instead of posting to the mailing list. It will need editing depending on where things are, but since it’s 2 lines, I hope it won’t be too hard to figure out.

Download

ViewSec

Security Auditing Script meant to be run from cron:

+ Lists any services either stopped or started

+ Lists any users added or removed

+ Lists any kernel modules added or removed

+ Lists any (new|deleted) s(u|g)id programs owned by root, or grouped root.

+ Sends an email if any of the above are detected.

Download

SnortAlert

This is a quick little script which queries a snort/acid db, then does a diff on the last results and cleans up the output

effectively giveing a snapshot of any new alerts. This is best when run from cron, as the output will be delivered via mail.

Download