Commit Graph

759 Commits

Author SHA1 Message Date
Christian Hohnstädt
82936fa3bd No need to especially mention brainpool curves
They are part of OpenSSL 1.0.2, XCA now requires
at least OpenSSL 1.1.0
2021-05-11 12:07:40 +02:00
Christian Hohnstädt
8daf06dcac Close #259: Follow the XDG base directory specification
After dropping Qt4 support, the Qt5 QStandardPaths class
can be used to replace my implementation of directory discovery.

QStandardPaths follows the XDG specification.
2021-05-11 12:04:46 +02:00
Christian Hohnstaedt
7d564132ba Move ca-properties dialog to the certificate view
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
2021-05-10 20:41:12 +02:00
Christian Hohnstaedt
57802580c8 Drop backward-compatibility for old(<2.0.0) XCA databases 2021-05-10 20:41:12 +02:00
Christian Hohnstädt
1500e636c8 Drop OpenSSL backward compatibility hacks < 1.1.0
OpenSSL < 1.1.1 is out of support anyway
2021-05-09 12:25:32 +02:00
Christian Hohnstädt
d5fa97c3bb Drop support for Qt4
Version 2.4.0 was the last one with Qt4 support
2021-05-09 12:25:32 +02:00
Christian Hohnstaedt
2c38ddbd8d Set default key size to 2048 instead of 0
when changing the key type from EC/ED25519 to RSA/DSA
2021-05-07 22:30:51 +02:00
Christian Hohnstaedt
f24038bbdc Update changelog and copyright year 2021-05-07 21:58:09 +02:00
Christian Hohnstaedt
0f98d17f3a Close import-dialog when it is empty
either after deleting or importing the last item
2021-05-05 21:52:23 +02:00
Christian Hohnstädt
703d9c0ba7 sql: better handle SQL errors during insert
Don't pop-up a success message, but delete the item,
if an SQL error occures during insert.
2021-05-05 19:39:28 +02:00
Christian Hohnstaedt
5b7aa117fa NewX509: select correct help context by tab
Especially removing tabs will shuffle the numbers.
Set the help context as tab-widget objects name.
2021-05-02 23:11:22 +02:00
Christian Hohnstaedt
2eb621e6e4 NewX509: directly call the NewKey and RequestDetail dialog
instead of calling it indirectly through signal-slot
mechanism.
This way we can set ourselves as parent to work
properly with Qt::WindowModal modality.
2021-05-02 22:59:41 +02:00
Christian Hohnstaedt
b805fc20cc ImportMulti: Fix use-after-free issue
Also remove a leftover TRACE and do not abort()
on unexpected events.
2021-05-02 18:53:52 +02:00
Christian Hohnstaedt
4aad4233b5 MainWindow: re-enable dropping a database onto the application
and also clicking on a database to open it in the current
inkarnation on macOS
2021-05-02 18:51:16 +02:00
Christian Hohnstaedt
261f84c409 ImportMulti: change modality to not block the help window
otherwise the details shown from within the details
don't allow to switch to the help window.
2021-05-02 18:47:02 +02:00
Christian Hohnstaedt
40a241a1c2 Help: Raise the help window when clicked on help. 2021-05-02 18:45:40 +02:00
Christian Hohnstaedt
583b9f82b2 Improve windows icon 2021-05-01 09:15:17 +02:00
Christian Hohnstaedt
5d4b52ac87 Fix opening a database on startup.
Commit e32fce8581
(main.cpp: mainwin must exist for read_cmdline() in GUI mode)
created the Mainwindow before parsing the commandline,
but the MainWindow constructor opened a default database if set.

With this change, the MinWindow constructor does not open a default
database. Now the default database is explicitly opened after parsing
the command line, if no other database is already open.

Rename init_database() to setup_open_database()
It is re-entrant.
2021-04-28 22:26:40 +02:00
Christian Hohnstädt
4632a457fa KeyDetail with ReadOnly option
When the public key of a certificate is shown
it is not in the database and the name should not be editable
2021-04-24 23:16:36 +02:00
Christian Hohnstaedt
ff7704ff0b Add context sensitive documentation
All dialogs get the "Qt::WindowModal" modality to
operate the Help window in parallel
while also blocking the dialog parent windows.

The manageRevocations() moved from model to view

The Details dialogs become more self-sufficient.
There is a statc start method that shows the dialog and
updates name and comment after accept().
This allows recursive starts of certificate details and
independence of mainwin.
It is necessary to set the current toplevel widget as parent
for the next dialog to not block the application.
2021-04-23 15:50:13 +02:00
Christian Hohnstaedt
4f706fb3de Move Help window into separate class
Start it on application start and keep it around
for context sensitive help.
2021-04-09 17:36:03 +02:00
Christian Hohnstaedt
d53d64d23d Transform XCA documentation from SGML to sphinx
linuxdoc is pretty outdated, while sphinx is really cool:

 - Sphinx is modern with a broad user base
 - The generated documentation is themeable
 - The sphinx-source is much more readable than the
   SGML-tag scattered linuxdoc.
 - The different topics can be splitted into different files
 - It can be converted to qt-context sensitive help
 - It supports syntax highlighting for the SQL database documentation
 - It is supported on MacOSX,because it is python-based.

Drop code2html perl-script, which was used to colorize the SQL schema.
Generate "doc/arguments.rst" with XCA_MAN="rst" ./xca
2021-04-09 17:36:03 +02:00
Christian Hohnstädt
7f9f61c5c7 Issue a warning when using an insecure hash algorithm
md5, ripemd160 and sha1 are considered insecure.
Issue a warning if one of them is used.
2021-04-01 14:02:59 +02:00
Christian Hohnstädt
9f0d70746f Fix issuing ED25519 certificates 2021-04-01 13:44:49 +02:00
Christian Hohnstädt
45de747461 Add support for SSH2 ED25519 private key export
Encrypting the SSH2 private keys is not supported, yet.
2021-04-01 12:24:01 +02:00
Christian Hohnstaedt
86cfff35d0 Close #142: Support Ed25519 Public export an Details
- Export SSH2 Public key
- Detect whether ED25519 key is private key
- Support ED25519 in the KeyDetails dialog
   o Display public key
   o Curve name
   o Fingerprints
   o Availability of private key
2021-04-01 11:02:22 +02:00
Christian Hohnstaedt
dbb3c48ef3 Close #142: Support Ed25519 Keygen
Support generating ED25519 keys
2021-04-01 11:02:22 +02:00
Christian Hohnstaedt
25347fa28a OpenDb: Fix opening remote database when local DB was open
The OpenDB dialog did not show up and the previous sqlite
database was opened again.

Start the dialog without current Database preset to always show it.
2021-04-01 11:01:10 +02:00
Christian Hohnstädt
bab4326c0e Change language maintainer of brazilian portuguese 2021-02-06 22:55:20 +01:00
Christian Hohnstädt
e2a0e41151 Close #210: Make dialog to edit SAN less strict
Dialog to edit Subject Alternative Name does now
allow URI scheme to contain digits or special chars.
2020-10-16 11:20:56 +02:00
Christian Hohnstädt
af711cc174 Templates: constify 2020-10-16 00:37:12 +02:00
Christian Hohnstädt
63cf680908 Templates: Fix editing on doubleclick 2020-10-16 00:37:12 +02:00
Christian Hohnstaedt
e9edb75442 ImportMulti: Update pointer management to always free all items 2020-10-16 00:37:12 +02:00
Christian Hohnstädt
e4f9dd6389 Fix opening new database, while another one is open
Avoid crashes by checking for model being set.
Thoroughly close previous database before opening a new one.
Drop changeDB() function and replace by init_database.
2020-10-14 22:02:48 +02:00
Christian Hohnstädt
0745af1d63 Fix editing revocation entries and generate CRL from that dialog 2020-10-14 19:48:18 +02:00
Christian Hohnstädt
a010c091df Manage Revocations: Fix double click on item to edit 2020-10-14 19:48:18 +02:00
Christian Hohnstädt
33787e852b ReqTreeView: signReq() and toRequest() got mixed up. Sort it out 2020-10-14 19:48:17 +02:00
Christian Hohnstädt
24009b13c7 Fix warnings 2020-10-14 19:48:17 +02:00
Christian Hohnstaedt
ef24c00c22 Minor fixes 2020-06-26 14:21:32 +02:00
Christian Hohnstaedt
17b621ccef Encapsulate all index.internalPointer() in fromIndex(index) 2020-05-10 09:09:31 +02:00
Christian Hohnstaedt
45f834a6e4 Move tree-handling from db_x509 class to the base class
This is a preparation for possibly inserting
structuring folder elements later.
2020-05-08 17:37:40 +02:00
Christian Hohnstaedt
af79214121 Use fromIndex(index) convenience function
for certificates create a function returning
a dynamically casted pki_x509 pointer

Add NULL check of dynamically casted pointer,
because it could be a folder...
2020-05-08 17:37:40 +02:00
Christian Hohnstaedt
1e544161f6 Eliminate the use of "mainwin" in lib/db_* 2020-05-08 11:59:09 +02:00
Christian Hohnstaedt
7c65a786ea Revamp database management
The global variable "Database" of class xca_db
can be used by any other class to access. No need
to provide it.

The "xca_db" class managed the "database_model" pointer.
Accessing the name of the current database has been unified.
2020-05-08 07:47:15 +02:00
Christian Hohnstaedt
9b201566e2 Improve on cmdline, console, unicode and windows CMD
Improve Windows registry functions

Use *A postfix function explicit becaus e we don't expect
unicode characters.
Also simplify "console_write()"
2020-05-06 18:32:27 +02:00
Christian Hohnstaedt
b5c9d645e3 More native separators when displaying file names 2020-05-06 17:57:09 +02:00
Christian Hohnstaedt
b2ab7570b8 Minor fixxes and constifies 2020-04-30 18:47:28 +02:00
Christian Hohnstaedt
5a64725556 Move item store from db_base into separate class "pki_lookup"
Since also pki_base and other classes need to access them.
2020-04-30 18:37:25 +02:00
Christian Hohnstaedt
7d5bb9ca4f Fix newline handling 2020-04-07 15:54:16 +02:00
Christian Hohnstaedt
5cb1b45d81 console_write: takes a QByteArray instead of printf()
Good Windows Unicode font:
https://math.berkeley.edu/~serganov/ilyaz.org/software/fonts/
2020-04-06 22:08:04 +02:00