Skip to content

Instantly share code, notes, and snippets.

@MrSuicideParrot
Last active March 29, 2024 14:28
Show Gist options
  • Save MrSuicideParrot/18d59a2949b65cf1cb9234db8a6642c6 to your computer and use it in GitHub Desktop.
Save MrSuicideParrot/18d59a2949b65cf1cb9234db8a6642c6 to your computer and use it in GitHub Desktop.
Restart network on kali linux, after use wirless in monitor mode
#!/bin/bash
sudo service networking restart
sudo service NetworkManager restart
@beelzebro
Copy link

beelzebro commented May 16, 2021

Correction;
#!/bin/bash
sudo service networking restart
sudo service NetworkManager restart

And this is supposedly going to restart a router? I doubt this very much my good man.

@MrSuicideParrot
Copy link
Author

Thanks! The script is old and probably the network-manager was renamed. I will update the snippet.

I don't know if I understood your question correctly. But the ideia of this script is to restart the services that are responsible for handling the network interfaces, when you are done with a interface in monitor mode.

@beelzebro
Copy link

Gotcha. From the name, an i guess thevstate of my mind at the time, i thought that maybe this was an exploit. To remote restart the hardware....lol

@fanbyprinciple
Copy link

lol

@khaled201922
Copy link

ver good

@belachkar
Copy link

Update:
The only services to stop and restat actually are NetworkManage, wpa_supplicant:

sudo airmon-ng check     

    PID Name
    470 NetworkManager
  23542 wpa_supplicant

@PushkraJ99
Copy link

To put your Network Card back into Managed Mode
run Following Comands -->

sudo ifconfig wlan0 down
sudo iwconfig wlan0 mode managed
sudo service NetworkManager start

@shariar100
Copy link

thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment