Commit Graph

485 Commits

Author SHA1 Message Date
Morris Jobke 06aef4e8b1 Revert "Updating license headers"
This reverts commit 6a1a4880f0.
2015-02-26 11:37:37 +01:00
Thomas Müller f5b6226732 Merge pull request #14462 from owncloud/add-some-php-docs
Add some PHPDocs
2015-02-25 02:53:22 -08:00
Thomas Müller f6044fe429 Merge pull request #14460 from owncloud/revive/12971
Add support for sftp custom port
2015-02-25 02:52:25 -08:00
Robin McCorkell edfeb05a05 Fix bugs in ownCloud external storage 2015-02-25 10:10:13 +00:00
Lukas Reschke dbb665a361 Add some PHPDocs
My IDE was crying...
2015-02-24 13:44:40 +01:00
Lukas Reschke 1229184873 Fix code that never worked
Introduced with 1df8a5a774 in February 2013…
2015-02-24 13:26:23 +01:00
Lukas Reschke 6dd5bc0379 Fix code style as per review 2015-02-24 13:22:12 +01:00
SA 350f8eb86e Add support for sftp custom port 2015-02-24 13:15:38 +01:00
Jenkins for ownCloud 6a1a4880f0 Updating license headers 2015-02-23 12:13:59 +01:00
Andreas Fischer c640e2fa66 Update phpseclib to version 0.3.9. 2015-02-18 01:16:23 +01:00
Robin Appelman 6467369cad make sure the root has a trailing slash 2015-02-16 13:52:11 +01:00
Robin Appelman e98983485f handle deleting non existing files 2015-02-16 13:52:11 +01:00
Robin Appelman e5731b6e1a Use better way to check for the existence of smbclient 2015-02-16 13:52:11 +01:00
Robin Appelman d2255a1d30 New SMB storage backend 2015-02-16 13:52:11 +01:00
Vincent Petry bd01ff135a Merge pull request #13190 from is-apps/master-sftp-key
Add SFTP public key authentication support
2015-02-10 16:44:29 +01:00
Vincent Petry 3764515365 Allow saving incomplete external storage config
This is needed for Dropbox and others that need a token.
2015-01-27 13:44:05 +01:00
Ross Nicoll 64f4f8fc84 Add support for SFTP key authentication
Add support for external files accessed via SFTP using public key exchange authentication.
Keys are generated automatically when the configuration is added, or can be regenerated on demand if a key is compromised.
Creation of a new configuration row now triggers focus on that row. This is used to trigger auto-configuration for SFTP keys.
Generated public keys are saved in user's data directory for easy retrieval by an external application.
Add controller for SFTP key generation AJAX
SFTP class initialisation no longer produces a warning if the password field is missing.
Add unit tests for SFTP with key authentication backend
2015-01-14 17:00:34 +00:00
Morris Jobke 75e8b39826 Merge pull request #12879 from owncloud/mountconfig
Add mount specific options
2014-12-18 23:38:14 +01:00
Jörn Friedrich Dreyer 49318b4d93 Merge pull request #12896 from owncloud/drop-deprecated
first step to drop \OCP\Config:: in favour of IConfig
2014-12-18 23:01:49 +01:00
Robin Appelman d075b1d743 Add the storage id to the mount config 2014-12-17 14:22:03 +01:00
Robin Appelman 95a145f67f Load mount specific options from the mount config 2014-12-17 14:03:50 +01:00
Morris Jobke d41082f4d6 first step to drop \OCP\Config:: in favour of IConfig 2014-12-17 11:12:37 +01:00
Lukas Reschke 5eaa2214b8 Remove conditional check for 5.3 compatibility 2014-12-12 12:25:59 +01:00
Morris Jobke e3de51078d Merge pull request #12090 from AdamWill/google-rename-delete
google: delete original after successful rename
2014-12-10 09:10:17 +01:00
Lukas Reschke 25a87d4058 Merge pull request #12577 from owncloud/public-mount-api
Add a public api for apps to add mounts
2014-12-08 22:57:33 +01:00
Volkan Gezer 57452a3641 Keep spaces out of the string
Otherwise translators cannot notice them on Transifex.
2014-12-07 01:57:34 +01:00
Robin Appelman a369d78124 Use the mount config api for files_external 2014-12-04 16:47:30 +01:00
Lukas Reschke 805be635fa Only store user credentials when SMB_OC storage is enabled
Conflicts:
	apps/files_external/lib/smb_oc.php
2014-12-01 11:18:29 +01:00
Adam Williamson 415411a3d5 google: delete original after successful rename
In GDrive, filenames aren't unique, and directories are just
special files - so you can have multiple files with the same
name, multiple directories with the same name, and even files
with the same names as directories.

OC doesn't handle this at all, though, and just wants to act
as if file and directory names *are* unique. So when renaming,
we must check if there's an existing object with the same
file or directory name before we commit the rename, and
explicitly delete it if the rename is successful. (Other
providers like dropbox do the same for files, but intentionally
don't do it for directories; we really need to do it for
directories too.)

A good way to observe this is to run the storage unit tests
and look at the state of the Drive afterwards. Without this
commit, there will be several copies of all the test files
and directories. After this commit, there's just one of each.

We can't just say "hey, Drive lets us do this, what's the
problem?" because we don't handle multiple-objects, same-name
cases - getDriveFile() just bails and prints an error if it
searches for the file or directory with a given name and gets
multiple results.
2014-11-30 15:34:35 -08:00
Robin Appelman a2457b5fb9 Merge pull request #6989 from AdamWill/google-1
Migrate Google Drive external storage app to v1.0.6-beta of the google-api-php-client library
2014-11-26 12:17:57 +01:00
Lukas Reschke c749570a06 Merge pull request #12411 from owncloud/unknown-command-windows
Replace some more "command -v" calls with the Helper method
2014-11-26 10:29:41 +01:00
Joas Schilling 0274dcba57 Replace some more "command -v" calls with the Helper method 2014-11-25 18:10:03 +01:00
Joas Schilling 2c39aec8cb Replace deprecated constant with new class constant 2014-11-25 16:30:21 +01:00
Lukas Reschke 284ba5b688 Merge pull request #12290 from owncloud/ext-preventbreakageduetobugs2
Show warning when invalid user was passed
2014-11-19 14:27:32 +01:00
Vincent Petry c941c3fa51 Show warning when invalid user was passed
Sometimes there are bugs that cause setupFS() to be called for
non-existing users. Instead of failing hard and breaking the instance,
this fix simply logs a warning.
2014-11-14 16:43:23 +01:00
Vincent Petry 914f4cb6f2 Do not remove dir entry if it has the same name as the parent
This fixes an issue when a subdir has the same name as its parent, it
would get exluded from the list.
2014-11-13 17:37:56 +01:00
Adam Williamson f76419d190 fix touch() when $mtime is set (Google wants RFC3339) #11267
ownCloud passes us a Unix time integer, but the GDrive API wants
an RFC3339-formatted date. Actually it wants a single particular
RFC3339 format, not just anything that complies will do - it
requires the fractions to be specified, though RFC3339 doesn't.

This resolves issue #11267 (and was also noted by PVince81 in
reviewing PR #6989).
2014-11-10 11:56:01 -08:00
Adam Williamson c237acb395 google: disable compression when curl is not available
This is a slightly hacky workaround for
https://github.com/google/google-api-php-client/issues/59 .
There's a bug in the Google library which makes it go nuts on
file uploads and transfer *way* too much data if compression is
enabled and it's using its own IO handler (not curl). Upstream
'fixed' this (by disabling compression) for one upload
mechanism, but not for the one we use. The bug doesn't seem to
happen if the google lib detects that curl is available and
decides to use it instead of its own handler. So, let's disable
compression, but only if it looks like the Google lib's check
for curl is going to fail.
2014-11-07 22:52:07 -08:00
Adam Williamson 04369fb9cc scrutinizer fix: explicitly declare Google class property $client 2014-11-06 21:28:05 -08:00
Adam Williamson f9bd43ff03 scrutinizer fix: correct @return for getDriveFile() 2014-11-06 21:27:12 -08:00
Adam Williamson 62b859d66f Migrate Google Drive storage app to v1.0.0 of the client library 2014-11-06 18:47:11 -08:00
Jörn Friedrich Dreyer 69a3d8eb1a fix files_external storage id migration 2014-10-31 14:25:55 +01:00
Lukas Reschke b3a04840b5 Add type hinting to functions
It's only reasonable to have proper type hinting here which might even help us to catch bugs.
2014-10-24 14:13:40 +02:00
Lukas Reschke d060180140 Use function outside of loop
Otherwise the function is executed n times which is a lot of overhead
2014-10-24 12:27:53 +02:00
Lukas Reschke 2d2a4741ce Make files non executable
There is not much sense in having these files marked executable, we should avoid that.
2014-10-24 11:14:51 +02:00
Morris Jobke 7c14a17361 Merge pull request #11721 from owncloud/fix-s3-regression
[master] Fix S3 connection regression
2014-10-23 12:42:42 +02:00
Morris Jobke ca01530f57 Merge pull request #11726 from owncloud/s3-fixunittests
Fix S3 folder creation for new AWS API
2014-10-23 12:35:44 +02:00
Vincent Petry 188effa433 Fix S3 folder creation for new AWS API
This also fixes the unit tests
2014-10-22 23:00:30 +02:00
Vincent Petry 71dce48bd3 Fix S3 connection 2014-10-22 22:17:07 +02:00
Vincent Petry 075e8d8e86 Lazy initialize external storages
Fixed the following external storages to not connect in the constructor,
but do it on-demand when getConnection() is called.
- S3
- SWIFT
- SFTP
2014-10-22 12:42:36 +02:00