Until now XCA templates could not be viewed during import.
But this is necessary to skip the multi-import dialog.
The NewX509 dialog is used with almost everything disabled.
Importing the displayed public key of a certificate during
certificate import resulted in a double free.
The "import" flag of the key-details can now forcefully
disable the import button.
Fixing it was way more complex than simply disabling it.
Also add sanity checks for pointers that are not our childs
when creating the QModelIndex
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.
When displaying external items before import,
XCA tries to find their issuer and matching key in the database.
Now it only does it if the database is open.
The ImportMulti dialog does not show up if there is only
one item to display, but the item is displayed directly.
The displayed items have a new "Import" button to import
directly from the viewed item.
If XCA is called with certs, crls, keys etc. from the commandline
XCA only displays and optionally imports the item if a default
database is given. Afterwards XCA exits.
Fix logical error when exporting in PEM format.
The key export part was not reached...
The diff is much smaller when displayed with -b to skip
indentation-only changes....
Drop the unused "F_PLUSKEY" flag and fix the Template export
APPSTORE_COMPLIANT = ON:
- Turns off the File menu and moves the language selector to
the "Extra" Menu. "Options" and "Exit" are at the xca-macos
special-menu anyway.
- Switches the signing key from "Developer ID Application" to
"3rd Party Mac Developer Application"
- Sets the database name to "default.xdb"
- Adds "-appstore-compliant" option to macdeployqt
- Picks the "entitlement-appstore-compliant.plist"
- Disables the "Token" menu and "PKCS#11 provider" tab
in the option dialog
Simple message boxes are still native messageboxes.
Complex message boxes have buttons with adapted texts.
Apparently the "Q_OBJECT" declaration in "xcaWarningBox"
made it. Don't know why.
Unify import functions for some (on_butImport_clicked)
or all (on_butOk_clicked) items.
They both call "importIndexes(const QModelIndexList &indexes)"
containing some or all indexes to import.
db_x509.cpp: Only need to search the treeItem (containing all items
without issuer, not all in the rootItem (containing also certificates
with known issuer)
Re-use "remFromCont()" when stealing items from an other CA.
There were 2 slots to trigger the switchHashAlgo()
whenever the selected key or request changes.
But their signature for automatic connect()ion was wrong.
After fixing the methods signature, they are connected
and get called whenever the keylist changes and especially,
when a new key is inserted.
The proposed "addAction()" with the KeySequence as 2nd argument
is only available soince Qt6.3 and not compatible with QT5
Change the call in a compatible way and set the shortcut afterwards.
xca.ico is only used as resource of the EXE file. To make
that work, the linker option -MD is necessary.
Use the 128x128 px PNG in favor to the 128x60 px PNG
as icon to avoid rescaling.
Don't use the xca.ico, which would require "imageformats/qico.dll"
This also reverts the rubbish commit 583b9f82b2.
No libraries needed. Just put all files as source to xca
and those needed for xcadoc to the xcadoc target.
Github Action: create deployments for each matrix result
XCA now supports both, Qt6 and Qt5 down to Qt-5.2
Use CMAKE_PREFIX_PATH to point to the QT dompiler directory like
$ cmake -B build -DCMAKE_PREFIX_PATH=$HOME/6.3.1/gcc_64
Before that "" was concatenated with second element so each
call by index to that array would be off by 1.
Signed-off-by: Melg Eight <public.melg8@gmail.com>
For interoprability reason.
To enforce it, set "#define OPENSSL_NO_STDIO 1"
All file access is done by reading/writing from/to BioByteArray()
which is filled by QFile:readAll()
Drop CRYPTO_malloc_debug / CRYPTO_mem_leaks
which is unused and disabled since many years.
- Always build html documentation if sphinx-build is available.
to be installable during install
- Collect "${D}/qthelp/xca.qhc" "${D}/qthelp/xca.qch" in QTHELP_IDX
and use this instead.
- On linux also install the qthelp in an html subdirectory like WIN32
- Don't instanciate QHelpEngine if no help available.
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.
This also seperates UI from the core.
After calling QLocale::setDefault(), the empty QLocale constructor
returns the current default locale.
This is now used instead of XcaApplication::language()
Correctly create NewKey list items for smart-cards mechanisms.
use the PKCS#11 ID t.mech as parameter for CK_MECHANISM_TYPE
instead of t.type, which is an OpenSSL ID.
Both are numeric, so the compiler didnot complain.
For RSA it worked accidentally, because
type:EVP_PKEY_RSA == mech:CKM_RSA_PKCS_KEY_PAIR_GEN == 0
Bug introduced after 2.3.0 with
77519936e0
Set the mechanism of ED25519 to CKM_VENDOR_DEFINED, because ED25519
is not supported by PKCS#11 and 0 means CKM_RSA_PKCS_KEY_PAIR_GEN.
Why?
- QT will switch from qmake to cmake sooner or later.
- autotools are good for unix-ish systems, cmake also for
macOS and Xcode as well as Windows and VS-code
- Cross compiling the windows-binaries on linux
is not very helpful to attract windows-centric
developers.
Also drop qmake's xca.pro
Generate man-page and sphinx sources of commandline arguments
during build by executing xca (xcadoc.cpp).
Generating Version-patchlevel and git hash is now also
OS independent.
The generic XcaProgress object is used, which dynamically
creates a Cmdline progress object.
The Mainwindow replaces it by a GUI object, which integrates
into the status bar.
the "lastRemote" database is not GUI specific and
has been moved from "OpenDb" to the non-gui class dbhistory,
which in turn becomes independent of OpenDb
After dropping Qt4 support, the Qt5 QStandardPaths class
can be used to replace my implementation of directory discovery.
QStandardPaths follows the XDG specification.
Reduce UI from QDialog to QWidget and display it in the XcaDialog frame.
Also move user interface specific code from the db_x509 class
into the CertTreeView class