LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Restrict computer time for kids (https://www.linuxquestions.org/questions/linux-software-2/restrict-computer-time-for-kids-4175507561/)

Thomas Baeckeroot 09-10-2017 07:54 AM

A solution: bash script that logs-off user once his daily time is over (4 lines to install)
 
Hi all,

I just made an answer available easily. Code is explained on thread http://forums.linuxmint.com/viewtopic.php?f=213&t=77687 . In short: a limit configured in minutes per day, a cron job every minute, a message to user to keep him informed and a forced logoff.

To download and install this, open a Terminal and run the commands below:
Code:

cd /tmp/
git clone https://github.com/Thomas-Baeckeroot/ParentalControl.git
cd ParentalControl/
./install.sh

Administrator password will be requested during the installation process (to install the cron job, to copy the script, …). From there you will be guided for the configuration (number of minutes for each user). There is also an ./uninstall.sh at the same place just in case. It is build to work with all Ubuntu based distro (Mint, etc… probably all debian also). If any issue occurs please let me know, including system version and graphical environment in comments:
Code:

uname -a
echo $XDG_CURRENT_DESKTOP

PS: At the time I started this script (~2012), "kidtimer" solution from grover66 and Jim Dunphy did not exist yet so I haven't checked their solution, it looks to do the same: https://github.com/JimDunphy/kidtimer .


Thomas Baeckeroot

Marcus67 04-20-2019 06:51 AM

New Parental Control Application for Debian Linux
 
I've just released a beta version of my new application LittleBrother that is able to monitor play time on Linux machines. Test users are welcome to try the Debian package. Instructions on how to download and use it can be found here: https://github.com/marcus67/little_brother. The installation may still be a little rough, though. These are the features of the application:
  • Any number of users can be monitored.
  • Each user can have a specific set of rules defining the permitted playtime.
  • Rules can be adapted to "contexts", such as the day of the week and/or a vacation schedule (currently only the German schedules are supported).
  • Play time can be restricted to a time window (from, to).
  • A maximum play time per day can be defined.
  • Users can be forced to take a break after a certain maximum session time.
  • Users can be forced to wait for a miniumum break time after their activity.
  • Any number of Linux client hosts can be monitored (currently this requires users to have the same login on all machines).
  • There is a master host with a history of the activities of all users. This master host checks the rule sets and prompts the client hosts to terminate processes if required.
  • The master host offers a simple web interface for viewing the user activity over a configured history length (e.g. 7 days) and an administration page to dynamically define rule exceptions for a configured number of days into the future.
  • The web application can be run behind a proxy so that it will be accessible from away allowing remote administration after receiving calls from young users begging for more play time.
  • The application has international language support. Currently English and German translations are provided. Users are invited to provide translations for other languages.
  • The application uses voice generation to inform the user over impending forced logouts. Also these spoken messages are internationalized.
  • In addition to the time spent on Linux hosts the application can also monitor activity time on other devices such as smart phones or tables. It takes advantage of the fact that most modern operating systems put devices in some kind of power saving mode while they are not being used. This way, the network response (by pinging) can be used to determine the activity on those devices. In contrast to the Linux hosts, the application will not be able the terminate the activity. The play time, however, will be added to the overall playtime and hence will have an impact on the time allowed and also on the break time rules on the Linux hosts.

ondoho 04-21-2019 04:51 AM

sounds ambitious.
I hope it works well!
is it distro-independent?
can you explain in a few simple words how it works under the hood?
and at what age will kids be able to circumvent it? ;)

Marcus67 04-22-2019 03:32 PM

Description of architecture will follow
 
Quote:

Originally Posted by ondoho (Post 5987153)
sounds ambitious.
I hope it works well!
is it distro-independent?
can you explain in a few simple words how it works under the hood?
and at what age will kids be able to circumvent it? ;)

Currently, the application is available as a Debian package only. However, the effort to make it available to other distributions should be small.

Your commend reminds me of the fact, that I wanted to write a short technical description of the "architecture" if that word is applicable for such a small application. I will do this as one of my next chores. This is the architecture in a nutshell: https://github.com/marcus67/little_b...RCHITECTURE.md.

The children would require a sufficient knowledge of Linux processes and most likely root access or the admin password must have been compromised.

bgstack15 04-23-2019 06:56 AM

This sounds fascinating. Thank you for sharing this! Do you expect that a person could modify this to have a popup, instead of an audible message?

Marcus67 04-23-2019 04:58 PM

Popup is already on the issue list
 
Quote:

Originally Posted by bgstack15 (Post 5987724)
This sounds fascinating. Thank you for sharing this! Do you expect that a person could modify this to have a popup, instead of an audible message?

Actually, I just transferred some issues to GitHub and voila: https://github.com/marcus67/little_brother/issues/6 :-)

ondoho 04-26-2019 11:30 AM

Quote:

Originally Posted by Marcus67 (Post 5987545)
I wanted to write a short technical description of the "architecture" if that word is applicable for such a small application. I will do this as one of my next chores. This is the architecture in a nutshell: https://github.com/marcus67/little_b...RCHITECTURE.md.

ok, thanks!
i think this:
Quote:

applies configured rules
would need to be expanded: what rules, and how are they "applied".

I hope you get more contributors!


All times are GMT -5. The time now is 12:58 PM.