This bot will help you in automatically logging in you account of the desired website or webpage when run. It basically saves time and energy of typing the username and password again and again. On ubuntu system, it runs automatically everytime wireless network is up and even when PC comes back from sleep. P.S. I used it to login into my college's wifi network.
- Enter the website and your username and password in the required to login into the website.
- Now go to the website/webpage and open the developer tools/Inspect element option.
- There search the html code corresponding to the html input fields of username, password and submit button as well.
- Copy the name(or class or id) of that element and paste it in the python code.
- On ubuntu linux copy
script.py
andcaptiveportalconnect.sh
at/etc/network/if-up.d/
and20_captive-portal-auths.sh
at/etc/pm/sleep.d/
- Rename
script.py
andcaptiveportalconnect.sh
tocpauth-yourssid
andcp-yourssid
sudo mv /etc/network/if-up.d/script.py /etc/network/if-up.d/cpauth-yourssid
sudo mv /etc/network/if-up.d/captiveportalconnect.sh /etc/network/if-up.d/cp-yourssid
- Change file permissions
sudo chmod 400 /etc/network/if-up.d/cpauth-yourssid
(the file should be read only by root) - Run the file.
(Optional)
As I wanted the automation to be a click easy, I created a Automator (only for macOS users) that just runs the python file when clicked.