The CA chain for the document signing was already a user setting & it
was exposed in the WOPI CheckFileInfo, but the actual signing
certificate & key was missing, so signing was not possible.
These are typically in a similar PEM format using just ASCII characters,
so providing a textarea where the user can paste them sounds like a good
fit.
Add the read/write of this setting and also expose it as part of the
private user info in WOPI CheckFileInfo.
With this, once all 3 are configured, it's possible to sign a document
in Nextcloud Office, using the Signature button on the Home tab of the
notebookbar.
Signed-off-by: Miklos Vajna <vmiklos@collabora.com>
Document signing needs to store keys as richdocuments settings. This
involves the signing key, certificate and the matching CA chain.
As a first step, add code to the personal settings to be able to set a
CA chain that issues the signing key / certificate.
Setting and getting the setting is possible after this; the setting is
not yet exposed in the WOPI CheckFileInfo response.
<https://github.com/CollaboraOnline/online/issues/9992#issuecomment-2396115427>
has instructions on how to generate self-signed certificates for
document signing for development purposes. Related to #4123
Signed-off-by: Miklos Vajna <vmiklos@collabora.com>