Python 3 Script to Get Internet Wifi Saved Passwords inside your PC or Laptop Using Subprocess Module Full Project For Beginners

Python 3 Script to Get Internet Wifi Saved Passwords inside your PC or Laptop Using Subprocess Module Full Project For Beginners

 

 

Welcome folks today in this post we will be getting wifi saved passwords inside your pc or laptop using python. All the full source code of the application is shown below.

 

 

Get Started

 

 

In order to get started you need to create an app.py file and copy paste the following code

See also  Python 3 Script to Add Colorful Border Frames to Image Files Using Pillow Library Full Tutorial For Beginners

 

app.py

 

 

import subprocess

data = (
    subprocess.check_output(["netsh", "wlan", "show", "profiles"])
    .decode("utf-8")
    .split("\n")
)
profiles = [i.split(":")[1][1:-1] for i in data if "All User Profile" in i]
for i in profiles:
    results = (
        subprocess
        .check_output(["netsh", "wlan", "show", "profile", i, "key=clear"])
        .decode("utf-8")
        .split("\n")
    )
    results = [b.split(":")[1][1:-1] for b in results if "Key Content" in b]
    try:
        print("{:<30}|  {:<}".format(i, results[0]))
    except IndexError:
        print("{:<30}|  {:<}".format(i, ""))

 

See also  Python 3 WxPython Add Menu Items Dynamically to Menubar Using Textctrl Widget GUI Desktop App Full Project For Beginners

 

And now you can run this python script using the below command

 

python app.py

 

So now it will list all your wifi saved passwords inside the console as shown below

See also  Python 3 Script to Remove Special Characters From CSV File Using csv Module Full Project For Beginners

 

 

 

Leave a Reply