Generalize the Clipboard format selection
and extend it to certificates.
Certificates may now be exported as chain
or together with private key.
The clipboard format selection also
affects the Drag&Drop content.
The Export->Clipboard men now also shows the
currently selected format export.
When XCA started in 2002, there were no C++ initializers.
Drop explicit initializers from the constructors.
- Fix indentations of section declarators.
- Replace NULL by nullptr when feasible.
- Sort private section: properties first, then methods.
Collect all export formats in pki_export.
Each export format has assigned acouple of flags, indicating,
whether they are text, concatenateable, encrypted, usable for
multiple selections or only for a single item.
Always only use forward slash /
Drop all "QDir::separator()" and "nativeSeparator()"
functions. Only use it where filenames are displayed for the user.
New classes:
- database_model: Manage the database tables (keys, req, cert, crl, templ)
extracted from widgets/MW_database.cpp
- arguments: parse commandline, dynamically create help text
- allow setting a database as default
- Strip xca-app-folder from database and export filenames.
This allows renaming/moving the portable app and open the default DB
and use the working directory inside the folder
- Remember database history and configured language
With this commit PKCS#11 libraries may be reordered
and enabled or disabled.
The slot selection dialog iterates over all enabled and successfully
loaded libraries in the configured order and collects the slots
of each of them.
In the options dialog the library info is shown in the tool-tip
Print digest of public keys in the key details in different formats:
Print SHA256 SSH digest as used to by SSH users:
ssh-keygen -l -f ~/.ssh/id_rsa.pub
Print SHA1 X509 key digest as shown in the
Subject key identifier of a certificate
Print SHA256 digest as in:
openssl pkey -pubout -outform DER < key.pem | sha256sum
as requested by this issue.
Refactored digesting functionality by a generic Digest()
function working with QByteArrays.
The function formatHash() now also expects a QByteArray input.
A "hostId" determines the current host and is appended to
the "workingdir", "pkcs11path" and "mw_geometry" settings
in the database. This allows opening the database
on different hosts without wrong workingdir or not
loadable PKCS#11 libraries
On Windows XCA goes in portable mode if no XCA registry entry is found.
On Mac and Unix it checks the XCA_PORTABLE environment to be non-empty.
In portable mode:
- The current working directory is not written to the database
- The configured language and history of opened databases is
forgotten after a restart of XCA
- No registry entry is required nor written.
- No unexpected files are written to disk, except exported items.
- Portable mode is displayed in the "About" dialog
If setup.exe or "make install" are not used,
- XCA is not assigned as app for any file types
Add configuration values in the Options dialog to
control the time when certificates get marked yellow and
the expiration alarm time in calendar entries.
Add settings class to access the settings table in the database
Cache values and improve database writes.
Options dialog simplified
Replace getSetting / storeSetting
Unpack option flags to rows in the settings