Try to open a socket and compare source IP with destination to detect
local interface
This change fixes an issue where if /proc/sys/net/ipv4/ip_nonlocal_bind  is set to 1, remote
addresses where detected as local.