Skip to content

Tinone 71

Stralci dal web

  • HOME
  • About me..
  • News
  • CIAO MAX
  • GALLERIE
    • Comics 2022
    • Fuochi Sant’ Eusebio 2022
    • Fulmini luglio 2021
    • Lago Antrona
    • Ferrara
    • Saline di Comacchio
    • Lido di Pomposa
    • Foto Varie
    • Pietra Ligure 2019
    • Schiranna 2019
    • Laveno Dicembre 2019
    • Incendio Ghirla
    • Forte di Bard Aosta
    • Costa Fascinosa 2023
  • MOTO
    • YAMAHA R1 1999
    • HONDA VTR 1000
    • CBR 600F
    • MUGELLO 2008
  • Privacy Policy
  • Assistenza Remota HopTodesk
  • Home
  • How to Find Wi-Fi Network Passwords from Command Line on Mac | OSXDaily
  • Senza categoria

How to Find Wi-Fi Network Passwords from Command Line on Mac | OSXDaily

Admin 5 Settembre 2016 3 min read

How to Find Wi-Fi Network Passwords from Command Line on Mac

wpa

 

Given the complexity of some wi-fi network passwords combined with the general infrequency of entering them and that they’re typically saved on use, it’s not terribly unusual to forget what a specific routers wireless password is. Fortunately, if you’re on a Mac, there are a few ways to go about finding those lost or forgotten wi-fi router login details.

Perhaps the easiest method is recovering forgotten wireless passwords with KeyChain Access in OS X, but if you’re an advanced Mac user you may wish to retrieve the same data from the command line, and that’s what we’re going to demonstrate here.

Find & Show Wi-Fi Network Passwords from the Command Line in OS X

To get started with this trick, open the Terminal app from /Applications/Utilities/, then use the following command syntax to find and display the password for a specific wireless network:

security find-generic-password -ga "ROUTERNAME" | grep "password:"

Replace “ROUTERNAME” with the exact name of the wireless router you want to retrieve the password for. You do not need to be connected to that network to recover the password for that network, you only need to have joined it once, and saved the password for it when you connected at that time.

For example, let’s say the wireless router name is “YOUR-ROUTER”, the command would look like the following:

security find-generic-password -ga "YOUR-ROUTER" |grep "password:"

Hitting return and running that command string will request an administrator login (or you can prefix with sudo), which will then return the password for the given router, looking like the following:

$ security find-generic-password -ga "YOUR-ROUTER" |grep "password:"
password: "osxdailysecretpassword"

In this example, the password for ‘YOUR-ROUTER” is “osxdailysecretpassword”, minus the quotations.

This command can be particularly helpful if you combine it with the ability to list all wireless networks a Mac has connected to before, particularly if you can’t remember the exact name or spelling of a specific router.

You can also leave off the pipe to grep, which will report back additional details about the queried router, most of the added data reported isn’t particularly useful though, thus why we’re cleaning up the output and shortening it with grep. For those curious, the command return without the grep pipe would look something like the following:

$ security find-generic-password -ga "YOUR-ROUTER-NAME"
keychain: "/Library/Keychains/System.keychain"
class: "genp"
attributes:
0x00000007 blob="YOUR-ROUTER-NAME"
0x00000008 blob=NULL
"acct"blob="YOUR-ROUTER-NAME"
"cdat"timedate=0x52192841772471472498124818A00 "20150723143649Z\000"
"crtr"uint32=NULL
"cusi"sint32=NULL
"desc"blob="AirPort network password"
"gena"blob=NULL
"icmt"blob=NULL
"invi"sint32=NULL
"mdat"timedate=0x52192841772471472498124818A00 "20150723143649Z\000"
"nega"sint32=NULL
"prot"blob=NULL
"scrp"sint32=NULL
"svce"blob="AirPort"
"type"uint32=NULL
password: "osxdaily"

In this case, the wi-fi password for ‘Your-Router-Name’ with ‘password: “osxdaily”‘ is at the very bottom of the returned command.

As mentioned already, you can find the same wi-fi login details from KeyChain Access tool in OS X, and you don’t even need to be connected to the wi-fi network you are retrieving the password for, which is extremely helpful for those times you get a phone call from a friend or family member asking “hey what’s the password for the router at so-and-so house” (maybe I’m the only one who gets those calls). Whether you go the command line route as described here, which is ultimately just a terminal approach to the keychain anyway, or through the more user friendly KeyChain Access application, is up to you.

Thanks to LifeHacker for pointing out this great trick, we cleaned it up a bit with grep but for PC users, Lifehacker goes further to demonstrate how to perform the same wi-fi router password finding from a Windows PC too, which could be undoubtedly helpful to many users, based primarily on Macs or otherwise.

Enjoy this tip? Subscribe to the OSXDaily newsletter to get more of our great Apple tips, tricks, and important news delivered to your inbox! Enter your email address below:

540
141

Continue Reading

Previous: Come installare Windows 10 da USB
Next: Outlook – Aggiungere se stessi in BBC in ogni messaggio von VBA

Related Stories

Outlook – Aggiungere se stessi in BBC in ogni messaggio von VBA
2 min read
  • Senza categoria

Outlook – Aggiungere se stessi in BBC in ogni messaggio von VBA

28 Settembre 2016
Come installare Windows 10 da USB
1 min read
  • Senza categoria

Come installare Windows 10 da USB

3 Agosto 2016
Guida Vsftpd
3 min read
  • Linux
  • Senza categoria

Guida Vsftpd

30 Agosto 2009
Copyright © All rights reserved. | DarkNews by AF themes.
Cookies
This website uses cookies to improve your experience. We'll assume you're ok with this, but you can opt-out if you wish. Cookie settingsACCEPT
Privacy & Cookies Policy

Privacy Overview

This website uses cookies to improve your experience while you navigate through the website. Out of these cookies, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may have an effect on your browsing experience.
Necessary
Sempre abilitato
Necessary cookies are absolutely essential for the website to function properly. This category only includes cookies that ensures basic functionalities and security features of the website. These cookies do not store any personal information.
Non-necessary
Any cookies that may not be particularly necessary for the website to function and is used specifically to collect user personal data via analytics, ads, other embedded contents are termed as non-necessary cookies. It is mandatory to procure user consent prior to running these cookies on your website.
ACCETTA E SALVA