diff --git a/Python/WifiConnectionFinder/Readme.MD b/Python/WifiConnectionFinder/Readme.MD new file mode 100644 index 00000000..7d04005a --- /dev/null +++ b/Python/WifiConnectionFinder/Readme.MD @@ -0,0 +1,25 @@ +# Wifi Connection Finder + +## Introduction +``` +Wifi Connection finder is a python script that list all wifi connected to your device.It uses the concept of subprocess +The subprocess module present in Python(both 2.x and 3.x) is used to run new applications or programs through Python code by creating new processes. It also helps to obtain the input/output/error pipes as well as the exit codes of various commands +``` +### In order to get the information about the wifi devices system is connected to we will use the command given below +``` +subprocess.check_output(['netsh', 'wlan', 'show', 'profiles']) +``` + +## How to use the code +``` +1. Download the given code +2. Run the wififinder.py file +3. All the devices connected to wifi will be listed as ordered list +``` +## Output + +![endpoint](https://github.com/Tejas1510/hacking-tools-scripts/blob/wifi/Python/WifiConnectionFinder/images/image1.png) + +![built with love](https://forthebadge.com/images/badges/built-with-love.svg) + +Check out my Github profile [Tejas1510!](https://github.com/Tejas1510) diff --git a/Python/WifiConnectionFinder/images/image1.png b/Python/WifiConnectionFinder/images/image1.png new file mode 100644 index 00000000..7c8f5111 Binary files /dev/null and b/Python/WifiConnectionFinder/images/image1.png differ diff --git a/Python/WifiConnectionFinder/wififinder.py b/Python/WifiConnectionFinder/wififinder.py new file mode 100644 index 00000000..6d50f3a7 --- /dev/null +++ b/Python/WifiConnectionFinder/wififinder.py @@ -0,0 +1,16 @@ +import subprocess ## to know more about subprocess please refer readme file where i have explained the details about it +wififinalData = subprocess.check_output(['netsh', 'wlan', 'show', 'profiles']) +finalData = wififinalData.decode('utf-8', errors ="backslashreplace") +finalData = finalData.split('\n') +allWifiName = [] +for i in finalData: + if "All User Profile" in i : + i = i.split(":") + i = i[1] + i = i[1:-1] + allWifiName.append(i) +print("Your System is Connected to following wifi networks : ") +i=1 +for name in allWifiName: + print(i,")",name) + i=i+1