Re:A New Future for Icanhazip
by fulafel on Sunday June 06, 2021 @10:23PM
(#27418333)
> It does strike me as weird that there is seemingly no POSIX-compliant way to get your public Internet address, from my readings.
Because traditionally if you're doing things right, you're not using NAT, which is against IP specs and a nonstandard kludge. So you just take your socket and query its local endpoint address using getsockname and voila.
Because traditionally if you're doing things right, you're not using NAT, which is against IP specs and a nonstandard kludge. So you just take your socket and query its local endpoint address using getsockname and voila.