Crank v0.0.5
============

Author: Matthew Russell <twig5151@yahoo.com>
Homepage: http://crank.sourceforge.net/

See 'BUGS' for current bugs.
See 'TODO' for planned features soon to be implemented.
See 'HISTORY' for changes over versions.

Installation
============

You'll need gdk/gtk+ to build crank.

On Linux:
---------

- Change directory to where Crank has been unpacked. eg. 

% cd crank-0.0.5

- Compile the sources:

% make

- Run crank from this directory (needs the data directory 'data/' to be in
this location):

% ./crank

On Windows
----------

Crank can be compiled under Windows using (at least) mingw gcc and the
Win32 port of GTK+. You can download precompiled binary packages from
Sourceforge, but if you wish to compile it yourself, here's (vaguely) how:

1. Download and install gcc mingw (http://www.mingw.org)
2. Download the gtk+ developer packages from:
http://user.sgic.fi/~tml/gimp/win32/downloads.html
3. Unpack these packages into some directory
4. Rename 'Makefile.mingw' as just 'Makefile', and edit it to tell it the
location of the unpacked gtk+/gdk etc libraries.
5. Run 'make'
6. Copy the following DLLs from the gtk directories to your compilation
directory (or one of your system DLL folders):

glib-1.3.dll
inconv-1.3.dll
gtk-1.3.dll
gmodule-1.3.dll
gnu-intl.dll
gdk-1.3.dll  

7. Crank should (might) run correctly..

Usage Summary
=============

The main text area in Crank is a view of the source text using the current
key. This current key is displayed using two rows of letters. This
indicates the current substitution being employed.

The 'Key Controls' bring up a controls box including the following:
Invert - find the inverse of the substitution
Shift <<, Shift >> - do a Caesar shift on the key
Reverse - Reverse the order of the key
Complete - Fill in any blanks in an arbitrary fashion
Clear - Remove all key entries
Change (x) - (y) - Change the key mapping for individual letters

'Preprocess source' allows you to strip away numbers, punctuation and
whitespace.

'Statistics' displays 1, 2, and 3 letter combination counts (unigram,
bigram and trigram, respectively), as well as error summaries from the
expected values.

'Break' invokes the automatic cracker, which isn't that strong yet. It
works by randomly trying to improve the key's error rating by slightly
altering the key. The trial key alterations are minor at the start, but
they begin increasing the longer it's been since the last improvement. To
successfully decrypt a message, you generally need about 2-3000 characters
of text (excluding whitespace, punctuation, etc), though it can be more or
less depending on the exact ciphertext.

A sample encrypted text file has been given - "ciphertext.txt" - which you
can use Crank to decrypt.
