Project

General

Profile

Actions

Bug #60511

closed

FAL Indexer (scheduler task) doesn't respekt symlinks

Added by Markus Blaschke over 9 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
File Abstraction Layer (FAL)
Target version:
-
Start date:
2014-07-24
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
6.2
PHP Version:
5.5
Tags:
Complexity:
easy
Is Regression:
No
Sprint Focus:

Description

Currently the indexing scheduler task from FAL ignores symlinks and all files behind symlinks are not indexed.

Method TYPO3\CMS\Core\Resource\Driver\LocalDriver::retrieveFileAndFoldersInPath skips all symlinks because they are not "isFile" and not "isDir".

Actions #1

Updated by Frans Saris over 9 years ago

  • Status changed from New to Needs Feedback

Are yourserver settings and folder permissions correct?

From what I read on the net it this should work. Didn't test myself

See:
- http://stackoverflow.com/questions/6969901/is-dir-returning-false-on-symlinks-in-apache
- http://php.net/manual/en/function.is-dir.php

Actions #2

Updated by Markus Blaschke over 9 years ago

Thanks, that was the other issue.

But the real issue remains because the RecursiveDirectoryIterator doesn't follow symlinks be default.

The iterator needs "\FilesystemIterator::FOLLOW_SYMLINKS" as additional mode:

currently:
$iteratorMode = \FilesystemIterator::UNIX_PATHS | \FilesystemIterator::SKIP_DOTS | \FilesystemIterator::CURRENT_AS_FILEINFO;

new:
$iteratorMode = \FilesystemIterator::UNIX_PATHS | \FilesystemIterator::SKIP_DOTS | \FilesystemIterator::CURRENT_AS_FILEINFO | \FilesystemIterator::FOLLOW_SYMLINKS;

"\FilesystemIterator::FOLLOW_SYMLINKS" was introduced with PHP 5.3.1.

Actions #3

Updated by Alexander Opitz over 9 years ago

  • Status changed from Needs Feedback to New
Actions #4

Updated by Mathias Schreiber about 9 years ago

  • Sprint Focus set to On Location Sprint
Actions #5

Updated by Ingo Schmitt about 9 years ago

  • Complexity set to easy
Actions #6

Updated by Mathias Schreiber about 9 years ago

  • Status changed from New to In Progress
Actions #7

Updated by Gerrit Code Review about 9 years ago

  • Status changed from In Progress to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/36429

Actions #8

Updated by Gerrit Code Review about 9 years ago

Patch set 1 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/36470

Actions #9

Updated by Roman Schürmann about 9 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions #10

Updated by Anja Leichsenring about 8 years ago

  • Sprint Focus deleted (On Location Sprint)
Actions #11

Updated by Benni Mack over 5 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF