Page MenuHome GnuPG

Kleopatra: Custom placeholder text in newcertificatewizard
Closed, ResolvedPublic

Description

Currently we take the username and e-mail on Windows from AD.

There are organizations where this is not the best because the e-mail does not match the actually used e-mail and users tend to click on continue without checking that. In that case it would be good if we could add a custom placeholder text in kleopatrarc and when this is set we would no longer take the value for which the placeholder is set from AD but instead use the placeholder as placeholder so that users are forced to fill that.

So that you can enter e.g. "Vorname Nachname" and "vorname.nachname@foocorp.org" as placeholders.

Event Timeline

aheinecke triaged this task as Normal priority.Nov 15 2021, 2:05 PM
aheinecke created this task.

Can you given a example on how this would look like. In particulr are placeholders some kind of forced template or just a grey background text?

It would be the grey background text and no forced template, just as an input hint. And it would override the automatic detection of name / e-mail so that no wrong values are prefilled. This should help avoid unattentive users from creating a slightly wrong user id if their ad domain address does not match the e-mail.

ikloecker moved this task from Restricted Project Column to Restricted Project Column on the Restricted Project board.

I have decided to use two different sets of settings for the placeholders and for controlling the prefilling of the values. Overloading the semantics of a specified placeholder text would have confused users and developers alike.

The placeholder texts can be specified by setting the config entries CN_placeholder, NAME_placeholder, and EMAIL_placeholder in the [CertificateCreationWizard] group in kleopatrarc.

Prefilling can be disabled by setting the config entries CN_prefill, NAME_prefill, and EMAIL_prefill to false in the [CertificateCreationWizard] group in kleopatrarc.

ikloecker changed the task status from Open to Testing.Nov 23 2021, 8:58 AM
ikloecker moved this task from Restricted Project Column to Restricted Project Column on the Restricted Project board.

Example:

[CertificateCreationWizard]
CN_placeholder=Common Name
CN_prefill=false
EMAIL_placeholder=name@example.com
EMAIL_prefill=false
NAME_placeholder=Firstname Lastname
NAME_prefill=false
ikloecker added a subscriber: ikloecker.

While testing I noticed that another requirement was to hide the advanced button. I have added this myself.

ebo claimed this task.
ebo moved this task from Restricted Project Column to Restricted Project Column on the Restricted Project board.
ebo added a subscriber: ebo.

works