I have been looking to write a script to automate login on an internal company website that is used as a Ping Board to monitor a network of IP connected cameras. I am pretty new to bash scripting and have no idea how to proceed. I have a command in the /home/pi/.config/lxsession/LXDE-pi/autostart file that runs on boot and opens the Chromium browser full screen and directs to the page I require. I wish for the system to automatically log in when at this page without requiring to save the password. I've had a look at the web page code and it is fairly straight forward, standard "Username" and "password" fields on the form. I'm a novice at coding in general but know I am looking for something that essentially identifies the relevant empty fields and populates them according to values I define as "Username" and "password" in the script. Any help would be appreciated and if I am missing any vital info on the issue please let me know.

  • 1
    Hello. I don't think that this problem is really specific to the Pi and I have a hunch that things like this have been discussed on superuser.com before.
    – Ghanima
    Sep 18, 2017 at 12:34
  • Fair point, I am going to soon take this down and put it on the SuperUser site soon
    – JayBuckel
    Sep 18, 2017 at 13:11

1 Answer 1


You might try to launch the startup webpage with the username and password embedded in the URL:

http://username:[email protected]/page.html

This is especially useful for ftp sites (ftp://username/[email protected]/) and often works for http sites, depending of how the site handles it's form submissions

  • I don't now why you were downvoted, this solution worked quite well, the only issue being there is no HTML style sheet and my web page appears "bare bones" if you will, which is problematic as we have a colour coding method for camera's that are offline/online/in need of repairs etc. Any idea how to negate or work around this? Thanks for the reply.
    – JayBuckel
    Sep 18, 2017 at 14:44
  • @JayBuckel: Perhaps, after your page has loaded, and used your credentials, you might reload the page. This would then be a normal page load, and might just fix the problem. It's not guaranteed! (p.s. You might upvote me, perhaps?)
    – Conor
    Sep 18, 2017 at 17:40
  • I tried this too but no luck. I will continue to try and find a solution to the new issue of the invisible style sheet. And I have upvoted you, it's just that my rep is too low for it to count, or so it keeps telling me. I am removing this post soon as I have now posted it on super user, thanks again for the pointers.
    – JayBuckel
    Sep 19, 2017 at 7:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.