2020-04-13 14:45:02 |
INIZAN yannick |
bug |
|
|
added bug |
2020-04-14 17:24:47 |
Rafael David Tinoco |
samba (Ubuntu): status |
New |
Incomplete |
|
2020-04-14 17:24:52 |
Rafael David Tinoco |
bug |
|
|
added subscriber Ubuntu Server |
2020-04-24 21:16:21 |
Bruno F |
bug |
|
|
added subscriber Bruno F |
2020-04-25 11:22:37 |
Bruno F |
attachment added |
|
files_shown_as_folder.png https://bugs.launchpad.net/ubuntu/+source/samba/+bug/1872476/+attachment/5360224/+files/files_shown_as_folder.png |
|
2020-04-25 11:23:16 |
Bruno F |
attachment added |
|
can_not_open_file.png https://bugs.launchpad.net/ubuntu/+source/samba/+bug/1872476/+attachment/5360225/+files/can_not_open_file.png |
|
2020-04-25 11:23:28 |
Bruno F |
attachment added |
|
smbclient-works.txt https://bugs.launchpad.net/ubuntu/+source/samba/+bug/1872476/+attachment/5360226/+files/smbclient-works.txt |
|
2020-04-25 11:24:28 |
Bruno F |
samba (Ubuntu): status |
Incomplete |
New |
|
2020-04-27 14:46:32 |
Andreas Hasenack |
bug watch added |
|
https://bugzilla.redhat.com/show_bug.cgi?id=1801442 |
|
2020-04-27 14:46:32 |
Andreas Hasenack |
bug watch added |
|
https://bugzilla.samba.org/show_bug.cgi?id=14101 |
|
2020-04-28 14:05:58 |
Sergio Durigan Junior |
samba (Ubuntu): assignee |
|
Sergio Durigan Junior (sergiodj) |
|
2020-04-30 08:26:55 |
Launchpad Janitor |
samba (Ubuntu): status |
New |
Confirmed |
|
2020-05-04 10:28:45 |
Sebastien Bacher |
samba (Ubuntu): importance |
Undecided |
High |
|
2020-05-04 10:28:51 |
Sebastien Bacher |
tags |
|
rls-ff-incoming |
|
2020-05-04 18:41:18 |
Launchpad Janitor |
merge proposal linked |
|
https://code.launchpad.net/~sergiodj/ubuntu/+source/samba/+git/samba/+merge/383358 |
|
2020-05-05 12:33:53 |
Andreas Hasenack |
nominated for series |
|
Ubuntu Focal |
|
2020-05-05 12:33:53 |
Andreas Hasenack |
bug task added |
|
samba (Ubuntu Focal) |
|
2020-05-05 12:34:04 |
Andreas Hasenack |
samba (Ubuntu Focal): assignee |
|
Sergio Durigan Junior (sergiodj) |
|
2020-05-05 12:34:12 |
Andreas Hasenack |
samba (Ubuntu Focal): status |
New |
In Progress |
|
2020-05-05 12:34:16 |
Andreas Hasenack |
samba (Ubuntu Focal): importance |
Undecided |
High |
|
2020-05-05 14:20:09 |
Sergio Durigan Junior |
description |
System : Xubuntu 20.04 LTS, kernel 5.6.2
Samba : Version 4.11.6-Ubuntu
problem : latest versions of samba can't mount remote disk if the remote protocol is too old. Can be fixed by adding "client min protocol = CORE" under [global] section in conf.
But there is another problem, all files in remote disk are shown as folders, so we can't read these files
(screenshot : https://ibb.co/g9FW14c) |
[Impact]
The current samba package on focal suffers from a bug that manifests itselft when the SMB1 (NT1) protocol is being used. In this scenario, the user will see regular files being presented as directories when using GIO/gvfs to browse the samba share (e.g., via nautilus, or using the "gio" command). Even though the SMB1 protocol is old, it is still used by some NAS devices and therefore this issue can impact a non-trivial number of users.
The fix, which had to be cherry-picked from upstream, is to revert a specific libsmb code that attempts to obtain some POSIX stat(2) information when running on UNIX-like environments. The upstream commit can be found here:
https://gitlab.com/samba-team/devel/samba/-/commit/39c910fd9cba3caf7414274b678b9eee33d7e20b
[Test Case]
In order to reproduce the bug, one can do:
$ lxc launch ubuntu-daily:focal samba-bug1872476
$ lxc shell samba-bug1872476
When inside the LXC container, as root:
# apt install samba smbclient gvfs gvfs-backends dbus-x11
# sed -i 's/^\[global\]/[global]\n client min protocol = NT1\n client max protocol = NT1\n server min protocol = NT1\n server max protocol = NT1/g' /etc/samba/smb.conf
# cat >> /etc/samba/smb.conf << __EOF__
[testshare]
path = /testshare
readonly = no
browsable = yes
guest ok = yes
__EOF__
# mkdir /testshare
# cat > /testshare/123.txt << __EOF__
Hi, this is a test for samba bug 1872476.
This is a regular file, and not a directory.
__EOF__
# ufw allow samba
# eval $(dbus-launch --sh-syntax)
# gio mount -a smb://127.0.0.1/testshare
# gio info smb://127.0.0.1/testshare/123.txt | grep '^type:'
type: directory
As can be seen above, the regular file '123.txt' is mistakenly listed as a directory.
There's a PPA with a proposed fix here:
https://launchpad.net/~sergiodj/+archive/ubuntu/samba-bug1872476-v2
When trying it out, it is important to umount the share and remount it with the new package:
# gio mount -u smb://127.0.0.1/testshare
# add-apt-repository ppa:sergiodj/samba-bug1872476-v2
# apt update && apt upgrade
# gio mount -a smb://127.0.0.1/testshare
# gio info smb://127.0.0.1/testshare/123.txt | grep '^type:'
type: regular
[Regression Potential]
This change is relatively simple and has been incorporated by upstream and by other distributions, but it touches libsmb, which is a central area of samba.
The POSIX stat(2) call was only made when dealing with the NT1/SMB1 version of the samba protocol running on UNIX-like environments, which contributes to reduce the impact of the patch.
We can assume that there is regression potential for users of the NT1/SMB1 protocol on UNIX-like environments that are dealing with different types of files (regular, directory, symbolic links, etc.), since the code that the patch modifies is responsible for obtaining the attributes of a file. Even though the function uses fallback mechanisms (like resorting to qpathinfo calls) to not depend solely on stat(2), the user might experience some regression when trying to determine the type of a file.
[Original Description]
System : Xubuntu 20.04 LTS, kernel 5.6.2
Samba : Version 4.11.6-Ubuntu
problem : latest versions of samba can't mount remote disk if the remote protocol is too old. Can be fixed by adding "client min protocol = CORE" under [global] section in conf.
But there is another problem, all files in remote disk are shown as folders, so we can't read these files
(screenshot : https://ibb.co/g9FW14c) |
|
2020-05-09 08:25:47 |
Vincent |
bug |
|
|
added subscriber Vincent |
2020-05-12 18:17:50 |
Brian Murray |
samba (Ubuntu Focal): status |
In Progress |
Fix Committed |
|
2020-05-12 18:17:51 |
Brian Murray |
bug |
|
|
added subscriber Ubuntu Stable Release Updates Team |
2020-05-12 18:17:54 |
Brian Murray |
bug |
|
|
added subscriber SRU Verification |
2020-05-12 18:18:01 |
Brian Murray |
tags |
rls-ff-incoming |
rls-ff-incoming verification-needed verification-needed-focal |
|
2020-05-13 07:43:32 |
Vincent |
tags |
rls-ff-incoming verification-needed verification-needed-focal |
rls-ff-incoming verification-done-focal verification-needed |
|
2020-05-18 12:27:14 |
Andreas Hasenack |
samba (Ubuntu): status |
Confirmed |
Fix Released |
|
2020-05-21 08:05:51 |
Łukasz Zemczak |
removed subscriber Ubuntu Stable Release Updates Team |
|
|
|
2020-05-21 08:05:57 |
Launchpad Janitor |
samba (Ubuntu Focal): status |
Fix Committed |
Fix Released |
|
2020-10-31 23:49:03 |
jsquared |
attachment added |
|
smb_issue.jpg https://bugs.launchpad.net/ubuntu/+source/samba/+bug/1872476/+attachment/5429897/+files/smb_issue.jpg |
|
2020-11-01 16:34:12 |
Rapper_skull |
bug |
|
|
added subscriber Rapper_skull |
2020-11-03 12:49:07 |
Andreas Hasenack |
samba (Ubuntu Focal): status |
Fix Released |
New |
|
2020-11-13 22:15:12 |
Launchpad Janitor |
samba (Ubuntu Focal): status |
New |
Confirmed |
|
2020-12-02 07:01:09 |
Meabert |
samba (Ubuntu Focal): status |
Confirmed |
Fix Released |
|
2020-12-08 09:54:35 |
Christian Ehrhardt |
samba (Ubuntu Focal): status |
Fix Released |
Confirmed |
|
2020-12-08 13:30:25 |
Lee Tae Hoon |
attachment added |
|
2020-12-08 22-24-53.png https://bugs.launchpad.net/ubuntu/+source/samba/+bug/1872476/+attachment/5441973/+files/2020-12-08%2022-24-53.png |
|
2020-12-08 16:27:00 |
Dave Gregory |
attachment added |
|
Screenshot from 2020-12-08 16-25-16.png https://bugs.launchpad.net/ubuntu/+source/samba/+bug/1872476/+attachment/5442011/+files/Screenshot%20from%202020-12-08%2016-25-16.png |
|
2020-12-09 14:03:28 |
Lee Tae Hoon |
attachment added |
|
samba.zip https://bugs.launchpad.net/ubuntu/+source/samba/+bug/1872476/+attachment/5442249/+files/samba.zip |
|
2020-12-10 14:44:15 |
Lee Tae Hoon |
attachment added |
|
samba1.zip https://bugs.launchpad.net/ubuntu/+source/samba/+bug/1872476/+attachment/5442523/+files/samba1.zip |
|
2020-12-11 16:17:35 |
Lee Tae Hoon |
attachment added |
|
Samba2.docx https://bugs.launchpad.net/ubuntu/+source/samba/+bug/1872476/+attachment/5442812/+files/Samba2.docx |
|
2020-12-14 13:23:42 |
Bernard |
bug |
|
|
added subscriber Bernard |
2020-12-22 01:15:28 |
rmills |
bug |
|
|
added subscriber rmills |
2021-02-15 20:38:26 |
Morbius1 |
bug |
|
|
added subscriber Morbius1 |
2021-02-22 11:41:56 |
Nathan Rennie-Waldock |
attachment added |
|
0001-s3-smbd-Ignore-zero-length-attributes-in-parse_dos_a.patch https://bugs.launchpad.net/ubuntu/+source/samba/+bug/1872476/+attachment/5465921/+files/0001-s3-smbd-Ignore-zero-length-attributes-in-parse_dos_a.patch |
|
2021-04-11 13:03:58 |
Ward Chanley |
bug |
|
|
added subscriber Ward Chanley |
2021-04-19 15:55:26 |
Bryce Harrington |
samba (Ubuntu Focal): status |
Confirmed |
Triaged |
|
2021-11-23 02:25:57 |
Sergio Durigan Junior |
cve linked |
|
2016-2124 |
|
2021-11-23 02:25:57 |
Sergio Durigan Junior |
cve linked |
|
2020-25717 |
|
2021-11-23 02:25:57 |
Sergio Durigan Junior |
cve linked |
|
2020-25718 |
|
2021-11-23 02:25:57 |
Sergio Durigan Junior |
cve linked |
|
2020-25719 |
|
2021-11-23 02:25:57 |
Sergio Durigan Junior |
cve linked |
|
2020-25721 |
|
2021-11-23 02:25:57 |
Sergio Durigan Junior |
cve linked |
|
2020-25722 |
|
2021-11-23 02:25:57 |
Sergio Durigan Junior |
cve linked |
|
2021-23192 |
|
2021-11-23 02:25:57 |
Sergio Durigan Junior |
cve linked |
|
2021-3738 |
|
2021-11-23 02:26:06 |
Sergio Durigan Junior |
samba (Ubuntu Focal): status |
Triaged |
Fix Released |
|