Commit Graph

18 Commits

Author SHA1 Message Date
Martin Kleusberg
84615258af dbhub: Push databases using the POST method instead of PUT 2017-08-15 21:22:05 +02:00
Martin Kleusberg
38caf867bc dbhub: Refresh the directory list when a database upload has finished 2017-08-13 14:53:19 +02:00
Martin Kleusberg
17cf3ad7d9 dbhub: Support multiple simultaneous downloads/uploads of databases
This feature isn't explicitly available via the UI (yet) but should
prevent errors when the user is faster than the network connection, e.g.
when opening two directories very quickly.
2017-08-13 13:42:30 +02:00
Martin Kleusberg
3d1f2062f9 dbhub: Also clear access cache when pushing a database as other user 2017-08-12 21:49:32 +02:00
Martin Kleusberg
1c7cc24b15 dbhub: Improve push database UI
This adds a new Push Database dialog which lets you specify the database
name, the licence, a commit message, and the visibility of the database.
2017-08-12 14:58:30 +02:00
Martin Kleusberg
e08ebffd63 dbhub: Improve UI for pushing databases
This improves the user experience for pushing database files. Before
this you had to type in the entire URL for pushing, e.g.:
https://db4s-beta.dbhub.io:5550/username/databasename
With this the host name as well as the user name is taken from the
currently active client certificate. So all you have to type in now is
the database name. And for this we make a sensible automatic suggestion
based on the name of the local file you're trying to push.

Note that while this makes pushing databases a lot easier, it still
doesn't implement proper version control or any extra code for handling
conflicts etc.
2017-08-03 19:02:42 +02:00
Martin Kleusberg
43a5175af1 dbhub: Keep track of the cloned databases
This adds a local database to keep track of all the cloned databases.
For now we only use this information to prevent exactly the same
database being downloaded twice.
2017-03-23 19:08:26 +01:00
Martin Kleusberg
1e9fec270b Merge automatic update check into dbhub.io code
Move the network part of the automatic version check code into the
dbhub.io parts. While semantically this doesn't make a lot of sense it
simplifies the code a bit, reduces the size of the main window class,
and avoids duplication of code e.g. when introducing proxy support.
2017-03-19 17:29:20 +01:00
Martin Kleusberg
dec1c6acb1 dbhub: Code refactoring 2017-03-19 16:56:14 +01:00
Martin Kleusberg
3e4f3fc3d2 dbhub: Add remote dock with directory browsing support
This adds a new dock to the main window that contains all the remote
functionality (or is supposed to contain it all in the future).

It also adds a directory browsing feature which allows you to browse
through the folders and files on the dbhub server.

By double clicking a database you can download and open it. The Open
Remote menu action isn't needed anymore and has been removed.

This also fixes an issue with pushing databases where, after sending the
file is completed, the save dialog was opened.

Note that this is still WIP and is far from polished.
2017-03-18 20:40:59 +01:00
Martin Kleusberg
df5e604e6e dbhub: Add support for sending files
NOt perfect yet but a start.
2016-11-07 23:38:51 +01:00
Martin Kleusberg
eeeec5f2fc dbhub: Use certificate manager to get client cert for authentication
When trying to fetch a database don't load a hardcoded client
certificate but grab one from the certificate manager in the preferences
dialog.

Also add support for password protected private keys.

Note: Since this is all testing code on the front-end side, we just use
the first certificate in case multiple certificates are configured.
2016-11-06 14:50:27 +01:00
Martin Kleusberg
60e4cb758e dbhub: Add client certificate management
Add a list of all configured client certificates to the preferences
dialog and show some information on them.

Add two button to the preferences dialog to add and remove client
certificates.

Copy configured client certificates to some safe place where they aren't
deleted by accident.

Change the remote code to expect certificate and private key in one
file. The path to this file is still hardcoded, now to client.cert.pem.

Remove the example client certificate as it's not up-to-date anymore
anyway.

Still missing: Option to use a configured client certificate from the
preferences dialog to authenticate.
2016-11-01 22:54:50 +01:00
Martin Kleusberg
6283f97598 dbhub: Add list of CA certificates and restructure code
Change the layout of the preferences dialog a bit.

Remove the server selection combo box from the preferences dialog as it
will probably never be required. The way we do logins using certificates
kind of makes this obsolete, I think.

Restructure the whole remote code a little bit. Also add helper
functions here and there.

Show a list of our the CA certificates built into the application in the
preferences dialog. This list is read only of course but still
informative as it tells the user which sites are supported ny DB4S.
2016-11-01 19:45:42 +01:00
Martin Kleusberg
08e7f575ee dbhub: Fix weird progress bar behaviour 2016-10-25 20:54:42 +02:00
Martin Kleusberg
c2a9608c80 dbhub: Add basic HTTPS support
This adds basic support for fetching databases via HTTPS using client
certificates. You can include CA certificates to verify any responses
from a server. For now, one test CA certificate is included but it's
easy to add more.

It's also possible to authentify the client using a client certificate,
a client key and a password. As of this commit all three items are
hardcoded.

It's still possible to access any remote database via HTTP but if a
request URL starts with 'https' this new mechanism will be used.

All certificates, keys, and password included in here are taken from my
node.js test server repository. They will be replaced soon-ish.
2016-10-25 20:42:31 +02:00
Martin Kleusberg
fad7246400 dbhub: Show download progress and allow canceling downloads 2016-10-24 23:56:36 +02:00
Martin Kleusberg
4d26624bda dbhub: Add very basic support for opening remote files
This adds some initial support for opening remote files. You can enter a
URL and DB4S will try to download the file. When successful you'll be
able to specify a place and name to save the file under, and after
saving it locally to disk it'll be opened just like any local database
file.

See the included TODO comments for missing features. Most notably
missing is the HTTPS and certificate handling code. Also any support
for storing the remote source of a database is lacking.
2016-10-24 22:49:32 +02:00