gnu.crypto.key
public interface IKeyAgreementParty
The visible methods of an key agreement protocol participating party.
Version: $Revision: 1.2 $
Method Summary | |
---|---|
byte[] | getSharedSecret() Returns the byte array containing the shared secret as generated by this party. |
void | init(Map attributes) Sets up the instance to operate with specific attributes. |
boolean | isComplete() Returns |
String | name() Returns the canonical name of the key agreement protocol. |
OutgoingMessage | processMessage(IncomingMessage in) Processes an incoming message at one end, generating a message that will be processed by the other party(ies). |
void | reset() Resets this instance for re-use with another set of attributes. |
Returns the byte array containing the shared secret as generated by this party.
Returns: the generated shared secret.
Throws: KeyAgreementException if the key agreement is not yet initialised, or is initialised but the exchange is still in progress.
Sets up the instance to operate with specific attributes.
Parameters: attributes a map of name-values used by concrete implementations.
Throws: KeyAgreementException if an exception occurs during the setup.
Returns true
if the party in the key agreement protocol
exchange has completed its part of the exchange. If this is the case an
IllegalStateException is thrown for any method invocation except
init()
or reset()
.
Returns: true
if this party has completed its part of the key
agreement protocol exchange; false
otherwise.
Returns the canonical name of the key agreement protocol.
Returns: the canonical name of the key agreement protocol.
Processes an incoming message at one end, generating a message that will be processed by the other party(ies).
Parameters: in the incoming message.
Returns: an outgoing message, or null
if this is an
intermediary step that does not cause any output.
Throws: KeyAgreementException if an exception occurs during the processing of the incoming message, or during the generation of the outgoing message.