// sending authentication message
final Message authenticationMessage = MessageStaticFactory.newSTUNMessageInstance(STUNMessageClass.REQUEST,
STUNMessageMethod.AUTHENTICATE);
authenticationMessage.addAttribute(new Token(this.authentikationToken));
logger.info("Sending AuthenticationMessage: {}", authenticationMessage); //$NON-NLS-1$
messageWriter.writeMessage(authenticationMessage);
// receiving authentication acknowledgment message
final Message reveivedAckMessage = messageReader.readSTUNMessage(toBeAuthenticated.getInputStream());
if (this.hpUtil.isAuthenticationAcknowledgmentMessage(reveivedAckMessage)) {
synchronized (sharedLock) {
// sending second authentication acknowledgment message