Date: Mon, 29 Oct 2018 01:50:31 +0000 From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 232772] fusefs(4) allows rename to create directory loops Message-ID: <bug-232772-227@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D232772 Bug ID: 232772 Summary: fusefs(4) allows rename to create directory loops Product: Base System Version: CURRENT Hardware: Any OS: Any Status: New Severity: Affects Many People Priority: --- Component: kern Assignee: bugs@FreeBSD.org Reporter: asomers@FreeBSD.org rename(2) is supposed to return EINVAL if it would create a directory loop.= =20 This is the behavior of UFS and ZFS. However, fusefs(4) doesn't detect it.= =20 fusefs-exfat and fusefs-ext2 both hang when you try, and a closed-source fu= se filesystem created the directory loop just fine. Steps to reproduce, with exfat: # truncate -s 1g /tmp/da1 # mkexfatfs /tmp/da1 mkexfatfs 1.2.7 Creating... done. Flushing... done. File system created successfully. # sudo mount.exfat -d /tmp/da1 /mnt Then in another window: # cd /mnt # mkdir foo # mkdir foo/sub # mv foo foo/sub/sub mv: rename foo to foo/sub/sub: Operation timed out Note that renaming foo to foo/sub correctly fails; the error only happens w= ith the additional level of indirection. Tested on 12.0-ALPHA9 amd64 and TrueOS-Desktop-201803131015. --=20 You are receiving this mail because: You are the assignee for the bug.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-232772-227>