[Pkg-owncloud-commits] [owncloud] 306/457: Validate path in getChild

David Prévot taffit at moszumanska.debian.org
Sun Jun 28 20:06:29 UTC 2015


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch stable8
in repository owncloud.

commit 06dda427f38f240539f4d3054da7a5eb80aaaf8b
Author: Vincent Petry <pvince81 at owncloud.com>
Date:   Fri Jun 5 12:08:18 2015 +0200

    Validate path in getChild
---
 lib/private/connector/sabre/directory.php | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/lib/private/connector/sabre/directory.php b/lib/private/connector/sabre/directory.php
index 58f16a2..7349db3 100644
--- a/lib/private/connector/sabre/directory.php
+++ b/lib/private/connector/sabre/directory.php
@@ -150,9 +150,12 @@ class Directory extends \OC\Connector\Sabre\Node
 		$path = $this->path . '/' . $name;
 		if (is_null($info)) {
 			try {
+				$this->fileView->verifyPath($this->path, $name);
 				$info = $this->fileView->getFileInfo($path);
 			} catch (\OCP\Files\StorageNotAvailableException $e) {
 				throw new \Sabre\DAV\Exception\ServiceUnavailable($e->getMessage());
+			} catch (\OCP\Files\InvalidPathException $ex) {
+				throw new InvalidPath($ex->getMessage());
 			}
 		}
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud.git



More information about the Pkg-owncloud-commits mailing list