Parental Control Application implemented in Python 3 packaged for Debian and Ubuntu to monitor and limit kids' play time on Linux hosts
![]()
Parental Control Application LittleBrother
Overview
LittleBrother is a simple parental control application monitoring specific processes (read "games") on Linux hosts to monitor and limit the play time of (young) children. It is designed as a client server application running on several hosts and combining playing time spent across these hosts, but it also works on a standalone host.
When the application determines that a user has exceeded her play time, it will terminate the running process. Usually, the user will get several spoken notifications (using the LittleBrotherTaskbar) before she is actually kicked out so that she can log out gracefully in time.
What's New?
The latest major feature changes are:
| Version | Feature/Fix | (Issue) Link | |---------|--------------------------------------------------------------------------------|----------------------------------------------------------------------| | 0.5.6 | New: Provide an Alpine server image | Issue 209 | | 0.5.4 | Bug Fix: Proper deletion of table histories | Issue 203 | | 0.5.2 | Bug Fix: Installation problems due to unsupported playsound | Issue 205 | | 0.5.1 | New feature: Provide the first rudimentary version of the Angular web frontend | Issue 191 | | 0.4.33 | Support partial persistence of basic user settings on clients | Issue 190 | | 0.4.28 | Bug Fix: Remove incompatibility with Python 3.8 | Issue 180 | | 0.4.23 | Optionally use iptables to restrict network access | Issue 169 | | 0.4.20 | Bug Fix: Use Python virtual environment again | Issue 170 | | 0.4.17 | Bug Fix: Remove incompatibility with new alembic version | Issue 166 | | 0.4.16 | Bug Fix: Ignore invalid hosts during ping | Issue 165 | | 0.4.15 | Bug Fix: Do not fail on Debian package upgrades | Issue 158 | | 0.4.14 | Bug Fix: Correct detection of users in master-only setups | Issue 163 | | 0.4.12 | New: Client process available as snap | Snapcraft Support | | 0.4.9 | New: Automatic check for new versions of LittleBrother | Issue 150 | | | Improvement: Separate LDAP search DN for groups and users | Issue 144 | | | Improvement: Cache timeout for LDAP data | Issue 138 | | 0.4.8 | New: Full support for requesting optional time by users | Issue 130 | | 0.4.4 | New: Use user specific patterns to prohibit applications | Issue 129 |
Contact
Visit the project at Facebook or write comments to little-brother(at)web.de.
Screenshots
The following screenshots show the web frontend of LittleBrother. Click on the thumbnails to enlarge.
Change History
See here
GitHub Status
SourceForge Download Status
Continuous Integration Status Overview
| Status | Master | Release | |:--------------------|:-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------| | CircleCI | |
| | Test Coverage |
|
| | Codacy Code Quality |
|
| | Code Climate |
| not available | | Snyk Vulnerability |
|
| | Snyk Package Health | not available |
|
Note: The vulnerability status is derived from the Python PIP packages found in requirements.txt.
Features
LittleBrother has the following features:
- 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
- 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 minimum break time after their activity.
- Any number of Linux client hosts can be monitored.
- There is a master host with a history of the activities of all users. This master host checks the rule sets and
- The master host offers a simple web interface for viewing the user activity over a configured history length
- The web application can be run behind a proxy so that it will be accessible from away allowing remote
- There is a helper application (LittleBrotherTaskbar) to
- The application has international language support. Currently English, Italian and German translations are provided.
- Downtime of a server during playtime (e.g. due to hibernation) is automatically subtracted from the play time.
- In addition to the time spent on Linux hosts the application can also monitor activity time on other devices
pinging) can
be used to determine the activity on those devices. In contrast to the Linux hosts, the application
will not be able to 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.
- As of version 0.3.12
LittleBrotheris able to use ProxyPing to ping
- As of version 0.3.13
LittleBrotherclients will terminate local user sessions if they cannot reach the master
- As of version 0.4.0
LittleBrotherprovides an administration feature to easily extend the current computer time
- The application uses voice generation to inform the user over impending logouts. Also, these spoken
LittleBrother application has been replaced by the LittleBrotherTaskbar.
Architecture
The page gives a detailed description of the architecture of the application.
Tested Distributions
So far, LittleBrother has only been released as a Debian package. For other non-Debian based distributions there is some basic support using a generic installation script. See this page for details.
| Distribution | Version | Architecture | Comments | Most Recent Test | |--------------|---------------|--------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------| | Ubuntu | 24.04 | amd64 | This version is used as base image for the Ubuntu Docker image | 22.DEC.2024 | | Debian | 11 (bullseye) | amd64 | Feedback from a user as regular install using Mate desktop | 06.MAR.2022 | | Ubuntu | 18.10 | amd64 | See pip3 issue | 03.JUN.2019 | | Debian | buster | amd64 | The version buster-slim is used as base image for the Debian Docker image | 01.JAN.2020 | | Debian | 10.3 (buster) | amd64 | Feedback from a user as regular install with Mate desktop | 05.MAR.2020 | | Mint | 19 | amd64 | | 03.JAN.2020 | | Arch Linux | | amd64 | See https://aur.archlinux.org/packages/little-brother | 06.MAR.2022 | | Debian | stretch | armv6l | | 23.MAY.2020 | | Alpine | v3.13 | amd64 | This distribution is used as base image for the Alpine Docker Image | 06.MAR.2022 |
Quick Install (Snap)
There is a snap available for the client process. See snap-little-brother for details.
Quick Install (Debian Package)
This guide will take you through the steps required to install, configure, and run the LittleBrother application on your system. This guide works both for master and client setups.
See the repository little-brother-server-docker-setup for setting up LittleBrother using Docker (and Docker Compose).
YouTube Videos
| Thumbnail and Link to Video | Duration | Content | Related Versions | |------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------|---------------------------------------------------------------------------------------------|-------------------------------------------| |
| 16 min | Install LittleBrother Debian package, edit configuration file, add user, test functionality | LittleBrother 0.3.1 on Ubuntu 19.3 | |
| 14 min | Install LittleBrotherTaskbar pip3 package, register desktop service, test functionality | LittleBrotherTaskbar 0.1.9 on Ubuntu 19.3 |
Download the Software
The application is available as a Debian package from the release directory at SourceForge. The latest build is available from the master directory. Install it as you would install any other Debian package with
dpkg -i PACKAGE.deb apt-get install -f
Note that the second command is required to install missing dependencies since dpkg does not run a dependency check. Instead, it will return with an error which will then be "fixed" by apt-get.
After installation use
systemctl start little-brother
to start the application right away. The application will successfully start up provided that the default port 5555 is available on the host. You can check the success by trying to log into the web frontend.
Configuring the Application (Mostly Optional)
The default setup will fit most first-time users (except for the password). The following table contains various additional aspects that may require additional configuration.
| Aspect | Default Setting | Alternatives | Reference | |-----------------------------|----------------------------------------------------------------------------|-----------------------------------------------------------------|----------------------------------------------------------| | Admin Password | User admin with password test123 | Use LDAP for authentication and authorization | See "Setting Admin Password" below | | Database backend | File oriented database sqlite | Full fledged database such as MySQL dor MariaDB | See Advanced Configuration | | Web frontend port | 5555 | Any other available port | See Advanced Configuration | | Web frontend base URL | / | Any other path | See Advanced Configuration | | User registry | /etc/passwd | Predefined users and UIDs or LDAP registry | See Advanced Configuration | | Master client setup | Use only a master host | Use any number of client hosts | See Advanced Configuration | | Mapping UIDs | UIDs are synchronized across all hosts | Each host (group) can have different UIDs | See Advanced Configuration | | Scanning Interval | Every 5 seconds | Any other interval | See Advanced Configuration | | Reverse proxy setup | No reverse proxy | Run little-brother behind a reverse proxy (e.g. nginx) | See Advanced Configuration | | Docker Support | Client and/or server is installed as a Debian package | Client and/or server is run as a Docker container | See little-brother-server-docker-setup | | Prometheus Support | Not activated | Activate Prometheus server port and provide run time statistics | See Operational Monitoring. | | Network Tempering Detection | Automatic logout of monitored users after a network downtime of 50 seconds | Set a different time out | See Advanced Configuration | | Firewall support | Do not restrict network access of client hosts | Configure targets IP addresses to be blocked | See Advanced Configuration | | Frontends | Only activate the classic frontend | Configure the new Angular frontend | See Advanced Configuration |
Setting the Admin Password
For the time being setting the admin password is the only standard configuration that still requires using an editor. See this issue. You have to be root to follow these steps (e.g. use sudo):
- Use your favorite editor to edit the file
/etc/little-brother/little-brother.conf.
- Find the setting
admin_passwordin the section[UnixUserHandler].
- Change the password.
- Save the file.
- Restart the application by issuing:
From now on the new password will have to be used to access the administration pages.
Using the Web-Frontend
You are all set now. It's time to set up users to be monitored and optionally devices. See the Web Frontend Manual.
To get a glimpse of the new Angular frontend see here.
Troubleshooting
So, you went through all the above but LittleBrother does not seem to work? Maybe this troubleshooting page can help you.
Caveats
The application LittleBrother is far from perfect. Some major caveats are listed here and/or in the issue list on GitHub (see here).
- Every once in a while processes fail to terminate even though they have been killed by
LittleBrother.
- The web server only responds to HTTP requests. This is probably always OK for communication between the
Internationalization
The application uses the PIP package Flask-Babel to provide internationalization for the web frontend. Currently, the following languages are supported or in preparation (in the order they were made available):
| Flag | Language | Locale | Status | Translation provided by | |------------------------------------------------------------|------------|--------|----------------|---------------------------| |
| English | en | Up-to-date | Marcus Rickert | |
| German | de | Up-to-date | Marcus Rickert | |
| Italian | it | Revision 116 | Albano Battistella | |
| Dutch | nl | Revision 63 | Simone & Lex | |
| Finnish | fi | Revision 63 | Isakkii Kosonen | |
| French | fr | Revision 86 | Albano Battistella | |
| Turkish | tr | Revision 63 | Selay Dogan | |
| Russian | ru | Revision 63 | J. Moldawski | |
| Japanese | ja | Revision 63 | Arik M. | |
| Bangla | bn | Revision 63 | Rownak Jyoti Zaman | |
| Thai | th | Revision 63 | Busaba Kramer | |
| Danish | da | Revision 63 | Erik Husmark | |
| Spanish | es | Revision 63 | Ruth Wucherpfennig-KrΓΆmer | |
| Croatian | hr | Revision 63 | Incognito | |
| Lithuanian | lt | In preparation | N.N. |
A revision number in the status column denotes that all texts up to that revision have been localized. Your help with translations is greatly appreciated. Please, contact the author if you are interested in providing a translation. You do not necessarily have to clone this repository or be familiar with Python to do so.
Credits
- Thanks to all the people maintaining the wonderful script language Python
- The country flags were taken from www.countryflags.com.
- See the section about on internationalization for credits regarding the translations.
- The site www.mehr-schulferien.de maintains the vacation metadata for
- The icons are provided by fontawesome.com.
- People contributing by providing pull requests:
