SOCKET_...AMEINFO(1p)
π NAME π
okay so <pink>socket_getnameinfo</pink> β it's a command-line tool that wraps up the <purple>getnameinfo(3)</purple> resolver, bestie. that's the whole vibe β¨
πΈ SYNOPSIS πΈ
socket_getnameinfo [options...] address port
π¦ DESCRIPTION π¦
so basically this tool is a cute lil convenient command-line wrapper around the <purple>getnameinfo(3)</purple> resolver function. it does one single reverse lookup and turns an address plus a port number into their host and service names. periodt π
and like, why do you care? because it's mainly useful when you're debugging name resolution problems π΅οΈβοΈ β it lets you peek directly at what <purple>getnameinfo(3)</purple> is doing itself, totally outside of any real program that's trying to use it. no middleman, no extra chaos, just the raw behaviour. iconic honestly π
β¨ OPTIONS β¨
--address,-AADDRβ the numerical form of the address you wanna look up. if you don't pass it, it'll just use the first positional argument instead π«Ά--port,-PPORTβ the port number you wanna look up. if you don't pass it, it'll use the second positional argument π--dgramβ sets the<purple>NI_DGRAM</purple>flag, so it looks up a<purple>SOCK_DGRAM</purple>(udp) port allocation instead of<purple>SOCK_STREAM</purple>(tcp). lowkey important, don't skip it π₯--helpβ shows a help summary and dips out βοΈ
π NOTE π
upstream, this script is actually called <pink>getnameinfo</pink> β but on Debian it got renamed. so if you're out here looking for getnameinfo and it's giving nothing, that's why bestie π
π AUTHOR π
Paul Evans <leonerd@leonerd.org.uk>
and that's the whole page, no cap β¨ this lil gem is part of the User Contributed Perl Documentation for perl v5.40.0, dated 2025-02-01 β so like, if you're running something older, maybe don't come for me π. go resolve some names, you main character ππ
π¦ where this page comes from
- debian trixie: libsocket-getaddrinfo-perl 0.22-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libsocket-getaddrinfo-perl 0.22-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libsocket-getaddrinfo-perl 0.22-6 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms