Commit Graph

295 Commits

Author SHA1 Message Date
Joas Schilling 658af627ce External FTP Storage should request hostname instead of URL
Fix issue #6277
2014-02-12 18:20:10 +01:00
Joas Schilling 828985dc60 Make google drive client secret and dropbox api secret a password field
Fix issue #5794
2014-02-07 18:12:01 +01:00
Vincent Petry bf95532fb6 Removed unused writeBack method 2014-01-23 15:05:05 +01:00
Vincent Petry 421f24868a Now using SFTP stream wrapper from phpseclib
- Upgraded phpseclib to master version (post 0.3.5)
- Now using fopen() on sftp URL for both read and write
- Fixes #4063
2014-01-23 12:43:12 +01:00
Tigran Mkrtchyan a78dc11732 webdav: return SPACE_UNKNOWN if server do not support quota
Signed-off-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de>
2014-01-17 11:45:26 +01:00
Vincent Petry 5e04b7f284 Merge pull request #6422 from ccerrillo/fixing-6301-external-mount-webdav-blank-files
Fixing Issue #6301 on master branch
2014-01-13 07:09:01 -08:00
Thomas Müller a8d20e0919 Merge pull request #5238 from owncloud/externalstorage-owncloudbackend
Added ownCloud backend for external storage
2014-01-08 01:49:15 -08:00
Michael Monreal f52a9e5e42 Silence output of 'which' command used in smbclient detection 2013-12-27 18:10:47 +01:00
Carlos Cerrillo c06844c374 Fix ```createCertificateBundle``` and ```getCertificates``` methods
from ```OC_Mount_config``` to use ```OC_User::getHome``` to get the
path
2013-12-17 10:13:14 +01:00
Carlos Cerrillo b245e2e3d8 Fixing tab/space coding style
Only set SSL things when ```$this->secure``` is ```true```
2013-12-17 09:38:43 +01:00
Carlos Cerrillo 7c264c88fe Fixing Issue #6301 on master branch
Added private var $certPath to store the user root cert

Move logic to determine the $certPath path to the constructor and modify to get the path from OC_User::getHome()

Add curl options to use the certificate to avoid certificate errors with self-signed certicates in the downdload/upload method so we don't get blank files
2013-12-15 17:22:52 +01:00
Vincent Petry 3b7905364f Fixed test function for S3
Fixes #5752
2013-12-03 12:26:08 +01:00
Vincent Petry 76b1fcbf27 Fixed Amazon S3 ext storage config UI
Optional parameters are now really optional

Fixes #5861
2013-12-03 12:26:08 +01:00
Vincent Petry d69243ee51 Fixed FTP and SMB to use rmdir() when deleting folders
Some storages need to use different calls for deleting files or folders,
usually unlink() and rmdir().

Fixes #4532 (SMB dir deletion)
Fixes #5941 (FTP dir deletion)

Note that the extra is_dir() should be fast because it's read from the
stat cache.
2013-11-29 13:01:01 +01:00
Vincent Petry 84f3dd15a6 Add trailing slash in FTP root path when missing
Fixes #6093
2013-11-28 11:45:26 +01:00
Vincent Petry 30e086fb53 Fixed SFTP storage to overwrite on rename 2013-11-26 16:32:44 +01:00
Vincent Petry 2653d914d9 Merge pull request #6008 from owncloud/extstorage-smb-webdav-renamefix
Fixed SMB rename function to overwrite target file
2013-11-26 06:42:36 -08:00
Morris Jobke a48fc120d0 Merge pull request #6054 from owncloud/extstorage-dropboxfixes
Fixed various Dropbox issues + unit tests
2013-11-26 04:48:54 -08:00
Vincent Petry e102eec89a Return true when touch succeeds 2013-11-26 12:47:00 +01:00
Vincent Petry 7c81ac3d28 Fixed various Dropbox issues + unit tests
- fixed touch function to return true on success
- fixed local metadata cache to remove deleted files/directories
- fixed getMetaData() to ignore files reported as deleted by
  Dropbox
- fixed "file not found" case to not log as exception
- fixed "overwrite on rename" case
- fixed unit tests to exclude unsupported cases
- added unit test for touch return value
- unit tests for Dropbox should all run correctly now
2013-11-26 11:59:36 +01:00
Vincent Petry d88025bf6b Fixed ext storage touch function to return true on success
Some ext storage impl didn't return true on success.

Fixes #5943 (Dropbox)
Fixes #6010 (WebDAV)
2013-11-25 12:44:27 +01:00
Vincent Petry 1b0c5e57e5 Fixed SMB rename function to overwrite target file
When uploading files through WebDAV, a part file is created and a rename
operation is performed with the expectation that the part file
overwrites an existing file, if any.

This fix makes the SMB external storage delete the target file before
renaming, as smbclient doesn't support overwrite on move/rename.

Fixes #5348
2013-11-25 11:17:38 +01:00
Morris Jobke b82146eeee Merge pull request #5991 from owncloud/extstorage-mountpointvalidation
Prevent using root as mount point for external storage
2013-11-25 00:30:06 -08:00
Vincent Petry 2d947835b9 Now also preventing the user of "Shared" as mountpoint 2013-11-22 18:36:27 +01:00
Vincent Petry c62cce8269 Moved default isReadable/isUpdatable impl into Common class
Also adjusted all ext storage backends to not override these when the
default behavior is expected.
2013-11-22 18:21:17 +01:00
Vincent Petry a49e873d3f Return plausible isReadable() default impl for ext storage
When an ext storage doesn't implement isReadable(), always returning
true made the file scanner believe that the file exists and creates a
cache entry with the size zero.

This fix makes the default impl of isReadable() use file_exists().

Fixes #5940
2013-11-22 18:21:17 +01:00
Vincent Petry 0b2c9b823c Prevent using root as mount point for external storage
Fixes #5981
2013-11-21 17:22:12 +01:00
Vincent Petry 39cbdca429 Fixed path normalization to prevent dot dirs
Fixes #5945 where stat(.) would cause the backend OC to cache a dot dir
(only in older versions)
2013-11-21 16:07:01 +01:00
Vincent Petry 391f267d38 Merge pull request #5897 from hkjolhede/master
Fixed error-checking error in sftp.php
2013-11-21 01:22:05 -08:00
Vincent Petry e26500045f Fixed move operation to pass the whole URL as expected
The MOVE and COPY spec expect the "Destination" header to receive the
full URL, not only the root.

Fixes #5942
2013-11-20 18:59:02 +01:00
Vincent Petry 5b6d1d79d0 Fixed SMB file deletion success detection
Since unlink() smb4php doesn't return true on deletion success, we need
to check whether the file was deleted to confirm success.

Fixes #5866
2013-11-19 15:05:11 +01:00
Vincent Petry 8ab40f1959 Removing trailing dot in path that samba doesn't seem to like
Fixes #5778
Added unit test for getId() and constructUrl()
2013-11-19 15:05:11 +01:00
hkjolhede 3e2d4c1bc1 Fixed error-checking error in sftp.php 2013-11-15 21:10:09 +01:00
Christian Berendt 70276ca520 settings tags for optional parameters 2013-10-29 10:21:50 +01:00
Christian Berendt 235bf5269d extended parameter descriptions for Swift 2013-10-29 09:19:43 +01:00
Christian Berendt dd82481f59 add configuration parameter to manually set the timeout of HTTP requests 2013-10-24 16:19:17 +02:00
Christian Berendt 128d3221cc make Swift::testLocal workable by using a delimiter 2013-10-23 08:07:59 +02:00
Christian Berendt a1e956263c Revert "make Swift::testLocal workable by fixing the prefix used with the object listing in opendir"
This reverts commit b92061da5a.
2013-10-23 08:01:32 +02:00
Christian Berendt b92061da5a make Swift::testLocal workable by fixing the prefix used with the object listing in opendir 2013-10-23 07:57:41 +02:00
Christian Berendt 506db6c63a rewrite of OC\Files\Storage\Swift 2013-10-22 14:59:09 +02:00
Christian Berendt f0d04f3ac6 adjustment of the configuration parameters 2013-10-22 13:34:24 +02:00
Vincent Petry b1f1357957 Added ownCloud backend for external storage
To make it possible to use the short ownCloud URL (without specifying
webdav.php or remote.php), a new backend is available for ownCloud.

The user must specify the host + context path in the "Url" field (which
is mapped to the "host" parameter) and the subdir to mount in the "Root"
field.

This is to prevent confusion because some users forget to append
webdav.php or remote.php to the WebDAV URL.

Fixes #4923
2013-10-09 17:30:22 +02:00
Thomas Müller 9637ca3ae8 Merge pull request #5070 from owncloud/smb-streamwrapper-fixes
Various fixes for the streamwrapper based SMB backend
2013-10-09 03:05:51 -07:00
Lennart Rosam 5470700c9a Update file to meet coding standarts 2013-10-07 01:08:39 +02:00
Lennart Rosam 72ad309920 Actually test the connection 2013-10-07 01:08:38 +02:00
Lennart Rosam b9a948b597 Fixes #4129 2013-10-07 01:08:38 +02:00
Robin Appelman de43515cfa fix recursive delete for smb 2013-10-01 22:33:58 +02:00
Robin Appelman 29deef38b2 fix using touch to create a file for smb 2013-10-01 22:31:22 +02:00
Thomas Müller d5ddbfb045 Merge pull request #4719 from owncloud/port_4701_master
Always check variable type before using readdir to avoid surprises
2013-09-12 15:44:20 -07:00
Thomas Müller 3b835ea1b6 never hack late night 2013-09-11 01:11:57 +02:00