If you use NetworkManager, you can right click its icon, choose Edit Connections. Then select the desired network, and choose "WiFi Security" and then "Show password".
Connection configuration, including plain text passwords, are stored in /etc/NetworkManager/system-connections/ for connections that are available to all users. They are readable by root only, obviously. Otherwise the password is stored in your keyring (e.g. Gnome Keyring under Gnome).
wicd GUI network manager (I use this with Debian/XFCE) basically same as first paragraph above - click on try icon, wait for wicd to finish scanning, find your current connection, click 'properties' find the 'key' field and click the little 'show' box. There is your password.
sudo cat /etc/netctl/wlp3s0-wlas (though it's the hashed key only, except if you'd used wifi-menu without -o to generate the file)
depends on the type of linux :)
EDIT: if it has to be the current network, something like this horrible bash oneliner: sudo vim /etc/netctl/$(ifconfig | grep UP | grep RUNNING | grep BROADCAST | cut -d: -f1)-$(iwconfig 2>/dev/null | grep ESSID | cut -d: -f2 | sed -e 's/"//g')
if using wpa_supplicant, traditionally there was main config at /etc/wpa_supplicant.conf, where passwords to all networks could be held. file would be readable by root and the binary, obviously
tshadwell|10 years ago
These profiles are located in /etc/netctl, so cat-ing the correct file under sudo will give you it.
This will be a concat-d list of all profiles in a pager: `sudo cat /etc/netctl/* | less`.
samuellb|10 years ago
Connection configuration, including plain text passwords, are stored in /etc/NetworkManager/system-connections/ for connections that are available to all users. They are readable by root only, obviously. Otherwise the password is stored in your keyring (e.g. Gnome Keyring under Gnome).
AvImd|10 years ago
keithpeter|10 years ago
From a terminal as root you can
and find the password in the file.aselzer|10 years ago
depends on the type of linux :)
EDIT: if it has to be the current network, something like this horrible bash oneliner: sudo vim /etc/netctl/$(ifconfig | grep UP | grep RUNNING | grep BROADCAST | cut -d: -f1)-$(iwconfig 2>/dev/null | grep ESSID | cut -d: -f2 | sed -e 's/"//g')
adynatos|10 years ago