IAIK PKCS#11 Wrapper
version 1.5

iaik.pkcs.pkcs11.parameters
Class SkipJackPrivateWrapParameters

java.lang.Object
  |
  +--iaik.pkcs.pkcs11.parameters.SkipJackPrivateWrapParameters
All Implemented Interfaces:
java.lang.Cloneable, Parameters

public class SkipJackPrivateWrapParameters
extends java.lang.Object
implements Parameters

This class encapsulates parameters for the Mechanism.SKIPJACK_PRIVATE_WRAP.

Version:
1.0
Author:
Karl Scheibelhofer

Field Summary
protected  byte[] baseG_
          The base g value.
protected  byte[] password_
          The user-supplied password.
protected  byte[] primeP_
          The prime p value.
protected  byte[] publicData_
          The other party's key exchange public key value.
protected  byte[] randomA_
          The random Ra data.
protected  byte[] subprimeQ_
          The subprime q value.
 
Constructor Summary
SkipJackPrivateWrapParameters(byte[] password, byte[] publicData, byte[] randomA, byte[] primeP, byte[] baseG, byte[] subprimeQ)
          Create a new SkipJackPrivateWrapParameters object with the given attributes.
 
Method Summary
 java.lang.Object clone()
          Create a (deep) clone of this object.
 boolean equals(java.lang.Object otherObject)
          Compares all member variables of this object with the other object.
 byte[] getBaseG()
          Get the base g value.
 byte[] getPassword()
          Get the user-supplied password.
 java.lang.Object getPKCS11ParamsObject()
          Get this parameters object as an object of the CK_SKIPJACK_PRIVATE_WRAP_PARAMS class.
 byte[] getPrimeP()
          Get the prime p value.
 byte[] getPublicData()
          Get the other party's key exchange public key value.
 byte[] getRandomA()
          Get the random Ra data.
 byte[] getSubprimeQ()
          Get the subprime q value.
 int hashCode()
          The overriding of this method should ensure that the objects of this class work correctly in a hashtable.
 void setBaseG(byte[] baseG)
          Set the base g value.
 void setPassword(byte[] password)
          Set the user-supplied password.
 void setPrimeP(byte[] primeP)
          Set the prime p value.
 void setPublicData(byte[] publicData)
          Set the other party's key exchange public key value.
 void setRandomA(byte[] randomA)
          Set the random Ra data.
 void setSubprimeQ(byte[] subprimeQ)
          Set the subprime q value.
 java.lang.String toString()
          Returns the string representation of this object.
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

password_

protected byte[] password_
The user-supplied password.

publicData_

protected byte[] publicData_
The other party's key exchange public key value.

randomA_

protected byte[] randomA_
The random Ra data.

primeP_

protected byte[] primeP_
The prime p value.

baseG_

protected byte[] baseG_
The base g value.

subprimeQ_

protected byte[] subprimeQ_
The subprime q value.
Constructor Detail

SkipJackPrivateWrapParameters

public SkipJackPrivateWrapParameters(byte[] password,
                                     byte[] publicData,
                                     byte[] randomA,
                                     byte[] primeP,
                                     byte[] baseG,
                                     byte[] subprimeQ)
Create a new SkipJackPrivateWrapParameters object with the given attributes.
Parameters:
password - The user-supplied password.
publicData - The other party's key exchange public key value.
randomA - The random Ra data.
primeP - The prime p value.
baseG - The base g value.
subprimeQ - The subprime q value.
Method Detail

clone

public java.lang.Object clone()
Create a (deep) clone of this object.
Overrides:
clone in class java.lang.Object
Returns:
A clone of this object.

getPKCS11ParamsObject

public java.lang.Object getPKCS11ParamsObject()
Get this parameters object as an object of the CK_SKIPJACK_PRIVATE_WRAP_PARAMS class.
Specified by:
getPKCS11ParamsObject in interface Parameters
Returns:
This object as a CK_SKIPJACK_PRIVATE_WRAP_PARAMS object.

getPassword

public byte[] getPassword()
Get the user-supplied password.
Returns:
The user-supplied password.

getPublicData

public byte[] getPublicData()
Get the other party's key exchange public key value.
Returns:
The other party's key exchange public key value.

getRandomA

public byte[] getRandomA()
Get the random Ra data.
Returns:
The random Ra data.

getPrimeP

public byte[] getPrimeP()
Get the prime p value.
Returns:
The prime p value.

getBaseG

public byte[] getBaseG()
Get the base g value.
Returns:
The base g value.

getSubprimeQ

public byte[] getSubprimeQ()
Get the subprime q value.
Returns:
The subprime q value.

setPassword

public void setPassword(byte[] password)
Set the user-supplied password.
Parameters:
password - The user-supplied password.

setPublicData

public void setPublicData(byte[] publicData)
Set the other party's key exchange public key value.
Parameters:
publicData - The other party's key exchange public key value.

setRandomA

public void setRandomA(byte[] randomA)
Set the random Ra data.
Parameters:
randomA - The random Ra data.

setPrimeP

public void setPrimeP(byte[] primeP)
Set the prime p value.
Parameters:
primeP - The prime p value.

setBaseG

public void setBaseG(byte[] baseG)
Set the base g value.
Parameters:
baseG - The base g value.

setSubprimeQ

public void setSubprimeQ(byte[] subprimeQ)
Set the subprime q value.
Parameters:
subprimeQ - The subprime q value.

toString

public java.lang.String toString()
Returns the string representation of this object. Do not parse data from this string, it is for debugging only.
Overrides:
toString in class java.lang.Object
Returns:
A string representation of this object.

equals

public boolean equals(java.lang.Object otherObject)
Compares all member variables of this object with the other object. Returns only true, if all are equal in both objects.
Overrides:
equals in class java.lang.Object
Parameters:
otherObject - The other object to compare to.
Returns:
True, if other is an instance of this class and all member variables of both objects are equal. False, otherwise.

hashCode

public int hashCode()
The overriding of this method should ensure that the objects of this class work correctly in a hashtable.
Overrides:
hashCode in class java.lang.Object
Returns:
The hash code of this object.

IAIK PKCS#11 Wrapper
version 1.5

IAIK JavaSecurity Website http://jce.iaik.tugraz.at/

IAIK at Graz University of Technology, Austria, Europe
Copyright 2001-2004, IAIK, Graz University of Technology, Inffeldgasse 16a, 8010 Graz, Austria. All Rights Reserved.
version 1.5