Is there any reason why the following code would return the IPv6 loopback 
address and not the actual physical IPv4 address of the client?

import io.netty.handler.codec.mqtt.MqttMessage;
import org.apache.activemq.artemis.core.protocol.mqtt.MQTTInterceptor;
import org.apache.activemq.artemis.spi.core.protocol.RemotingConnection;

public class MyInterceptor implements MQTTInterceptor {
    @Override
    public boolean intercept(final MqttMessage mqttMessage, final 
RemotingConnection connection) {
      System.out.println("RemotingConnection: " + 
connection.getRemoteAddress());
      return true;
   }
}

This prints out: RemotingConnection: [0:0:0:0:0:0:0:1]:46682

Regards,

William Crowell


This e-mail may contain information that is privileged or confidential. If you 
are not the intended recipient, please delete the e-mail and any attachments 
and notify us immediately.

Reply via email to