|
Java Card 2.1 Platform Final Revision 1.0 |
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
The DSAKey interface is the base interface for the DSA algorithms private and
public key implementaions. A DSA private key implementation must also implement
the DSAPrivateKey
interface methods. A DSA public key implementation must also implement
the DSAPublicKey
interface methods.
When all four components of the key (X or Y,P,Q,G) are set, the key is initialized and ready for use.
DSAPublicKey
,
DSAPrivateKey
,
KeyBuilder
,
Signature
,
KeyEncryption
Method Summary | |
short |
getG(byte[] buffer,
short offset)
Returns the subprime parameter value of the key in plain text. |
short |
getP(byte[] buffer,
short offset)
Returns the base parameter value of the key in plain text. |
short |
getQ(byte[] buffer,
short offset)
Returns the prime parameter value of the key in plain text. |
void |
setG(byte[] buffer,
short offset,
short length)
Sets the subprime parameter value of the key. |
void |
setP(byte[] buffer,
short offset,
short length)
Sets the base parameter value of the key. |
void |
setQ(byte[] buffer,
short offset,
short length)
Sets the prime parameter value of the key. |
Method Detail |
public void setP(byte[] buffer, short offset, short length) throws CryptoException
buffer
- the input bufferoffset
- the offset into the input buffer at which the base parameter value beginslength
- the length of the base parameter valueCryptoException.ILLEGAL_VALUE
if the input parameter data length is inconsistent
with the implementation or if input data decryption is required and fails.
Note:
javacardx.crypto.KeyEncryption
interface and the Cipher
object specified via setKeyCipher()
is not null
, the base parameter value is decrypted using the Cipher
object.
public void setQ(byte[] buffer, short offset, short length) throws CryptoException
buffer
- the input bufferoffset
- the offset into the input buffer at which the prime parameter value beginslength
- the length of the prime parameter valueCryptoException.ILLEGAL_VALUE
if the input parameter data length is inconsistent
with the implementation or if input data decryption is required and fails.
Note:
javacardx.crypto.KeyEncryption
interface and the Cipher
object specified via setKeyCipher()
is not null
, the prime parameter value is decrypted using the Cipher
object.
public void setG(byte[] buffer, short offset, short length) throws CryptoException
buffer
- the input bufferoffset
- the offset into the input buffer at which the subprime parameter value beginslength
- the length of the subprime parameter valueCryptoException.ILLEGAL_VALUE
if the input parameter data length is inconsistent
with the implementation or if input data decryption is required and fails.
Note:
javacardx.crypto.KeyEncryption
interface and the Cipher
object specified via setKeyCipher()
is not null
, the subprime parameter value is decrypted using the Cipher
object.
public short getP(byte[] buffer, short offset)
buffer
- the output bufferoffset
- the offset into the output buffer at which the base parameter value startspublic short getQ(byte[] buffer, short offset)
buffer
- the output bufferoffset
- the offset into the output buffer at which the prime parameter value beginspublic short getG(byte[] buffer, short offset)
buffer
- the output bufferoffset
- the offset into the output buffer at which the subprime parameter value begins
|
Submit a bug or feature Java and Java Card are trademarks or registered trademarks of Sun Microsystems, Inc. in the US and other countries. Copyright 1993-1999 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A. All Rights Reserved. |
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |