Class CreateEgg

java.lang.Object
  extended by CreateEgg

public class CreateEgg
extends java.lang.Object

This program can be used to generate Easter eggs for inclusion in software that is based on HTML pages. It works by accepting the query string that is to be used to access the easter egg, generating an MD5 hash of the query string that should be used to determine when the user has entered that query string in the URL (so that the clear-text query string does not appear in the application source), and then reading a file with the data that should be displayed when this egg is invoked and re-writing it to a DES-encrypted file with a key of the clear-text query string.

Author:
Neil A. Wilson

Field Summary
static java.lang.String CIPHER_NAME
          The name of the cipher to use for the encryption.
static int ITERATIONS
          The number of iterations to apply to the encryption algorithm.
static byte[] SALT
          The salt that will always be used for encryption.
 
Constructor Summary
CreateEgg()
           
 
Method Summary
static void displayUsage()
          Displays usage information for this program.
static void main(java.lang.String[] args)
          Parses the command-line arguments and performs the appropriate processing.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SALT

public static final byte[] SALT
The salt that will always be used for encryption. Since we don't care that much about security in this case, the salt can be weak for added convenience.


ITERATIONS

public static final int ITERATIONS
The number of iterations to apply to the encryption algorithm.

See Also:
Constant Field Values

CIPHER_NAME

public static final java.lang.String CIPHER_NAME
The name of the cipher to use for the encryption.

See Also:
Constant Field Values
Constructor Detail

CreateEgg

public CreateEgg()
Method Detail

main

public static void main(java.lang.String[] args)
                 throws java.lang.Exception
Parses the command-line arguments and performs the appropriate processing.

Parameters:
args - The command-line arguments provided to this program.
Throws:
java.lang.Exception - If a problem occurs while performing any processing.

displayUsage

public static void displayUsage()
Displays usage information for this program.