Package gnu.java.zrtp

Class ZrtpStateClass


  • public class ZrtpStateClass
    extends Object
    This class is the ZRTP protocol state engine. This class is responsible to handle the ZRTP protocol. It does not handle the ZRTP HMAC, DH, and other data management. This is done in class ZRtp which is the parent of this class. The methods of this class implement the ZRTP state actions.
    Author:
    Werner Dittmann <Werner.Dittmann@t-online.de>
    • Constructor Detail

      • ZrtpStateClass

        protected ZrtpStateClass​(ZRtp p)
    • Method Detail

      • getTimeoutValue

        public long getTimeoutValue()
      • stopZrtpStates

        protected void stopZrtpStates()
      • dispatchEvent

        protected void dispatchEvent()
      • evInitial

        protected void evInitial()
      • evAckDetected

        protected void evAckDetected()
      • evAckSent

        protected void evAckSent()
      • evWaitCommit

        protected void evWaitCommit()
      • evCommitSent

        protected void evCommitSent()
      • evWaitDHPart2

        protected void evWaitDHPart2()
      • evWaitConfirm1

        protected void evWaitConfirm1()
      • evWaitConfirm2

        protected void evWaitConfirm2()
      • evWaitConfAck

        protected void evWaitConfAck()
      • evWaitClearAck

        protected void evWaitClearAck()
      • evSecureState

        protected void evSecureState()
      • subEvWaitRelayAck

        protected boolean subEvWaitRelayAck()
      • evWaitErrorAck

        protected void evWaitErrorAck()
      • sendSASRelay

        protected void sendSASRelay​(ZrtpPacketSASRelay relay)
        Send a SAS relay packet. Get the SAS relay packet and send it. It stores the packet in the sentPacket variable to enable resending. The method switches to secure sub-state WaitSasRelayAck.
        Parameters:
        relay - The relay packet to send
      • isMultiStream

        protected boolean isMultiStream()
        Returns:
        the multiStream
      • setMultiStream

        protected void setMultiStream​(boolean multiStream)
        Parameters:
        multiStream - the multiStream to set
      • isInState

        protected boolean isInState​(ZrtpStateClass.ZrtpStates state)
        Check current state of the ZRTP state engine
        Parameters:
        state - The state to check.
        Returns:
        Returns true id ZRTP engine is in the given state, false otherwise.