Note that this permissions check only concerns parental controls. If the
system flatpak polkit policy disallows installation to the system repo
(or requires an administrator password for it), this setting cannot
override that.
The default was previously to disallow installation, because the flatpak
polkit policy was previously overridden by these settings. How parental
controls are checked in flatpak has evolved since then, though.
See: https://github.com/flatpak/flatpak/issues/3995
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
Clarify that a standard user account has to be created, and then
parental controls enabled for it — and that clicking the button will
open the control centre.
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
Fixes: #25
Helps: #26
Try and nudge parents/carers towards the best practice for how to set
parental controls on a user, by linking them to appropriate external
content from people who know what they’re talking about.
This external content can vary in the translations so that parents are
pointed to appropriate localised guidelines. In the UK, for example,
this may be
https://www.nspcc.org.uk/keeping-children-safe/online-safety/.
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
This simplifies the UI, as nobody really understood the difference
between ‘Restrict Application Installation’ and ‘Restrict Application
Installation for Others’. Now there’s just a ‘Restrict Application
Installation’ checkbox, which controls application installation in the
home and system flatpak repos.
The underlying app-filter representation in libmalcontent still supports
restricting installation to them separately, but the UI will always set
them to the same value.
There is a suggestion that we may want to support user repos again in
future iff the user has added a remote to their user repo. However,
figuring that out for other users (which is what the admin would have to
do when setting this all up) starts to get tricky with permissions for
reading other users’ home directories. Skip that for the moment — we can
reconsider adding that option in future if someone argues a case for it.
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
Fixes: #30
This documents some development principles which should be borne in mind
when working on new malcontent features.
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
This prevents a polkit authentication prompt popping up unexpectedly if,
for example, a non-privileged user has opened and immediately closed
malcontent-control.
Spotted by Andre Moreira Magalhaes.
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
While the label for the OARS pseudo-combobox was updated when loading a
user’s app filter, the internal state (`self->selected_age`) was not.
Similarly, the set of restricted apps wasn’t loaded until the restricted
apps dialog was opened.
This caused problems when loading a user’s parental controls and then
editing a control which *wasn’t* restricted apps or the OARS level. The
resulting app filter would be built using default values for those two
controls, overwriting and losing their previous values when it was
saved.
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
Since the changes to avoid reloading the app list entirely when loading
an app filter (commit 9d4639cf49), the switch states haven’t been set
properly when loading a new app filter, since the app rows already
exist, and the switch states were only set on creation.
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
This is a backport of commit f742cc3cf2428 from appstream-glib:
as-content-rating: Align the OARS/CSM mappings of sex-*
Align the OARS/CSM mappings of sex-homosexuality and sex-themes, as the
two are identical apart from discriminating on sexual orientation.
This is a follow-up to commit 01e9ee8113a8ad.
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
This is to be referred to by developers when working on the project, and
documents the decisions behind the terminology used.
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
Fixes: #13
We’re standardising on ‘parental controls’ as terminology, and moving
away from explicitly referring to ‘children’.
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
Helps: #13
Rather than waiting until an app filter is set on the application
selector, load the app list immediately at construction time. This is
now possible because it can be diffed easily when the app filter is set.
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
Fixes: #28
Instead of removing all the entries in the list store when the set of
installed apps is updated, diff the old and new lists so that removed
apps can be selectively removed from the list store, and added apps can
be selectively added.
This means that we can (in subsequent commits) reload the app list less
conservatively, as doing so will no longer remove in-progress user
modifications to the set of blocked apps. Modifications are still only
saved when the restrict applications dialogue is closed.
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
Helps: #18, #28
This is handled on the primary instance, and causes the tab to be
switched to show the given username (if possible).
Signed-off-by: Philip Withnall <pwithnall@endlessos.org>
Fixes: #19