Bug 1694552 - After upgrade to fuse-2.9.9-1-fc29.x86_64 can't mount ENCFS directory on SAMBA
Summary: After upgrade to fuse-2.9.9-1-fc29.x86_64 can't mount ENCFS directory on SAMBA
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: fuse
Version: 29
Hardware: x86_64
OS: Linux
unspecified
urgent
Target Milestone: ---
Assignee: Peter Lemenkov
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-04-01 05:17 UTC by Christopher Archer
Modified: 2019-04-14 06:22 UTC (History)
4 users (show)

Fixed In Version: fuse-2.9.9-2.fc30 fuse-2.9.9-2.fc28 fuse-2.9.9-2.fc29
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-04-08 00:01:24 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github libfuse/libfuse/commit/b3abb451 0 None None None 2019-04-02 10:59:51 UTC
Github libfuse libfuse issues 392 0 None None None 2019-04-03 09:34:26 UTC
Launchpad 1530566 0 None None None 2019-04-02 10:59:51 UTC

Description Christopher Archer 2019-04-01 05:17:49 UTC
Description of problem:
Since upgrading to fuse-2.9.9-1-fc29.x86_64 and fuse-common-3.4.2-1.fc29.x86_64, ENCFS Samba directory mounted via smb4k can no longer be opened

Version-Release number of selected component (if applicable):
fuse-2.9.9-1-fc29.x86_64 and fuse-common-3.4.2-1.fc29.x86_64

How reproducible:
Always

Steps to Reproduce:
1. Attempt to open directory on Samba share for use, e.g.
encfs ~/smb4k/SERVER/Dir/.test ~/smb4k/SERVER/Dir/test

2. Provide correct password
3. ~/smb4k/SERVER/Dir/.test is not mounted to ~/smb4k/SERVER/Dir/test

Actual results:

[me@mine ~]$ encfs -v ~/smb4k/SERVER/Dir/.test ~/smb4k/SERVER/Dir/test
VERBOSE Root directory: /home/chris/smb4k/WACKO/Incoming/.test/ [main.cpp:686]
VERBOSE Fuse arguments: (daemon) (threaded) (keyCheck) encfs /home/chris/smb4k/WACKO/Incoming/test/ -o use_ino -o default_permissions  [main.cpp:687]
VERBOSE found new serialization format [FileUtils.cpp:299]
VERBOSE subVersion = 20100713 [FileUtils.cpp:313]
VERBOSE checking if ssl/aes(3:0:2) implements ssl/aes(3:0) [Interface.cpp:103]
VERBOSE allocated cipher ssl/aes, keySize 32, ivlength 16 [SSL_Cipher.cpp:395]
VERBOSE useStdin: 0 [FileUtils.cpp:1660]
EncFS Password:
VERBOSE checking if ssl/aes(3:0:2) implements ssl/aes(3:0) [Interface.cpp:103]
VERBOSE allocated cipher ssl/aes, keySize 32, ivlength 16 [SSL_Cipher.cpp:395]
VERBOSE cipher key size = 52 [FileUtils.cpp:1673]
VERBOSE checking if nameio/block(4:0:2) implements nameio/block(4:0) [Interface.cpp:103]
fusermount: mounting over filesystem type 0xfe534d42 is forbidden
fuse failed.  Common problems:
 - fuse kernel module not installed (modprobe fuse)
 - invalid options -- see usage message


Expected results:
~/smb4k/SERVER/Dir/.test successfully mounted to ~/smb4k/SERVER/Dir/test

Additional info:

Comment 1 Christopher Archer 2019-04-01 05:31:52 UTC
This seems to be a problem with SAMBA / smb4k.
Copying ~/smb4k/SERVER/Dir/test to a USB drive (Meko) then 

encfs /run/media/me/Meko/Dir/.test /run/media/me/Meko/Dir/test

works as expected.

rpm -qa | grep smb4k
smb4k-2.1.1-1.fc29.x86_64

rpm -qa | grep fuse
fuse-2.9.9-1.fc29.x86_64
gvfs-fuse-1.38.1-2.fc29.x86_64
fuse-sshfs-3.5.1-1.fc29.x86_64
fuse3-3.4.2-1.fc29.x86_64
fuse-encfs-1.9.5-2.fc29.x86_64
fuse-exfat-1.3.0-1.fc29.x86_64
fuse-common-3.4.2-1.fc29.x86_64
fuse-libs-2.9.9-1.fc29.x86_64
zfs-fuse-0.7.2.2-6.fc27.x86_64
glusterfs-fuse-5.5-1.fc29.x86_64
fuse3-libs-3.4.2-1.fc29.x86_64

rpm -qa | grep samba
samba-common-tools-4.9.5-0.fc29.x86_64
samba-common-libs-4.9.5-0.fc29.x86_64
samba-client-4.9.5-0.fc29.x86_64
samba-common-4.9.5-0.fc29.noarch
samba-libs-4.9.5-0.fc29.x86_64
samba-4.9.5-0.fc29.x86_64
samba-client-libs-4.9.5-0.fc29.x86_64

uname -a
Linux mine 5.0.4-200.fc29.x86_64 #1 SMP Mon Mar 25 02:27:33 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux

And yeah, so much for 'sanitizing' my directory names :-)

Failing call is 

encfs ~/chris/smb4k/WACKO/Incoming/.test/ ~/chris/smb4k/WACKO/Incoming/test/

Comment 2 Vasiliy Glazov 2019-04-01 05:36:20 UTC
Can you mount other fuse filesystems? For example fuse-zip.

Comment 3 Christopher Archer 2019-04-01 06:08:15 UTC
This works: 

sudo dnf install fuse-zip
sudo mkdir /mnt/TEST
sudo chmod 777 /mnt/TEST
fuse-zip -r ~/Downloads/2G/q201-ota-20171221.zip /mnt/TEST


This does not:
mkdir ~/smb4k/WACKO/Incoming/ziptest
cp ~/Downloads/2G/q201-ota-20171221.zip ~/smb4k/WACKO/Incoming/
fuse-zip -r ~/smb4k/WACKO/Incoming/q201-ota-20171221.zip  ~/smb4k/WACKO/Incoming/ziptest/
fusermount: mounting over filesystem type 0xfe534d42 is forbidden

So I'm guessing "filesystem type 0xfe534d42" either refers to Samba or smb4k

Comment 4 Vasiliy Glazov 2019-04-01 06:17:10 UTC
Test it please with previous version of fuse.

Comment 5 Christopher Archer 2019-04-02 00:06:18 UTC
sudo dnf downgrade fuse

rpm -qa | grep fuse
fuse3-3.2.3-14.fc29.x86_64
gvfs-fuse-1.38.1-2.fc29.x86_64
fuse-sshfs-3.5.1-1.fc29.x86_64
fuse-encfs-1.9.5-2.fc29.x86_64
fuse-exfat-1.3.0-1.fc29.x86_64
fuse-zip-0.6.0-1.fc29.x86_64
fuse-common-3.2.3-14.fc29.x86_64
fuse-libs-2.9.9-1.fc29.x86_64
zfs-fuse-0.7.2.2-6.fc27.x86_64
fuse-2.9.7-14.fc29.x86_64
glusterfs-fuse-5.5-1.fc29.x86_64
fuse3-libs-3.4.2-1.fc29.x86_64

and now it works!

Comment 6 Peter Lemenkov 2019-04-02 11:05:09 UTC
(In reply to Christopher Archer from comment #0)

> fusermount: mounting over filesystem type 0xfe534d42 is forbidden

This is an expected behavior. Upstream implemented whitelist of a filesystems which allow mounting over (because of a Launchpad's issue 1530566). Unfortunately we cannot do much here since this change has security implications (CVE-2016-1572). Please ask upstream either to add Samba to a good filesystems or for another way to override that behavior.

Comment 7 Peter Lemenkov 2019-04-02 11:14:56 UTC
(In reply to Christopher Archer from comment #3)
> This works: 
> 
> sudo dnf install fuse-zip
> sudo mkdir /mnt/TEST
> sudo chmod 777 /mnt/TEST
> fuse-zip -r ~/Downloads/2G/q201-ota-20171221.zip /mnt/TEST
> 
> 
> This does not:
> mkdir ~/smb4k/WACKO/Incoming/ziptest
> cp ~/Downloads/2G/q201-ota-20171221.zip ~/smb4k/WACKO/Incoming/
> fuse-zip -r ~/smb4k/WACKO/Incoming/q201-ota-20171221.zip 
> ~/smb4k/WACKO/Incoming/ziptest/
> fusermount: mounting over filesystem type 0xfe534d42 is forbidden
> 
> So I'm guessing "filesystem type 0xfe534d42" either refers to Samba or smb4k

Surprisingly, but CIFS filesystem is whitelisted. It has fsid 0xFF534D42, while you have 0xFE534D42.

Perhaps all we need is to add 0xFE534D42 but I'm not sure.

Christopher, is it possible to reconfigure your Samba somehow to get 0xFF534D42 as its fsid? I don't know much about Samba unfortunately.

Comment 8 Christopher Archer 2019-04-02 15:48:55 UTC
I haven't the first clue about how to 'reconfigure your Samba somehow to get 0xFF534D42 as its fsid'

What I DO find interesting is that the only difference between the fsids is an 'E' and an 'F'.
Is it possible there was a typo in the whitelist? 

I'm not doing anything special/exotic and this has worked a LONG time, so I'd be surprised if the problem is the fsid on my end, though I can't discount that.

Comment 9 Christopher Archer 2019-04-02 15:54:23 UTC
If it helps, the shares I'm mounting are on NASs that are running Alt-F

How do I see the FSIDs, e.g. for CIFS?

Comment 10 Peter Lemenkov 2019-04-03 09:34:26 UTC
Hello Christopher,
I've submitted a PR to add SMB2 to whitelist. Let's see what upstream says.

* https://github.com/libfuse/libfuse/pull/392

Comment 11 Christopher Archer 2019-04-03 15:27:41 UTC
Thank you. That's very much appreciated by me and the other SMB2 users out there :)

Comment 12 Fedora Update System 2019-04-04 10:34:32 UTC
fuse-2.9.9-2.fc30 has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-385e8ec9d7

Comment 13 Fedora Update System 2019-04-04 10:34:54 UTC
fuse-2.9.9-2.fc29 has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2019-efa6b41d3f

Comment 14 Fedora Update System 2019-04-04 10:35:17 UTC
fuse-2.9.9-2.fc28 has been submitted as an update to Fedora 28. https://bodhi.fedoraproject.org/updates/FEDORA-2019-8e8681281c

Comment 15 Fedora Update System 2019-04-04 18:07:05 UTC
fuse-2.9.9-2.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-385e8ec9d7

Comment 16 Fedora Update System 2019-04-05 02:35:30 UTC
fuse-2.9.9-2.fc28 has been pushed to the Fedora 28 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-8e8681281c

Comment 17 Fedora Update System 2019-04-05 03:26:00 UTC
fuse-2.9.9-2.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-efa6b41d3f

Comment 18 Fedora Update System 2019-04-08 00:01:24 UTC
fuse-2.9.9-2.fc30 has been pushed to the Fedora 30 stable repository. If problems still persist, please make note of it in this bug report.

Comment 19 Fedora Update System 2019-04-14 01:22:42 UTC
fuse-2.9.9-2.fc28 has been pushed to the Fedora 28 stable repository. If problems still persist, please make note of it in this bug report.

Comment 20 Fedora Update System 2019-04-14 06:22:54 UTC
fuse-2.9.9-2.fc29 has been pushed to the Fedora 29 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.