Merge pull request #21031 from owncloud/sanitize-findAppInDirectories

Sanitize the appId passed to `findAppInDirectories`
This commit is contained in:
Thomas Müller 2015-12-08 13:52:04 +01:00
commit 49095fa4bb
1 changed files with 5 additions and 1 deletions

View File

@ -474,9 +474,13 @@ class OC_App {
* search for an app in all app-directories
*
* @param string $appId
* @return mixed (bool|string)
* @return false|string
*/
protected static function findAppInDirectories($appId) {
$sanitizedAppId = self::cleanAppId($appId);
if($sanitizedAppId !== $appId) {
return false;
}
static $app_dir = array();
if (isset($app_dir[$appId])) {