0

I am connected via wlan to the internet. I was wondering where my password is saved on the raspberry pi. Once I saw it in plain text somewhere. I thought it was under

/etc/wpa_supplicant/wpa_supplicant.conf

But this file is empty. I tried

/etc/network/interfaces

as well. This file is not empty, but there is no information about my password. Then I tried

grep -r -i "MY_WLAN_NAME" ./

and

grep -r -i "wlan0" ./

without any proper results. Do you have any idea where my password could be located at, or at least how to find it?

Further information: I am using a raspberry pi 3 model b; operating system: raspbian.

Chris311
  • 43
  • 1
  • 8

2 Answers2

1

If you are using Raspbian and the default setup, WiFi details will be in /etc/wpa_supplicant/wpa_supplicant.conf. NOTE You need to use sudo to access the contents (this is a security setting to protect passwords).

/etc/network/interfaces should also exist, and CAN be used to configure WiFi, but is not standard, and not recommended.

There are many different ways of setting networks, but these require specific changes on your part.

How do I set up networking/WiFi/Static IP describes the standard file settings.

Milliways
  • 54,718
  • 26
  • 92
  • 182
  • Isn't this a security leak? The password is stored as plain text in a file. Is this the same with windows? – Chris311 Sep 11 '16 at 12:07
  • @Chris311 if you know the root password on a 'NIX system you can access and change anything. Indeed on any system the administrator can do almost anything, although I can't say what Windows does - I gave up on it years ago. – Milliways Sep 11 '16 at 12:18
  • @Chris311 Yes windows does let you access wifi passwords with the root password just like OS X – Mohammad Ali Sep 11 '16 at 15:14
0

If "connman" is your default network manager on you pi then you will have all the relevant setting regarding your wifi will be in one of the directories in "/var/lib/connman".

The name of the directory in actually the wifi-identifier (i don't know the official name for this id).

And you can figure out the id by running connmanctl services and checking the id against the AccessPoint name.

flide
  • 11
  • 2