org.logi.crypto.test
Class TestKey

java.lang.Object
  |
  +--org.logi.crypto.Crypto
        |
        +--org.logi.crypto.test.TestKey

public class TestKey
extends Crypto

This application tests the various Key classes.

Author:
Logi Ragnarsson (logir@logi.org)
See Also:
Key

Fields inherited from class org.logi.crypto.Crypto
BIT, cdsPath, EMPTY_ARRAY, FOUR, keySource, NIBBLE, ONE, primeCertainty, random, TWO, ZERO
 
Method Summary
static DecryptSession createDecrypt(java.lang.String mode, EncryptionKey pub, DecryptionKey pri, java.io.PrintWriter details, java.io.PrintWriter summary)
           
static EncryptSession createEncrypt(java.lang.String mode, EncryptionKey pub, DecryptionKey pri, java.io.PrintWriter details, java.io.PrintWriter summary)
           
static KeyPair createKeys(java.lang.String keyType, java.io.PrintWriter details, java.io.PrintWriter summary)
           
static void main(java.lang.String[] arg)
           
static boolean test(java.lang.String keyType, java.util.Hashtable tests, java.util.Hashtable modes, java.io.PrintWriter details, java.io.PrintWriter summary)
           
 
Methods inherited from class org.logi.crypto.Crypto
binString, binString, ensureArrayLength, ensureArrayLength, equal, equalRelaxed, equalSub, fromHexNibble, fromHexString, fromString, fromString, hexString, hexString, hexString, hexString, hexString, initRandom, initRandom, makeClass, makeInt, makeLong, makeSessionKey, pastSpace, pickBits, pickBits, prettyPrint, prettyPrint, readBlock, readInt, trimArrayLength, trimArrayLength, trimLeadingZeroes, writeBytes, writeBytes, writeInt
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

createKeys

public static KeyPair createKeys(java.lang.String keyType,
                                 java.io.PrintWriter details,
                                 java.io.PrintWriter summary)
                          throws java.io.IOException

createEncrypt

public static EncryptSession createEncrypt(java.lang.String mode,
                                           EncryptionKey pub,
                                           DecryptionKey pri,
                                           java.io.PrintWriter details,
                                           java.io.PrintWriter summary)
                                    throws CryptoException

createDecrypt

public static DecryptSession createDecrypt(java.lang.String mode,
                                           EncryptionKey pub,
                                           DecryptionKey pri,
                                           java.io.PrintWriter details,
                                           java.io.PrintWriter summary)
                                    throws CryptoException

test

public static boolean test(java.lang.String keyType,
                           java.util.Hashtable tests,
                           java.util.Hashtable modes,
                           java.io.PrintWriter details,
                           java.io.PrintWriter summary)
                    throws java.io.IOException

main

public static void main(java.lang.String[] arg)
                 throws java.lang.Exception


Copyright (c) 1997-2001 Logi Ragnarsson - Distributed under the GPL