+5 votes
56 views
How to View Saved WiFi Passwords on Linux

in Security by (551k points)
reopened | 56 views

1 Answer

+3 votes
Best answer

1 See WiFi passwords saved in Linux from configuration file
2 View Saved WiFi Passwords in Linux from Nmcli
3 View Saved WiFi Passwords in Linux from Settings

In our Linux operating systems we can establish a Wi-Fi connection either because the equipment has the adapter integrated or using external adapters, this allows us to access wireless networks in a certain range and when we connect by default the password of the network will be stored locally on the system and therefore we will have the possibility to access there to see what the password is. It is normal for us to save our WiFi or other login passwords as this will speed up other attempts and prevent us from wasting time trying to remember it. What we do have to keep in mind is that we will have to protect our equipment well to prevent other people from accessing this sensitive content..

 

When we connect to various WiFi networks, we will surely opt for the option of remembering our password, but if this is not the case or we do not have it written down, we will surely need to know the Linux WiFi password at some point. That is why this tutorial will help us copy it in case we have forgotten it or to validate its integrity, TechnoWikis will teach you 3 ways to see the Wi-Fi password saved in Linux and in this case we will use Ubuntu 23.04 but the process is similar for all.

 

 

 

To stay up to date, remember to subscribe to our YouTube channel!
SUBSCRIBE ON YOUTUBE

 


1 See WiFi passwords saved in Linux from configuration file

 

Step 1

All passwords in Linux will be stored in the connection configuration file, for use, we open the terminal and go to the connection file:
 cd /etc/NetworkManager/system-connections 
image

 

Step 2

We list the content with the command:
 ls -l 
Step 3

There we find the type of permission assigned and the name of the Wi-Fi network with the syntax name.nmconnection.

 

 

 

 

 

image

 

Step 4

We use some editor to access the content of this file:
 sudo cat name.nmconnection 
step 5

We will see the following:

 

image

 

step 6

In the "wifi-security" section in the "psk" line you find the password of the Wi-Fi network:

 

image

 

step 7

Alternatively it is possible to use GREP to access this information:
 sudo grep -r '^psk=' /etc/NetworkManager/system-connections/ 
step 8

You will see the Wi-Fi password:

 

image

 

step 9

To see this information in a more summarized way we will execute the following:
 sudo grep -hr '^psk=' /etc/NetworkManager/system-connections/ 
image

 

 


2 View Saved WiFi Passwords in Linux from Nmcli

 

Nmcli is a command line tool with which it is possible to control NetworkManager and have access to network status reports, with Nmcli it is possible to create, display, edit, delete, activate and deactivate network connections or manage and display the status of network devices..

 

Step 1

For its use we open the terminal and list the connections stored in Linux with the command:
 nmcli -g NAME connection show 
image

 

Step 2

We access the WiFi password using the following syntax:
 nmcli -s -g 802-11-wireless-security.psk connection show "NETWORK NAME" 
image

 


3 View Saved WiFi Passwords in Linux from Settings

 

 

Step 1

Finally it is possible to make use of the configuration of the distribution that we are using, in Ubuntu at the top of the desktop we click on the network icon:

 

image

 

Step 2

We click on the configuration icon to access it and we will go to the "Wireless" section:

 

image

 

Step 3

We click on the WiFi network configuration icon and then we will go to the "Security" tab:

 

image

 

Step 4

Check the "Show password" box to see the Linux Wi-Fi password:

 

image

 

Each of these options will allow us to access the Wi-Fi password in Linux.

 


by (3.5m points)
edited

Related questions

+4 votes
1 answer
+4 votes
1 answer
asked Oct 5, 2019 in Security by backtothefuture (551k points) | 486 views
+5 votes
1 answer
asked Jun 29, 2020 in Mac by backtothefuture (551k points) | 229 views
+5 votes
1 answer
asked Sep 19, 2019 in Security by backtothefuture (551k points) | 250 views
+4 votes
1 answer
asked Apr 29, 2020 in Internet by backtothefuture (551k points) | 225 views
Sponsored articles cost $40 per post. You can contact us via Feedback
10,633 questions
10,765 answers
510 comments
3 users