IWGETID(8)

✨ IWGETID πŸ’… (that's section 8 of the Linux Programmer's Manual, bestie)

okay so real talk, this page is iwgetid(8) from the wireless-tools girlies and it's literally the most useful little gremlin in your toolbox 🌸


πŸŽ€ NAME πŸŽ€

iwgetid β€” reports the ESSID, NWID or AP/Cell Address of a wireless network, no cap πŸ’–


πŸ¦‹ SYNOPSIS πŸ¦‹

iwgetid [interface] [--raw] [--scheme] [--ap] [--freq]
                   [--mode] [--protocol] [--channel]

πŸ‘‘ DESCRIPTION πŸ‘‘

so like, iwgetid is the girl you call when you need to know the NWID, ESSID or AP/Cell Address of the wireless network you're currently riding with ✨ The info it hands you is literally the exact same tea that iwconfig spills, except iwgetid is way easier to slot into your scripts, which is the whole point bestie 🫢

by default, iwgetid prints the ESSID of the device, and if the device is out here with no ESSID at all, it'll print its NWID instead. periodt πŸ’…

the default formatting output is pretty-print. cute, right? πŸŽ€


πŸ’– OPTIONS πŸ’–

  • --raw β€” this one disables the pretty-printing of the info, so you get the raw, unfiltered truth 😌 this option is orthogonal to the other options (except --scheme), so with the right lil combination of options you can print the raw ESSID, AP Address or Mode πŸ”₯ this format is ideal when you're storing the result of iwgetid as a variable in Shell or Perl scripts, or when you wanna pass the result as an argument on the command line of iwconfig. it's giving utility 🧚
  • --scheme β€” similar to the previous one, bestie: it disables the pretty-printing of the info AND removes all characters that aren't alphanumerics (so like, space, punctuation and control characters β€” bye bye πŸ‘‹). the resulting output is a valid Pcmcia scheme identifier (which may be used as an argument of the command cardctl scheme). this format is also ideal when you're using the result of iwgetid as a selector in Shell or Perl scripts, or as a file name 🌸 so versatile honestly
  • --ap β€” displays the MAC address of the Wireless Access Point or the Cell πŸ“‘
  • --freq β€” displays the current frequency or channel used by the interface 🌈
  • --channel β€” displays the current channel used by the interface. the channel is determined using the current frequency and the frequency list provided by the interface πŸ” (yes she does the math herself, iconic)
  • --mode β€” displays the current mode of the interface πŸ’«
  • --protocol β€” displays the protocol name of the interface. this lets you identify all the cards that are compatible with each other and accept the same type of configuration, so you can matchmake them πŸ₯° this can also be used to check Wireless Extension support on the interface, because this is the only attribute that all drivers supporting Wireless Extension are mandated to support. it's the vibe check of attributes, fr fr πŸ‘‘
not me reminding you that --raw is orthogonal to everything except --scheme πŸ’€ keep that in mind before you go mixing flags like it's a smoothie

🌈 SEE ALSO 🌈

iwconfig(8), ifconfig(8), iwspy(8), iwpriv(8).

go read those too, they're all part of the same friend group πŸ’œ


and that's the whole page bestie!! this one came from wireless-tools, dated 02 December 2003 β€” oldie but a goodie, still slaying after all these years πŸ‘‘πŸ’– mwah, go check your ESSID πŸ¦‹βœ¨