/** * Indicates that the security is time-outed, is not supported by the other end. * * @param evt Details about the event that caused this message. */ @Override public void securityTimeout(CallPeerSecurityTimeoutEvent evt) { timer.cancel(); // fail peer, call if (evt.getSource() instanceof AbstractCallPeer) { try { CallPeer peer = (CallPeer) evt.getSource(); OperationSetBasicTelephony<?> telephony = peer.getProtocolProvider().getOperationSet(OperationSetBasicTelephony.class); telephony.hangupCallPeer( peer, OperationSetBasicTelephony.HANGUP_REASON_ENCRYPTION_REQUIRED, "Encryption Required!"); } catch (OperationFailedException ex) { Logger.getLogger(getClass()).error("Failed to hangup peer", ex); } } }