borland Packages  Class Hierarchy  datastore Package 

Tf class

java.lang.Object
   +----com.borland.datastore.Tf

About the Tf class

Properties  Methods  

Note: This is a feature of JBuilder Professional and Enterprise.

This class is used internally by other com.borland classes. You should never use this class directly.

Twofish is an AES candidate algorithm. It is a balanced 128-bit Feistel cipher, consisting of 16 rounds. In each round, a 64-bit S-box value is computed from 64 bits of the block, and this value is xored into the other half of the block. The two half-blocks are then exchanged, and the next round begins. Before the first round, all input bits are xored with key- dependent "whitening" subkeys, and after the final round the output bits are xored with other key-dependent whitening subkeys; these subkeys are not used anywhere else in the algorithm.

Twofish was submitted by Bruce Schneier, Doug Whiting, John Kelsey, Chris Hall and David Wagner.

Reference:

  1. TWOFISH2.C -- Optimized C API calls for TWOFISH AES submission, Version 1.00, April 1998, by Doug Whiting.


Tf properties

*Read-only properties **Write-only properties

Properties implemented in java.lang.Object

Tf methods

Methods implemented in this class

Methods implemented in java.lang.Object


Tf methods

decrypt(byte[], int, byte[], int)

  public void decrypt(byte[] in, int inOff, byte[] out, int outOff)
Decrypt exactly one block of ciphertext.

Parameters:

in
- The ciphertext.
inOff
- Index of in from which to start considering data.
sessionKey
- The session key to use for decryption.

Returns: The plaintext generated from a ciphertext using the session key.

decryptKey(byte[])

  public final void decryptKey(byte[] src)

encrypt(byte[], int, byte[], int)

  public void encrypt(byte[] in, int inOff, byte[] out, int outOff)
Encrypt exactly one block of plaintext.

Parameters:

in
- The plaintext.
inOff
- Index of in from which to start considering data.
sessionKey
- The session key to use for encryption.

encryptCBC(byte[], int, byte[], int, byte[], int, int)

  public void encryptCBC(byte[] iv, int ivOff, byte[] src, int srcOff, byte[] dest, int destOff, int length)

encryptString(java.lang.String)

  public final byte[] encryptString(String src)

finalize()

  public void finalize()

Overrides: java.lang.Object.finalize()

makeKey(byte[], int)

  public void makeKey(byte[] k, int length)
Expand a user-supplied key material into a session key.

Parameters:

key
- The 64/128/192/256-bit user-key to use.

makeKey(char[])

  public final void makeKey(char[] src)
Expand a user-supplied key material into a session key.

makeSalt(byte[], int, int)

  public final void makeSalt(byte[] buf, int off, int length)