One question about getaddrinfo invoked in _dbus_listen_tcp_socket

Elvis Qin elvis.qin at broadcom.com
Fri Sep 30 01:58:02 UTC 2016


Hello Thiago Macieira



Please read my response for above subject.





First of all, don't use TCP.

<Elvis>

For different machine I need use TCP.



Second, please read up on the recent case of exploit on Jeep cars. Hint: it

was caused by dbus-daemon used on TCP.



Third, 123456 is not a valid port number. That's probably why getaddrinfo
is

failing.

<Elvis>

This port 123456 is just one example. I Know getaddrinfo ai_flags usage for
network socket.





You know

Uclibc define this 2 flags

# define AI_PASSIVE     0x0001  /* Socket address is intended for `bind'.
*/

# define AI_ADDRCONFIG  0x0020  /* Use configuration of this host to
choose returned
address type..  */



My concern, this file you already define *AI_ADDRCONFIG = 0 not Linux
standard in dbus-sysdeps-unix.c source code line 98.*



*hints.ai_flags = AI_ADDRCONFIG | AI_PASSIVE;   ==== > actually if
AL_ADDRCONFIG is not 0x0020 but 0, this ai_flags still is AI_PASSIVE.*



*If my understanding is wrong, please correct me.*



*By the way, suppose if all the linux interface is not UP maybe not
created at all. I think this getaddrinfo MUST failed with EAI_NONAME =
-2.*





*Thanks*

*Elvis *
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/dbus/attachments/20160930/d3ba9ad5/attachment.html>


More information about the dbus mailing list