|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Object
|
+--org.logi.crypto.Crypto
|
+--org.logi.crypto.protocols.EncryptedKeyExClient
Exchange keys by sending an encrypted key from this class to the corresponding EncryptedKeyExServer.
EncryptedKeyExServer| Fields inherited from class org.logi.crypto.Crypto |
BIT, cdsPath, EMPTY_ARRAY, FOUR, keySource, NIBBLE, ONE, primeCertainty, random, TWO, ZERO |
| Constructor Summary | |
EncryptedKeyExClient(EncryptionKey key,
Key sessionKey)
Create a new EncryptedKeyExClient object. |
|
EncryptedKeyExClient(EncryptionKey key,
SigningKey signKey,
Key sessionKey)
Create a new EncryptedKeyExClient object. |
|
| Method Summary | |
boolean |
completed()
Returns true iff this end of the protocol i completed. |
int |
maxMessageSize()
Returns the maximum expected size of a message for this protocol. |
byte[] |
message(byte[] received)
Get the next message in the protocol. |
Key |
sessionKey()
Returns the key if it has been decided upon, or null otherwise. |
| 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 |
| Constructor Detail |
public EncryptedKeyExClient(EncryptionKey key,
Key sessionKey)
key to encrypt sessionKey and then
sends it to the server.
public EncryptedKeyExClient(EncryptionKey key,
SigningKey signKey,
Key sessionKey)
key to encrypt sessionKey and then
sends it to the server.
If signKey is not null, then the
session key will be signed with this key.
| Method Detail |
public Key sessionKey()
null otherwise.sessionKey in interface InterKeyExClientpublic boolean completed()
completed in interface InterProtocolClientpublic int maxMessageSize()
maxMessageSize in interface InterProtocolClient
public byte[] message(byte[] received)
throws CryptoProtocolException
received is the last message received form the server
and has not yet been sent to the client.
The returned value is the next message to send to the server or null if no more messages need to be sent and the protocol is terminated.
message in interface InterProtocolClientCryptoProtocolException - if a problem arises with the
protocol.
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
Copyright (c) 1997-2001 Logi Ragnarsson - Distributed under the GPL