Commit Graph

14 Commits

Author SHA1 Message Date
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
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
f889efc4cb Merge branch 'master' into develop 2020-04-30 18:34:16 +02:00
Christian Hohnstaedt
a9a4c2b2d6 remote database: Dont show error if the password was empty
Otherwise, first an error message is shown and then
a password is asked.
2020-04-05 13:08:47 +02:00
Christian Hohnstaedt
c528c37986 Merge branch 'master' into develop 2020-04-05 10:58:47 +02:00
Christian Hohnstaedt
5543ec2fb8 Merge branch 'master' into develop 2020-04-02 07:35:18 +02:00
Christian Hohnstaedt
9845a00ca3 Store default database and recently opened file as UTF8 2020-03-17 05:07:46 +01:00
Christian Hohnstaedt
ef9b3aff3d Drop superflous includes from header files 2020-03-13 12:13:27 +01:00
Christian Hohnstaedt
10857e3e0c Support item import from the commandline 2020-03-13 12:13:27 +01:00
Christian Hohnstaedt
19eafe1739 Improve and fix qDeleteAll()
qDeleteAll() does not clear the QList.
Add it, if necessary.

Use dynamic_cast where appropriate
2020-03-13 12:13:27 +01:00
Christian Hohnstaedt
b2a69f3586 Several fixes of previous commit
Passwd::cleanse() also resets the password size
db_base::flushLookup() now deletes all items
and pki_base does not anymore.

Drop TRACE
Colorize pki_base::print()

Set and inherit filename of loaded items
Add print() method to pki_pkcs12
and constify its methods
2020-03-11 07:19:56 +01:00
Christian Hohnstaedt
a90d7b5b0d Improve password input handling
Unify password results
Retry on password verification error
Honor the users wish to exit
2020-03-11 07:19:56 +01:00
Christian Hohnstaedt
176c2f8169 Improve password input and handling
Use the Passwd class instead of QString

Move password input into the database model
to be available for commandline use.

Repeat in case of wrong password
2020-03-11 07:19:56 +01:00
Christian Hohnstaedt
113a201d39 Separate database from Mainwin for better cmdline support
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
2020-03-11 07:19:56 +01:00