Search code examples
pythondjangopandaspywin32pyautogui

Is it possible to get access to PC system via web app using modules like pyautogui and win32gui/pywin32?


As a training project i have made activity tracker using python (no GUI, only command-line).

Script checks with win32gui/pywin32 and pyautogui what program is currently used, and if it is web browser what web site is in use.
Name of window, date, and amount of time spent on program/website is stored in sqlite3 database. Then with help of pandas module same names are grouped and time is summed up.

I want to convert this script into web app using django but i am beginner in creating web apps, so i am wondering: is it possible to use this modules within django and is it even possible to create web app that works same as script mentioned earlier?

Sorry if the question is trivial. I will be grateful for every tip where and what exactly to look for in this topic.


Solution

  • Nope.

    You can't make a server to connect through a web client/browser and see the other processes. That's a security issue, a big one.

    Btw, some GNU/Linux desktop environments won't even allow the same user's processes in the same logged-in session on the same computer to see each other (Wayland).