Class HandshakeState

java.lang.Object
jadex.ipc.impl.security.HandshakeState

public class HandshakeState extends Object
Class maintaining the state of a handshake in progress.
  • Field Details

    • resultfut

      protected jadex.future.Future<ICryptoSuite> resultfut
      Future used to wait for the handshake to finish.
    • conversationid

      protected String conversationid
      Conversation ID.
    • cryptosuite

      protected ICryptoSuite cryptosuite
      The crypto suite once initialized
    • expirationtime

      protected long expirationtime
      Time when the handshake expires.
    • arrivedmessages

      protected Set<String> arrivedmessages
      Arrived handshake messages to filter duplicates.
  • Constructor Details

    • HandshakeState

      public HandshakeState()
  • Method Details

    • setExpirationTime

      public void setExpirationTime(long expirationtime)
      Sets the expiration time of the handshake.
      Parameters:
      expirationtime - The expiration time of the handshake.
    • getExpirationTime

      public long getExpirationTime()
      Gets the expiration time of the handshake.
      Returns:
      The expiration time of the handshake.
    • getResultFuture

      public jadex.future.Future<ICryptoSuite> getResultFuture()
      Returns the result future.
      Returns:
      The result future.
    • setResultFuture

      public void setResultFuture(jadex.future.Future<ICryptoSuite> resultfut)
      Sets the result future.
      Parameters:
      resultfut - The result future.
    • getConversationId

      public String getConversationId()
      Gets the conversation ID.
      Returns:
      The conversation ID.
    • setConversationId

      public void setConversationId(String conversationid)
      Sets the conversation ID.
      Parameters:
      conversationid - The conversation ID.
    • getCryptoSuite

      public ICryptoSuite getCryptoSuite()
      Gets the crypto suite.
      Returns:
      The crypto suite.
    • setCryptoSuite

      public void setCryptoSuite(ICryptoSuite cryptosuite)
      Sets the crypto suite.
      Parameters:
      cryptosuite - The crypto suite to set.
    • isDuplicate

      public boolean isDuplicate(BasicSecurityMessage msg)
      Filters for duplicate handshake messages.
      Parameters:
      msg - The message
      Returns:
      True, if message is duplicate.