Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [mosquitto-dev] IPv6 + TLS support?

Hi Aaron,

I believe that this was a historical requirement that came from
openssl, but I'm not entirely sure. It does seem to work but I'm
slightly cautious to say just go ahead. I think I need to add a load
of ipv6 related tests.

Cheers,

Roger


On Mon, May 16, 2016 at 11:10 AM, Aaron Tunney <Aaron.Tunney@xxxxxxxx> wrote:
> Hi,
>
> Does the Mosquitto library support IPv6 + TLS? From reading the code, it
> looks like the library is hard-coded to use IPv4 when WITH_TLS is defined.
>
> See _mosquitto_try_connect in net_mosq.c:
>
> memset(&hints, 0, sizeof(struct addrinfo));
>
> #ifdef WITH_TLS
>
> if(mosq->tls_cafile || mosq->tls_capath || mosq->tls_psk){
>
> hints.ai_family = PF_INET;
>
> }else
>
> #endif
>
> {
>
> hints.ai_family = PF_UNSPEC;
>
> }
>
>
> We are writing an iOS app that talks to an IoT device over MQTT. When our
> app is connected to an NAT64-based network, it is unable to connect to our
> device over the Internet. The app connects fine if we set hints.aifamily to
> PFINET6 or PF_UNSPEC though.
>
> Is IPv4-only support intentional? Would we run into side effects if we
> permanently set hints.aifamily to PF_UNSPEC?
>
> Thanks!
>
> Aaron
>
>
> Aaron Tunney
> Senior Software Engineer (iOS)
>
> Direct: +44 207 780 4776
>
> aaron.tunney@xxxxxxxx   |   http://www.akqa.com
>
> AKQA, 1 St John's Lane, London EC1M 4BL, UK
> Registered in England: 2964394
>
> Confidentiality notice:
> The information transmitted in this email and/or any attached document(s) is
> confidential and intended only for the person or entity to which it is
> addressed and may contain privileged material. Any review, retransmission,
> dissemination or other use of, or taking of any action in reliance upon this
> information by persons or entities other than the intended recipient is
> prohibited. If you received this in error, please contact the sender and
> delete the material from any computer.
>
> _______________________________________________
> mosquitto-dev mailing list
> mosquitto-dev@xxxxxxxxxxx
> To change your delivery options, retrieve your password, or unsubscribe from
> this list, visit
> https://dev.eclipse.org/mailman/listinfo/mosquitto-dev


Back to the top