[Bug 997391] Re: Symbolic links can create recursive loop that causes Baobab to never finish scanning

Bug Watch Updater 997391 at bugs.launchpad.net
Sat Oct 28 07:38:12 UTC 2017


Launchpad has imported 9 comments from the remote bug at
https://bugzilla.redhat.com/show_bug.cgi?id=849332.

If you reply to an imported comment from within Launchpad, your comment
will be sent to the remote bug automatically. Read more about
Launchpad's inter-bugtracker facilities at
https://help.launchpad.net/InterBugTracking.

------------------------------------------------------------------------
On 2012-08-18T12:55:15+00:00 Erik wrote:

Created attachment 605323
Proposed patch (created by upstream)

Hi,

While investigating an issue with baobab (gnome disk usage tool, bug
811399) I found out that ntfs-3g returns an invalid result when a
junction point (symbolic link) is detected. Whenever a junction point is
detected, the readdir syscall thinks that the file in question is a
directory while it actually is a symbolic link.

I filed this issue upstream along with a testcase and they provided a
fix for this issue. I tested this patch on my Fedora 17 x86_64
environment and it indeed does resolve the baobab issue.

Could you please apply this patch in the ntfs-3g package for now?

For more details, see:
https://bugzilla.redhat.com/show_bug.cgi?id=811399
https://bugzilla.gnome.org/show_bug.cgi?id=672219
http://tuxera.com/forum/viewtopic.php?f=2&t=29578

Reply at:
https://bugs.launchpad.net/fedora/+source/baobab/+bug/997391/comments/3

------------------------------------------------------------------------
On 2012-08-20T01:12:19+00:00 Tom wrote:

Erik, the patch you attached is seriously malformed (how did you manage
that?), but I found the correct patch from the tuxera link. Update is
coming, thanks.

Reply at:
https://bugs.launchpad.net/fedora/+source/baobab/+bug/997391/comments/6

------------------------------------------------------------------------
On 2012-08-20T01:25:51+00:00 Fedora wrote:

ntfs-3g-2012.1.15-3.fc17 has been submitted as an update for Fedora 17.
https://admin.fedoraproject.org/updates/ntfs-3g-2012.1.15-3.fc17

Reply at:
https://bugs.launchpad.net/fedora/+source/baobab/+bug/997391/comments/7

------------------------------------------------------------------------
On 2012-08-20T01:26:05+00:00 Fedora wrote:

ntfs-3g-2012.1.15-3.fc18 has been submitted as an update for Fedora 18.
https://admin.fedoraproject.org/updates/ntfs-3g-2012.1.15-3.fc18

Reply at:
https://bugs.launchpad.net/fedora/+source/baobab/+bug/997391/comments/8

------------------------------------------------------------------------
On 2012-08-20T03:57:19+00:00 Fedora wrote:

Package ntfs-3g-2012.1.15-3.fc18:
* should fix your issue,
* was pushed to the Fedora 18 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing ntfs-3g-2012.1.15-3.fc18'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2012-12261/ntfs-3g-2012.1.15-3.fc18
then log in and leave karma (feedback).

Reply at:
https://bugs.launchpad.net/fedora/+source/baobab/+bug/997391/comments/9

------------------------------------------------------------------------
On 2012-08-20T16:44:42+00:00 Erik wrote:

(In reply to comment #1)
> Erik, the patch you attached is seriously malformed (how did you manage
> that?), but I found the correct patch from the tuxera link. Update is
> coming, thanks.

I don't know what went wrong, but when I perform 'wget
https://bugzilla.redhat.com/attachment.cgi?id=605323' it returns a
proper patch here. Anyway, you managed to get the patch from upstream so
everything is good now.

Thanks for the quick update!

Reply at:
https://bugs.launchpad.net/fedora/+source/baobab/+bug/997391/comments/10

------------------------------------------------------------------------
On 2012-08-20T16:48:15+00:00 Erik wrote:

Sorry for the reassign noise. Some firefox extension messed up the
bugzilla form..

Reply at:
https://bugs.launchpad.net/fedora/+source/baobab/+bug/997391/comments/11

------------------------------------------------------------------------
On 2012-09-04T22:56:58+00:00 Fedora wrote:

ntfs-3g-2012.1.15-3.fc17 has been pushed to the Fedora 17 stable
repository.  If problems still persist, please make note of it in this
bug report.

Reply at:
https://bugs.launchpad.net/fedora/+source/baobab/+bug/997391/comments/16

------------------------------------------------------------------------
On 2012-09-17T23:43:10+00:00 Fedora wrote:

ntfs-3g-2012.1.15-3.fc18 has been pushed to the Fedora 18 stable
repository.  If problems still persist, please make note of it in this
bug report.

Reply at:
https://bugs.launchpad.net/fedora/+source/baobab/+bug/997391/comments/22


** Changed in: ntfs-3g (Fedora)
       Status: Unknown => Fix Released

** Changed in: ntfs-3g (Fedora)
   Importance: Unknown => Medium

** Bug watch added: GNOME Bug Tracker #672219
   https://bugzilla.gnome.org/show_bug.cgi?id=672219

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to ntfs-3g in Ubuntu.
https://bugs.launchpad.net/bugs/997391

Title:
  Symbolic links can create recursive loop that causes Baobab to never
  finish scanning

Status in ntfs-3g package in Ubuntu:
  Fix Released
Status in ntfs-3g source package in Precise:
  Fix Released
Status in ntfs-3g package in Debian:
  Fix Released
Status in baobab package in Fedora:
  Fix Released
Status in ntfs-3g package in Fedora:
  Fix Released

Bug description:
  = Stable Release Update discussion =
  == Impact ==
  readdir() returns the directory type for junction points (NTFS symbolic links). This causes baobab to go into an endless loop when scanning an NTFS file-system. Older baobabs used stat() which correctly identified junction points as being symlinks.

  This would affect all users who run baobab on a Windows 7 (or later)
  root file-system. For dual-booting users, that's fairly likely to be
  where they store most of their media (it's accessible from both OSs),
  and thus the file-system most likely to be full and need the help of
  baobab.

  == Test Case ==
  * Mount a Windows 7 root filesystem.
  * Run baobab on Users/somebody/Local\ Settings/Application\ Data (or just the whole file-system).
  * If affected by this bug, it will appear to take forever to scan, and under strace it's obvious that it's following an endless loop of symlinks. 

  == Regression potential ==
  The patch is limited to readdir() and simply adds support for more types of file. It is not trivial, but is readable and seems plausible.

  Fedora appear are also backporting this patch to F17.

  = Original report =
  1) The release of Ubuntu you are using, via 'lsb_release -rd' or System -> About Ubuntu
  Ubuntu 12.04 LTS

  2) The version of the package you are using, via 'apt-cache policy pkgname' or by checking in Software Center
  3.4.1-0ubuntu1

  3) What you expected to happen
  Detect the presence of symbolic link and omit directories under the link

  4) What happened instead
  Scans directories under the symbolic link, which is in reference to the directory above the symbolic link, and continue scanning without completion.

  Case in which bug was discovered:
  When scanning an NTFS drive with Windows 7 installed, the Users\System\AppData\Local\ directory contains a symlink called "Application Data" back to the Users\System\AppData\Local\ directory. This is used to maintain legacy support for older programs that require the Application Data folder. However, when Baobab reaches this point, it assumes that this continues to an infinite depth, and never completes the scan.

  Workaround:
  Omit scanning of the directory that is known to contain such links.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ntfs-3g/+bug/997391/+subscriptions



More information about the foundations-bugs mailing list