Page MenuHome GnuPG

Kleopatra: Don't offer "Trust root certificate" if users are not allowed to do this
Testing, NormalPublic

Description

If gpg-agent's no-allow-mark-trusted option is set then Kleopatra shouldn't allow users to mark root certificates as trusted or not trusted, i.e. the two actions "Trust root certificate" and "Distrust root certificate" shouldn't be offered.

If the no-allow-mark-trusted option is read-only (i.e. it's enforced by the administrators) then we should hide the actions. Otherwise we should just disable them.

Event Timeline

If we fix this bug for 2.2 we need to have a configure way to revert to the old behaviour. That needs to be a kleopatra config. Or we just don't fix this bug for current vsd but only for gpg4win and the next generation vsd.

This bug exists since Kleopatra offers "Trust root certificate" (i.e. since 2010). allow-mark-trusted seems to be default since Gpg4win 2.1.0. If admins really want to prevent users from messing with the trustlist then they anyway have to use the no-user-trustlist option.

And if admins are able to set these gpg-agent options in the global config file/registry then they will also be able to disable the "Trust root certificate" action via the standard mechanism.

What I'm trying to say is: Yes, the bug should be fixed for upcoming versions, but it doesn't make much sense to fix it in patch releases of old versions because there's an easy workaround.

ebo triaged this task as Normal priority.Fri, Oct 25, 4:26 PM
ebo added a project: gpd5x (gpd-5.0.0).
ebo edited projects, added gpd5x; removed gpd5x (gpd-5.0.0).
ikloecker moved this task from Backlog to WIP on the gpd5x board.
ikloecker changed the task status from Open to Testing.Tue, Oct 29, 4:32 PM

Fixed.

If gpg-agent's option "no-allow-mark-trusted" is set then the actions "Trust root certificate" and "Distrust root certificate" won't be available. If the option is set while Kleopatra is running then it needs to be restarted to get rid of the actions. If one tries to use the actions then Kleopatra will tell you that you are not allowed to do this. Similarly one needs to restart Kleopatra to make the action available again after the option was unset.

The option can be enabled/disabled via the GnuPG System configuration in Kleopatra (Private Keys -> Disallow clients to mark keys as "trusted"), i.e. you don't have to edit gpg-agent.conf by hand.