1
0
Fork 0
Commit Graph

114 Commits

Author SHA1 Message Date
Olivier Goffart 8ca3eb7883 Merge remote-tracking branch 'origin/master' into chunking-ng 2016-10-31 11:09:12 +01:00
Christian Kamm 5f47c01346 Account: Rearrange for readability 2016-10-25 13:20:23 +02:00
Christian Kamm 10644d3568 Move concatUrl and settingsWithGroup to Utility
There was little reason to keep them cluttering Account.
2016-10-25 12:05:28 +02:00
Christian Kamm 9ee3144358 Account: Remove wasMigrated/setMigrated
It was unused since early in the multi-account work:
a932eac832
2016-10-25 11:43:06 +02:00
Christian Kamm cf48ea2e00 Remove unused functions
Account::changed and AbstractCredentials::changed have not been needed
in a long while.
2016-10-25 11:33:38 +02:00
Christian Kamm db24f60ae3 License: Adjust license of GPLv2 source files to GPLv2+
See #5180
2016-10-25 11:06:54 +02:00
Olivier Goffart 4c79ce2ae6 ConnectionValidator: fetch the account name.
This is needed for the new webdav path used by the new chunking.
The user might not be the same as the one used to connect
2016-09-16 15:49:43 +02:00
Olivier Goffart a1558100b8 WIP: new chunking algorithm
Current limitations of this WiP
 - No resuming implemented yet
 - No parallel chunks
 - Hackish way to get the webdav paths
2016-08-31 10:28:15 +02:00
Jocelyn Turcotte d40c56eda5 Account: Use smart pointers to hold its credentials and QNAM objects
Also make sure that both use QObject::deleteLater as their delete
function.
2016-06-15 18:12:01 +02:00
ckamm 0e2c16e827 Certs: Re-ask for different cert after rejection #4898 (#4911)
Previously rejecting any kind of certificate meant that the user
was never asked again, even if the certificate changed.

Now we keep track of which certificates were rejected and ask again
if the ones mentioned in the ssl errors change.

mitmproxy is excellent for testing this.
2016-05-27 12:08:42 +02:00
Klaas Freitag 0eb1041290 AbstractNetworkJob: Add a delete job.
It is needed to easily send delete requests which happen
through the notify API.
2016-03-10 17:22:36 +01:00
Christian Kamm f66c28900a Add warnings for old server versions #4523
* A tray message on every start up
* Red message in account settings
* Folders are paused when the server version switches to
  an unsupported one
2016-03-02 12:54:22 +01:00
Christian Kamm d521232587 AccountState: Allow storing state in settings
This will be useful if we ever want to store account-level gui state.
I built this originally because I thought a paused account would be
this kind of state.
2016-03-01 16:08:23 +01:00
Niels van Adrichem 8f5658bc01 Added Non Shibboleth WebDAV authentication and Dav Path customization to `owncloudcmd` 2015-11-02 22:57:17 +01:00
Markus Goetz ccec186b98 ETagJob: Depth 0 for server >= 8.1 #3730 2015-10-19 15:31:27 +02:00
Phil Davis f0e17fd9c0 libtypos comment and message typos for master 2015-10-05 09:05:09 +05:45
Christian Kamm efefc2d986 Merge branch '2.0'
Conflicts:
	doc/images/menu.png
	doc/images/settings_network.png
2015-10-02 15:44:50 +02:00
Klaas Freitag 8c2b5af7f0 Account: Fixed typo in comment. 2015-09-10 17:44:20 +02:00
Klaas Freitag 93e1ad088c Account: Make sure that davPath() always comes with trailing slash. 2015-09-10 15:38:40 +02:00
Klaas Freitag 16d6418d10 Use a themable WebDAV path all over.
This is needed for enterprise#481
2015-09-10 13:04:26 +02:00
Jocelyn Turcotte 6d027ebd40 Separate the credential dialog from their fetch #3350
This moves the responsibility of asking the user or not for
credentials from the Credentials classes back to the AccountState.
fetch() now only extract credentials from the keychain, reports
the result to the AccountState which then decides if askFromUser()
should be called or not. The result is once more reported to the
AccounState.

This also replaces the HttpCredentials::queryPassword virtual
which now lets HttpCredentialsGui and HttpCredentialsText do it
the way that they prefer.
2015-09-05 16:00:45 +02:00
Markus Goetz 38b8508f15 Account: Save accepted SSL certs immediatly #3617 2015-08-14 11:31:01 +02:00
Markus Goetz bd71fdc388 SslButton: Fix harder #3534 #3536 2015-08-11 12:18:25 +02:00
Olivier Goffart 07ddf18b3b Account Capabilities: style fixup
- Remove the copy constructor. The default constructor is fine. Having
   a user defined copy constructor inhibit the move constructor.
 - Pass QVariantMap arguments via const references
 - Do not return a pointer to Capabilities from the account. It is a
   value type and should not be used by pointer.
2015-07-29 12:07:57 +02:00
Markus Goetz dccaba98af Merge pull request #3439 from rullzer/use_caps
Use server capabilities for share dialog
2015-07-29 11:50:35 +02:00
Roeland Jago Douma 6c8ff7c61a Added capabilities class 2015-07-28 12:04:24 +02:00
Christian Kamm 2124098f84 System proxy: Ask for credentials if needed.
The proxyAuthenticationRequired() signal now goes to the
ProxyAuthHandler class. That class will try to read the proxy settings
from the keychain or ask the user about them.

We won't ask the user for credentials for explicitly configured proxies.
It also does not change how the credentials for explicitly configured
proxies are stored. (see #261)
2015-07-17 11:54:46 +02:00
Daniel Molkentin a1b6571d53 Revert "Do not use std::unique_ptr"
This reverts commit 2db7ab5c46.
2015-07-02 13:31:42 +02:00
Olivier Goffart 2db7ab5c46 Do not use std::unique_ptr
The class is not existing on all platform we support
(namely macos 10.7)
2015-07-02 12:55:54 +02:00
Daniel Molkentin 66e8aaeabc Use doxygen style everywhere 2015-06-29 18:56:09 +02:00
Daniel Molkentin 0735aa1fbd Structure developer documentation
- rename target "doc-dev"
- group into modules
- move to doc/dev
2015-06-29 18:43:21 +02:00
Olivier Goffart 29fecb029e Merge remote-tracking branch 'origin/1.8'
Conflicts:
	VERSION.cmake
        src/gui/accountsettings.cpp
	src/gui/accountsettings.h
2015-06-25 12:30:52 +02:00
Jocelyn Turcotte 9a9897ea1e Shibboleth: Let the webview use its own QNAM #3359
Since we periodically recreatet the QNAM owned by the Account,
the web view could end up holding a dangling pointer to it.

Let the web view use its own QNAM, but make sure that the cookie
jars are shared so that we can grab the session token given
by the server.
2015-06-19 12:33:11 +02:00
Olivier Goffart 6e337ad242 Move Account::settings to AccountState::settings
It is only used by the GUI. Also return a unique_ptr to make the ownership clearer
2015-06-15 17:39:28 +02:00
Olivier Goffart 716b0c68da Merge remote-tracking branch 'origin/master' into new-ui 2015-05-12 15:20:40 +02:00
Daniel Molkentin a36df4aa4b Merge remote-tracking branch 'origin/1.8' into 1.9 2015-05-12 09:57:22 +02:00
Markus Goetz f2004da867 SSL: Re-use encryption session for different TCP connections #3159
This also improves the SSL configuration creation and fixes #3027
2015-05-08 14:21:27 +02:00
Christian Kamm b9eafaaf24 Wizard: Allow SSL cert dialog to show twice. #3168
Normally we never ask twice for the same url, but in the setup wizard
it makes sense to do so.
2015-05-08 12:32:14 +02:00
Christian Kamm 27159104a9 Folders: Store inside account config. 2015-04-24 13:42:35 +02:00
Christian Kamm abfdc574d4 Add a basic random Account::id() 2015-04-23 15:47:49 +02:00
Christian Kamm 28306e5dfb Move AccountState::displayName to Account. 2015-04-23 15:47:49 +02:00
Olivier Goffart 2da3bfb96f Merge branch 'master' into new-ui 2015-04-16 12:50:21 +02:00
Olivier Goffart afdd01488f AccountManager: Move out of libsync
The AccountManager does not belong in the libsync because it is not
part of the synchronisation algorithm, but is just an helper class
for the UI to maintain the account and read/save the config
2015-04-09 16:19:17 +02:00
Olivier Goffart 50ba73860c Merge remote-tracking branch into 1.8 2015-04-07 08:02:55 +02:00
Markus Goetz 750cdc1910 AbstractSslErrorHandler: Also give QSslConfiguration 2015-04-06 21:46:03 +02:00
Markus Goetz 99734f8d72 Account: Unusued variable 2015-03-25 08:52:23 +01:00
Christian Kamm 57c14a0eba Windows: Reset QNAM as a workaround. #2899 #2895 #2973
The QNetworkAccessManager is reset when we are disconnected, just
before attempting to fetch the server's status.php.

This may help fix the problem described in various issues where we
get 'Connection closed' or timeout errors after the OS has woken
from sleep.
2015-03-19 11:40:47 +01:00
Olivier Goffart 9351c7485f Try another way to fix the build 2015-02-17 14:04:16 +01:00
Olivier Goffart d43b82dc82 Fix compilation with clang
The compilation error was

 account.h:140:113: error: expected ')'
 const QList< QPair<QString, QString> > &queryItems = QList< QPair<QString, QString> >());
                                                                                   ^
followed by more errors.

The problem is because the compiler has hard time disambiguiating the comma

int foo(const QPair<int, int> &p = QPair<int, int>());
                                            ^
It is indeed quite hard for the compiler to know if this comma is a separation
between complate arguments or the separation between arguments of the functions.

Use the C++11 construct instead which does not need commas
2015-02-17 11:09:45 +01:00
Christian Kamm 40dbc78407 concatUrl: Remove manual parsing, add test. #2817 2015-02-13 14:53:55 +01:00
Olivier Goffart 438c4fe72e Account: put the server version in the account 2015-02-12 14:50:42 +01:00
Olivier Goffart 856df4c5f6 libsync: Get the capabilities and store it in the account 2015-02-05 15:42:56 +01:00
Joachim Schiele 9abc3e1333 fixes required by upstream 2015-01-23 19:22:56 +00:00
Nourredine ba8b1bbe06 adds 'SSL client certificate' support from n.octeau with qknight changes as:
* removed broken QSsl::SslV3 default
* rewrote slotHandleErrors(): no longer claim errors which are none.
* hack reverted: lib64 was not the cause for NixOS issues related to libraries.
* refactored csync/src/csync_owncloud.c and discovered+fixed why the dav_connect was never getting the certPath+certPassoword
* cleanup of code but seems this crushed the ssl client certificate support
* fixes the https://github.com/owncloud/client/issues/69#issuecomment-69358377 issue
* lots of cleanup
* From TODO list : translate all french comments into english
* changed _pemCertificate type from QString to QByteArray
2015-01-21 23:55:11 +00:00
Christian Kamm 38ebfec1fb Use global Account/AccountState less.
* Use a shared pointer to Account everywhere to ensure
  the instance stays alive long enough for a sync to terminate
* Folder is now tied to an AccountState
* SyncEngine and OwncloudPropagator tie to an Account and use that
  for all jobs they run

Issue: Since the setup wizard currently always replaces the
account, it will always wipe all folder definitions, even when
the actual changes to the account were minor.
2014-12-18 15:39:51 +01:00
Christian Kamm 6c7acd585e Account: Split into libsync/Account and gui/AccountState.
This allows all the account state information to live in gui
while the sync-relevant data stays in libsync.

I also moved quotainfo to gui since it depends on the account state.
2014-12-18 15:39:51 +01:00
Christian Kamm a006c6962c Move account state related logic into Account.
The account state is now managed mostly by the Account itself
instead of through Application. The gui can still control whether
an account is signed out or not.
2014-12-17 12:01:10 +01:00
Christian Kamm d8c59fcb73 Use connection validator to ping the server. #2485
* Stop the quota job from having an effect on account status
  as it can sometimes take a long time to reply. See #2485 and
  owncloud/core#12744.

* Instead of indirectly using the quota job, use the connection
  validator to regularly ping the server with a basic PROPFIND for
  'getlastmodified' on /.
  This request was usually fast for users even when the quota PROPFIND
  was slow.
2014-12-10 13:40:11 +01:00
Christian Kamm 53d5de685c Merge remote-tracking branch 'origin/1.7'
Conflicts:
	src/gui/folder.cpp
	src/gui/folder.h
	src/libsync/networkjobs.cpp
	src/libsync/owncloudpropagator.h
	src/libsync/propagatedownload.cpp
2014-12-10 13:01:36 +01:00
Daniel Molkentin ae85aa33fd Adjust namespaces 2014-11-09 22:34:07 +01:00
Daniel Molkentin f2eadacf09 Remove "Mirall" from class names 2014-11-09 22:30:29 +01:00
Christian Kamm 7ae0338f5c Merge remote-tracking branch 'origin/1.7'
Conflicts:
	src/CMakeLists.txt
	src/cmd/cmd.cpp
	src/gui/socketapi.h
	src/libsync/syncengine.h
	test/CMakeLists.txt
2014-10-22 10:41:55 +02:00
Klaas Freitag bcff1ced5e Merge branch '1.7'
Conflicts:
	src/CMakeLists.txt
	src/cmd/cmd.cpp
	src/gui/folderman.cpp
	src/gui/wizard/owncloudadvancedsetuppage.cpp
	src/libsync/account.cpp
2014-08-29 20:40:33 +02:00
Daniel Molkentin df3c3bca02 Split into three separate projects: library, gui and cmd 2014-07-11 11:07:31 +02:00